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'm trying to use PWCDCNet implemented in PyTorch to calculate the optical flow on some dataset with image shape of 3 * 480 * 640 (C x H x W).
However, when I fed the images into the network, the following error occurred:
File "...\pwc_model.py", line 143, in warp
vgrid = grid + flo
RuntimeError: The size of tensor a (15) must match the size of tensor b (16) at non-singleton dimension 2
Setting breakpoint and analyze the intermediate results in the forward() method of PWCDCNet shows that the variables c2x in forward() has following shape:
Hi, I'm trying to use
PWCDCNet
implemented in PyTorch to calculate the optical flow on some dataset with image shape of3 * 480 * 640
(C x H x W).However, when I fed the images into the network, the following error occurred:
Setting breakpoint and analyze the intermediate results in the
forward()
method ofPWCDCNet
shows that the variablesc2x
inforward()
has following shape:PWC-Net/PyTorch/models/PWCNet.py
Lines 182 to 193 in 07df6eb
When calculating
upflow_6
, theupflow_6
has shape oftorch.Size([1, 2, 16, 20])
.And hence the exception is raised on this line:
PWC-Net/PyTorch/models/PWCNet.py
Line 210 in 07df6eb
Is there any continent fix (i.e. without modifying the architecture which requires re-training the network) to this problem?
Thanks.
The text was updated successfully, but these errors were encountered: