caffe2pytorch-tsn icon indicating copy to clipboard operation
caffe2pytorch-tsn copied to clipboard

size mismatch for new_fc.weight

Open LiuLei95 opened this issue 3 years ago • 1 comments

When i used the pretrain model of ucf101_rgb.pth, there is an error "size mismatch for new_fc.weight: copying a param with shape torch.Size([101, 1024]) from checkpoint, the shape in current model is torch.Size([101, 2048])". How can i solve it ?

LiuLei95 avatar May 14 '21 13:05 LiuLei95

Ok, i solve the problem. The reason is that basemodel i used resnet101, but the pretrained model is used BNInception.

LiuLei95 avatar May 15 '21 05:05 LiuLei95