Traceback (most recent call last):
File "train.py", line 488, in
train_acc = trainepoch(epoch)
File "train.py", line 443, in trainepoch
total_norm = np.sqrt(total_norm.cpu())
AttributeError: 'float' object has no attribute 'cpu'
Is there a particular reason for you to use .cpu() here? Seems like it could be removed.
Traceback (most recent call last): File "train.py", line 488, in
train_acc = trainepoch(epoch)
File "train.py", line 443, in trainepoch
total_norm = np.sqrt(total_norm.cpu())
AttributeError: 'float' object has no attribute 'cpu'
Is there a particular reason for you to use
.cpu()
here? Seems like it could be removed.