Skip to content

Construct custom model using DreaMS #29

@WinterWei22

Description

@WinterWei22

Hi, Thanks for the great work!

I am interested in constructing a custom model based on DreaMS, but some details are confusing to me. For example, for the input of the DreaMS encoder, do we need to involve the pre-cursor peaks for the input? Because I noticed that you use the pre-cursor token in the ssl model:

class CustomModel(nn.Module):
     ...
    def forward(self, x):

        **x = self.spec_encoder(x)[:, 0, :]  # [:, 0, :] to get the precursor peak token embedding**

        x = F.sigmoid(self.lin_out(x))  # Example forward pass through the head

       return x

If the precursor peaks are needed, how can I provide them in the right way?

Thanks in advance for your help!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions