Re-training ResNet-18 Model

I am learning the tutorials of jetson-inference. Now I am stuck in this step of Re-training ResNet-18 Model.When I run the train.py, I encounter the problem below the picture.I am really looking forward your reply, thank you very much.

Hi,

It seems that you are meeting a similar problem of the below issue:

Please give it a check.
Thanks.

Hi @924971015, are you using PyTorch 1.7? I found this issue began occurring because of some updates in PyTorch 1.7 - I just fixed it in the classification training script in commit 15c7d5

If you are using PyTorch 1.7, re-clone the jetson-inference repo and the classification training should work now.

The updated code should still work on previous versions of PyTorch.

Thank you very much , I have solved this problem.

Is your problem identical with mine, could you describe your problem in details?

the problem have been solved by dusty , please re-clone the jetson-inference repo and the classification training should work now.