maciejkula/spotlight

Is there a way to manually set seq model mode?

cailurus opened this issue · 1 comments

I'd like to eval the NN model every epoch:

model = ImplicitSequenceModel(xxx, n_iter=1)

for _ in range(10):
    model.fit(train, verbose=True)
    sequence_precision_recall_score(model, test) # after I added this, internal PyTorch model changed to eval mode. So can I added a line to switch the internal model to train mode again?

Can you post the error you see?