|
我想把PyTorch autograd转型。变量到它的等效numpy数组。在他们的官方文档中,他们提倡使用a.numpy()来获得等效的numpy数组(用于PyTorch张量)。但这给了我如下错误:
Traceback (most recent call last): File "stdin", line 1, in module File "/home/bishwajit/anaconda3/lib/python3.6/site-packages/torch/autograd/variable.py", line 63, in getattr raise AttributeError(name) AttributeError: numpy
有什么办法可以解决吗 |
|