Open ceh-2000 opened 2 years ago
Full error message: RuntimeError: Can't call numpy() on Tensor that requires grad. Use tensor.detach().numpy() instead.
numpy()
tensor.detach().numpy()
Added the following as line 227 to serverbase.py to resolve: test_losses = [t.detach() for t in test_losses]
serverbase.py
test_losses = [t.detach() for t in test_losses]
Python version: 3.8.6
Thank you very much for providing the solution to this error!
Full error message: RuntimeError: Can't call
numpy()
on Tensor that requires grad. Usetensor.detach().numpy()
instead.Added the following as line 227 to
serverbase.py
to resolve:test_losses = [t.detach() for t in test_losses]
Python version: 3.8.6