You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I run this code,but has a error,the outpout is:
Please install sklearn for layer visualization
Traceback (most recent call last):
File "/home/hang/PycharmProjects/pytorch/test.py", line 209, in
output = cnn(b_x)[0] # cnn output
File "/home/hang/.local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 357, in call
result = self.forward(*input, **kwargs)
File "/home/hang/PycharmProjects/pytorch/test.py", line 180, in forward
x = self.conv1(x)
File "/home/hang/.local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 357, in call
result = self.forward(*input, **kwargs)
File "/home/hang/.local/lib/python2.7/site-packages/torch/nn/modules/container.py", line 67, in forward
input = module(input)
File "/home/hang/.local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 357, in call
result = self.forward(*input, **kwargs)
File "/home/hang/.local/lib/python2.7/site-packages/torch/nn/modules/conv.py", line 282, in forward
self.padding, self.dilation, self.groups)
File "/home/hang/.local/lib/python2.7/site-packages/torch/nn/functional.py", line 90, in conv2d
return f(input, weight, bias)
TypeError: argument 0 is not a Variable
Process finished with exit code 1
还有一个问题,为什么代码与视频中的不一样?
是因为Variable的问题吗
谢谢
The text was updated successfully, but these errors were encountered:
Hi, I run this code,but has a error,the outpout is:
Please install sklearn for layer visualization
Traceback (most recent call last):
File "/home/hang/PycharmProjects/pytorch/test.py", line 209, in
output = cnn(b_x)[0] # cnn output
File "/home/hang/.local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 357, in call
result = self.forward(*input, **kwargs)
File "/home/hang/PycharmProjects/pytorch/test.py", line 180, in forward
x = self.conv1(x)
File "/home/hang/.local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 357, in call
result = self.forward(*input, **kwargs)
File "/home/hang/.local/lib/python2.7/site-packages/torch/nn/modules/container.py", line 67, in forward
input = module(input)
File "/home/hang/.local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 357, in call
result = self.forward(*input, **kwargs)
File "/home/hang/.local/lib/python2.7/site-packages/torch/nn/modules/conv.py", line 282, in forward
self.padding, self.dilation, self.groups)
File "/home/hang/.local/lib/python2.7/site-packages/torch/nn/functional.py", line 90, in conv2d
return f(input, weight, bias)
TypeError: argument 0 is not a Variable
Process finished with exit code 1
还有一个问题,为什么代码与视频中的不一样?
是因为Variable的问题吗
谢谢
The text was updated successfully, but these errors were encountered: