Hi team,
First of all, thank you for open-sourcing this excellent project. During my testing, I identified a few code issues, primarily in the inference module:
Weight loading prefix issue: When loading pretrained model weights (possibly version-specific to my torch installation), there was an issue with the _orig_mod. prefix in state dict keys. I've provided a workaround example in MS2SMILES_yaml_predictor.py (lines 162-172).
Bug in beam_search_inference: The beam search implementation had a bug that has been fixed in MS2SMILES_Model.py. This fix also addresses the empty prediction issue reported in issue #3.
Thanks again for your work!
MS2SMILES_Model.py
MS2SMILES_yaml_predictor.py
Hi team,
First of all, thank you for open-sourcing this excellent project. During my testing, I identified a few code issues, primarily in the inference module:
Weight loading prefix issue: When loading pretrained model weights (possibly version-specific to my torch installation), there was an issue with the _orig_mod. prefix in state dict keys. I've provided a workaround example in MS2SMILES_yaml_predictor.py (lines 162-172).
Bug in beam_search_inference: The beam search implementation had a bug that has been fixed in MS2SMILES_Model.py. This fix also addresses the empty prediction issue reported in issue #3.
Thanks again for your work!
MS2SMILES_Model.py
MS2SMILES_yaml_predictor.py