Can I directly test my custom dataset on pretrianed model?
My console shows below error:
run
target_transform; <target_transforms.VideoID object at 0x7f8fd1f57898>
dataset loading [0/3783]
dataset loading [1000/3783]
dataset loading [2000/3783]
dataset loading [3000/3783]
test
/home/fazlik/Desktop/3D-ResNets-PyTorch/test.py:41: UserWarning: volatile was removed and now has no effect. Use with torch.no_grad(): instead.
inputs = Variable(inputs, volatile=True)
/home/fazlik/Desktop/3D-ResNets-PyTorch/test.py:49: UserWarning: Implicit dimension choice for softmax has been deprecated. Change the call to include dim=X as an argument.
outputs = F.softmax(outputs)
Traceback (most recent call last):
File "main.py", line 181, in
test.test(test_loader, model, opt, test_data.class_names)
File "/home/fazlik/Desktop/3D-ResNets-PyTorch/test.py", line 54, in test
test_results, class_names)
File "/home/fazlik/Desktop/3D-ResNets-PyTorch/test.py", line 19, in calculate_video_results
'label': class_names[locs[i].item()],
KeyError: 2037
Hi!
Can I directly test my custom dataset on pretrianed model?
My console shows below error:
run target_transform; <target_transforms.VideoID object at 0x7f8fd1f57898> dataset loading [0/3783] dataset loading [1000/3783] dataset loading [2000/3783] dataset loading [3000/3783] test /home/fazlik/Desktop/3D-ResNets-PyTorch/test.py:41: UserWarning: volatile was removed and now has no effect. Use
test.test(test_loader, model, opt, test_data.class_names)
File "/home/fazlik/Desktop/3D-ResNets-PyTorch/test.py", line 54, in test
test_results, class_names)
File "/home/fazlik/Desktop/3D-ResNets-PyTorch/test.py", line 19, in calculate_video_results
'label': class_names[locs[i].item()],
KeyError: 2037
with torch.no_grad():
instead. inputs = Variable(inputs, volatile=True) /home/fazlik/Desktop/3D-ResNets-PyTorch/test.py:49: UserWarning: Implicit dimension choice for softmax has been deprecated. Change the call to include dim=X as an argument. outputs = F.softmax(outputs) Traceback (most recent call last): File "main.py", line 181, inHow can I deal with that issue?
Thank you