Hi I am new to Pytorch.
Is model.train() the same as model for training?
I find they are the same, am I correct?
Thanks.
RNN Model
class RNN(nn.Module):
def init(self, input_size, hidden_size, num_layers, num_classes):
super(RNN, self).init()
self.hidden_size = hidden_size
…                       …      = dropout(…)
def forward(self, x):

…
…
…
rnn = RNN(input_size, hidden_size, num_layers, num_classes)
criterion = nn.CrossEntropyLoss()
optimizer = torch.optim.Adagrad(…)
train…
…
test
model.eval()