You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I use the prediction_emb.py to predict rt value ,I have found some questions.How can I deal with it.
python prediction_emb.py 46 param/dia_all_epo20_dim24_conv12/dia_all_epo20_dim24_conv12_filled.pt 12 data/SCX.txt
Traceback (most recent call last):
File "prediction_emb.py", line 78, in
obse,pred1=pred_from_model(conv1,conv1,round1model,RTtest,15)
File "prediction_emb.py", line 17, in pred_from_model
model.load_state_dict(torch.load(param_path))
File "/home/renzhe/anaconda3/lib/python3.7/site-packages/torch/nn/modules/module.py", line 769, in load_state_dict
self.class.name, "\n\t".join(error_msgs)))
RuntimeError: Error(s) in loading state_dict for CapsuleNet:
size mismatch for emb.weight: copying a param with shape torch.Size([25, 20]) from checkpoint, the shape in current model is torch.Size([21, 20]).
The text was updated successfully, but these errors were encountered:
because 66 is the max length in the "dia.txt" dataset, while 50 is for the "mod.txt" dataset, and "dict_path" means we want to include four modifications.
By the way, I guess you were using RPLC model to make predictions on SCX data, which might not be valid, since RP and SCX are different separation mechanisms...
When I use the prediction_emb.py to predict rt value ,I have found some questions.How can I deal with it.
python prediction_emb.py 46 param/dia_all_epo20_dim24_conv12/dia_all_epo20_dim24_conv12_filled.pt 12 data/SCX.txt
Traceback (most recent call last):
File "prediction_emb.py", line 78, in
obse,pred1=pred_from_model(conv1,conv1,round1model,RTtest,15)
File "prediction_emb.py", line 17, in pred_from_model
model.load_state_dict(torch.load(param_path))
File "/home/renzhe/anaconda3/lib/python3.7/site-packages/torch/nn/modules/module.py", line 769, in load_state_dict
self.class.name, "\n\t".join(error_msgs)))
RuntimeError: Error(s) in loading state_dict for CapsuleNet:
size mismatch for emb.weight: copying a param with shape torch.Size([25, 20]) from checkpoint, the shape in current model is torch.Size([21, 20]).
The text was updated successfully, but these errors were encountered: