FCN-pytorch icon indicating copy to clipboard operation
FCN-pytorch copied to clipboard

Mismatch error

Open Shaunlipy opened this issue 6 years ago • 4 comments

Hi, I implement the code, but for the fcn.py on line 145. It says: "The size of tensor a (44) must match the size of tensor b (45) at non-singleton dimension 2"

I found the score shape is [1, 512, 44, 60] and the x4 shape is [1, 512, 45, 60]

Curious how would that happen?

Thanks

Shaunlipy avatar Mar 21 '18 20:03 Shaunlipy

Can you report the dataset you used? Thanks!

pochih avatar Mar 29 '18 12:03 pochih

Hi,

I met the same question and I used camvid dataset. I don't know why is it? @brianhuang1019

Bing1002 avatar May 03 '18 18:05 Bing1002

For some reason, the attribute self.crop of the train dataset instance is reset to False when the validation dataset instance is created. Comment line #44 of init() method of Class CamVidDataset to solve this issue.

andrecavalcante avatar May 22 '18 20:05 andrecavalcante

For some reason, the attribute self.crop of the train dataset instance is reset to False when the validation dataset instance is created. Comment line #44 of init() method of Class CamVidDataset to solve this issue.

THANKS! after commenting ###self.crop = False,solve this issue. What bad influences will happen to our model?

Water2style avatar Mar 10 '19 07:03 Water2style