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 tried to run ur code, i got an error, do u know how to fix this?
thx~ :)
Here is the Traceback Information:
yellowtown@Yellowtown:/media/yellowtown/Work/Github/pytorch-capsule$ python3.5 main.py
Traceback (most recent call last):
File "main.py", line 61, in
output_unit_size=output_unit_size).cuda()
File "/media/yellowtown/Work/Github/pytorch-capsule/capsule_network.py", line 53, in init
self.reconstruct0 = nn.Linear(num_output_units*output_unit_size, (reconstruction_size * 2) / 3)
File "/home/yellowtown/.local/lib/python3.5/site-packages/torch/nn/modules/linear.py", line 39, in init
self.weight = Parameter(torch.Tensor(out_features, in_features))
TypeError: torch.FloatTensor constructor received an invalid combination of arguments - got (float, int), but expected one of:
no arguments
(int ...)
didn't match because some of the arguments have invalid types: (float, int)
(torch.FloatTensor viewed_tensor)
(torch.Size size)
(torch.FloatStorage data)
(Sequence data)
The text was updated successfully, but these errors were encountered:
Hi,
I tried to run ur code, i got an error, do u know how to fix this?
thx~ :)
Here is the Traceback Information:
yellowtown@Yellowtown:/media/yellowtown/Work/Github/pytorch-capsule$ python3.5 main.py
Traceback (most recent call last):
File "main.py", line 61, in
output_unit_size=output_unit_size).cuda()
File "/media/yellowtown/Work/Github/pytorch-capsule/capsule_network.py", line 53, in init
self.reconstruct0 = nn.Linear(num_output_units*output_unit_size, (reconstruction_size * 2) / 3)
File "/home/yellowtown/.local/lib/python3.5/site-packages/torch/nn/modules/linear.py", line 39, in init
self.weight = Parameter(torch.Tensor(out_features, in_features))
TypeError: torch.FloatTensor constructor received an invalid combination of arguments - got (float, int), but expected one of:
didn't match because some of the arguments have invalid types: (float, int)
The text was updated successfully, but these errors were encountered: