Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rxn map strict #33

Closed
autodataming opened this issue Jun 28, 2020 · 1 comment
Closed

rxn map strict #33

autodataming opened this issue Jun 28, 2020 · 1 comment

Comments

@autodataming
Copy link
Contributor

[H]C([H])([H])Oc1ccc(CCNC=O)cc1OC([H])([H])[H]>>[H]C([H])([H])Oc1cc2c(cc1OC([H])([H])[H])CCN=C2
[CH2:1]([CH2:2][NH:10][CH:11]=[O:21])[c:8]1[cH:7][cH:6][c:5]([O:4][CH3:3])[c:12]([cH:9]1)[O:13][CH3:14]>>[CH:11]1=[N:10][CH2:2][CH2:1][c:8]2[cH:9][c:12]([O:13][CH3:14])[c:5]([cH:6][c:7]12)[O:4][CH3:3]


COc1ccc(CCNC=O)cc1OC>>COc1cc2c(cc1OC)CCN=C2
[O:15]=[CH:1][NH:2][CH2:3][CH2:4][c:5]1[cH:6][cH:7][c:8]([O:9][CH3:10])[c:11]([O:12][CH3:13])[cH:14]1>>[CH:1]1=[N:2][CH2:3][CH2:4][c:5]2[cH:14][c:11]([O:12][CH3:13])[c:8]([O:9][CH3:10])[cH:7][c:6]12

I forgot to hidden the explicit hydrogen atoms. The mapped rxn is


[CH2:1]([CH2:2][NH:10][CH:11]=[O:21])[c:8]1[cH:7][cH:6][c:5]([O:4][CH3:3])[c:12]([cH:9]1)[O:13][CH3:14]>>[CH:11]1=[N:10][CH2:2][CH2:1][c:8]2[cH:9][c:12]([O:13][CH3:14])[c:5]([cH:6][c:7]12)[O:4][CH3:3]

run the command

python find_reaction_center_eval.py --test-path  2.rxns -np 1

it reports error

Traceback (most recent call last):
  File "find_reaction_center_eval.py", line 83, in <module>
    main(args)
  File "find_reaction_center_eval.py", line 29, in main
    load=args['load'])
  File "/home/zgong/nfs/program/anaconda2/envs/py36dgllifesci/lib/python3.6/site-packages/dgllife/data/uspto.py", line 395, in __init__
    self.load_reaction_data(path_to_reaction_file, num_processes)
  File "/home/zgong/nfs/program/anaconda2/envs/py36dgllifesci/lib/python3.6/site-packages/dgllife/data/uspto.py", line 452, in load_reaction_data
    mol, reaction, graph_edits = load_one_reaction(li)
  File "/home/zgong/nfs/program/anaconda2/envs/py36dgllifesci/lib/python3.6/site-packages/dgllife/data/uspto.py", line 331, in load_one_reaction
    atom_map_order[atom.GetIntProp('molAtomMapNumber') - 1] = j
IndexError: list assignment index out of range

aftre cannoical rxn, the problem will be solved!

[O:15]=[CH:1][NH:2][CH2:3][CH2:4][c:5]1[cH:6][cH:7][c:8]([O:9][CH3:10])[c:11]([O:12][CH3:13])[cH:14]1>>[CH:1]1=[N:2][CH2:3][CH2:4][c:5]2[cH:14][c:11]([O:12][CH3:13])[c:8]([O:9][CH3:10])[cH:7][c:6]12
@mufeili
Copy link
Contributor

mufeili commented Jul 1, 2020

The issue was addressed in #36 .

@mufeili mufeili closed this as completed Jul 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants