Hi, I don’t understand how the problem is solved. Based on the code he gave at first, he wanted the training to stop after a certain epoch. But in the code you gave him, you were initializing the model and setting train to false immediately without training it first.
Thanks for your answer.