hnjzbss / EKAGen

[CVPR 2024]Instance-level Expert Knowledge and Aggregate Discriminative Attention for Radiology Report Generation
Apache License 2.0
18 stars 0 forks source link

Teacher model weight loading problem #3

Open dyy1201 opened 1 month ago

dyy1201 commented 1 month ago

I'm encountering a dimension mismatch error while loading the weights for the teacher model (tmodel). The issue specifically occurs in the transformer.embeddings.word_embeddings.weight and mlp.layers. I have used the weight file you provided (iu_t_model.pth), but there is such an error, and there is another weight file (iu_weight.pth) that I have not used. May I ask where it is loaded?

hnjzbss commented 1 month ago

I'm encountering a dimension mismatch error while loading the weights for the teacher model (tmodel). The issue specifically occurs in the transformer.embeddings.word_embeddings.weight and mlp.layers. I have used the weight file you provided (iu_t_model.pth), but there is such an error, and there is another weight file (iu_weight.pth) that I have not used. May I ask where it is loaded?

"iu_t_model.pth" is the weights for the teacher network, while "iu_weight.pth" contains the final trained model weights. If you encounter a dimension mismatch error, please check if there is an error with the vocab_size parameter. You can refer to the shell script for the specific parameters of the two datasets.