foolwood / SiamMask

[CVPR2019] Fast Online Object Tracking and Segmentation: A Unifying Approach
http://www.robots.ox.ac.uk/~qwang/SiamMask
MIT License
3.47k stars 816 forks source link

run demo.py and have a error #45

Open tiankongzhang opened 5 years ago

tiankongzhang commented 5 years ago

Traceback (most recent call last): File "../../tools/demo.py", line 56, in state = siamese_track(state, im, mask_enable=True, refine_enable=True) # track File "/home/zhouwenzhang/SiamMask-master/tools/test.py", line 254, in siamese_track mask = net.track_refine((delta_y, delta_x)).cuda().sigmoid().squeeze().view( File "/home/zhouwenzhang/SiamMask-master/experiments/siammask/custom.py", line 157, in track_refine pred_mask = self.refine_model(self.feature, self.corr_feature, pos=pos) File "/opt/conda/envs/pytorch-py3.6/lib/python3.6/site-packages/torch/nn/modules/module.py", line 468, in call result = self.forward(*input, **kwargs) File "/home/zhouwenzhang/SiamMask-master/experiments/siammask/custom.py", line 123, in forward out = self.post0(F.upsample(self.h2(out) + self.v2(p2), size=(31, 31))) File "/opt/conda/envs/pytorch-py3.6/lib/python3.6/site-packages/torch/nn/functional.py", line 1797, in upsample return torch._C._nn.upsample_nearest2d(input, _scale_factor(2)) File "/opt/conda/envs/pytorch-py3.6/lib/python3.6/site-packages/torch/nn/functional.py", line 1769, in _scale_factor 'x'.join(map(str, input.size())))) RuntimeError: output size specified in UpsamplingNearest (31x31) has to be divisible by the input size, but got: 1x32x15x15

eathongdoubin commented 5 years ago

I have encountered the same problem with you. Have you solved it?

sunweixings commented 4 years ago

I meet the same problem with you.How can I solve it?

MrL-CV commented 3 years ago

i meet the same problem, but someone said it may be the mismatch between the cuda version, but i dont known how to solve it