nok-halfspace / Transformer-Time-Series-Forecasting

373 stars 102 forks source link

one question about the model #10

Open ixjx opened 1 year ago

ixjx commented 1 year ago

in the model.py:

        self.encoder_layer = nn.TransformerEncoderLayer(d_model=feature_size, nhead=7, dropout=dropout)
        self.transformer_encoder = nn.TransformerEncoder(self.encoder_layer, num_layers=num_layers)        
        self.decoder = nn.Linear(feature_size,1)

the tranformer decoder is only a Linear layer, is there something I missd?

justinge commented 1 month ago

for the author ,the decoder is the same with encoder