kenshohara / video-classification-3d-cnn-pytorch

Video classification tools using 3D ResNet
MIT License
1.11k stars 260 forks source link

Some problem when use 'resnext-101-64f-kinetics-ucf101_split1.pth' #20

Closed sunume closed 6 years ago

sunume commented 6 years ago

My command was 'python main.py --input ./input --video_root ~/data/U CF-101/CleanAndJerk/v_CleanAndJerk_g --output ./output.json --model ./resnext-101-64f-kinetics-ucf101_split1.pth --mode score --model_name resnext --model_depth 101 --batch_size 32 --n_thread 4 --resnet_shortcut 'B' --resnext_cardinality 32' However, I got RuntimeError :While copying the parameter named module.fc.weight, whose dimensions in the model are torch.Size([400, 2048]) and whose dimensions in the checkpoint are torch.Size([101, 2048]). Is there anything wrong with my parameters?

sunume commented 6 years ago

I have solved it by change the class number, but I met another problem: RuntimeError: avg_pool3d(): argument 'kernel_size' must be tuple of ints, but found element of type float at pos 1

qkgia commented 6 years ago

I had the same problem "RuntimeError: avg_pool3d()". Solved using python3 instead of python2

sunume commented 6 years ago

@qkgia , thanks for your help. I have solved this using python3