video-classification-3d-cnn-pytorch
video-classification-3d-cnn-pytorch copied to clipboard
Unable to load resnext-101-kinetics.pth model
I run following command:
python main.py --input ./input --video_root ./videos --output ./output.json --model_name resnext --model_depth 101 --model ./models/resnext-101-kinetics.pth --mode score
and got following error:
Traceback (most recent call last): File "main.py", line 24, in
model_data = torch.load(opt.model) File "/home/saurabhr/.local/lib/python3.5/site-packages/torch/serialization.py", line 303, in load return _load(f, map_location, pickle_module) File "/home/saurabhr/.local/lib/python3.5/site-packages/torch/serialization.py", line 459, in _load magic_number = pickle_module.load(f) _pickle.UnpicklingError: invalid load key, ' '.
Python version: 3.5.2 torch version: 0.4.0 torchvision version: 0.2.1 cuda : 9.0
The shortcut parameter is missing from your command. It may be the cause of the error. Try to add "--resnet_shortcut B" in the command.
@thanasisDr I didn't help. Same error. I think pretrained model file has some problem.
@saurabhhjjain Did you try loading any of the other resnext models? There's six of them.
No, I didn't
The shortcut parameter is missing from your command. It may be the cause of the error. Try to add "--resnet_shortcut B" in the command.
thank you, it helps.