-
Notifications
You must be signed in to change notification settings - Fork 215
Closed
Labels
documentationImprovements or additions to documentationImprovements or additions to documentation
Description
Dear everyone,
I have install torchdrug correctly, and then follow the tutorial https://torchdrug.ai/docs/tutorials/retrosynthesis.html
When I run the code as below:
from torchdrug import datasets
reaction_dataset = datasets.USPTO50k("D:/test/molecule-datasets/",
node_feature="reaction_reaction_identification",
kekulize=True)
synthon_dataset = datasets.USPTO50k("D:/test/molecule-dataset/", as_synthon=True,
node_feature="synthon_completion",
kekulize=True)It happens error as follows:
Loading D:/test/molecule-datasets/data_processed.csv: 100%|██████████| 50017/50017 [00:00<00:00, 92358.37it/s]
Constructing molecules from SMILES: 0%| | 0/50016 [00:00<?, ?it/s]
Traceback (most recent call last):
File "F:/workdir/pycharm/Retrosynthesis/main.py", line 5, in <module>
kekulize=True)
File "D:\soft\Anaconda3\envs\py37\lib\site-packages\decorator.py", line 232, in fun
return caller(func, *(extras + args), **kw)
File "D:\soft\Anaconda3\envs\py37\lib\site-packages\torchdrug-0.1.0-py3.7.egg\torchdrug\core\core.py", line 282, in wrapper
return init(self, *args, **kwargs)
File "D:\soft\Anaconda3\envs\py37\lib\site-packages\torchdrug-0.1.0-py3.7.egg\torchdrug\datasets\uspto50k.py", line 63, in __init__
**kwargs)
File "D:\soft\Anaconda3\envs\py37\lib\site-packages\torchdrug-0.1.0-py3.7.egg\torchdrug\data\dataset.py", line 112, in load_csv
self.load_smiles(smiles, targets, verbose=verbose, **kwargs)
File "D:\soft\Anaconda3\envs\py37\lib\site-packages\torchdrug-0.1.0-py3.7.egg\torchdrug\data\dataset.py", line 232, in load_smiles
mol = data.Molecule.from_molecule(mol, **kwargs)
File "D:\soft\Anaconda3\envs\py37\lib\site-packages\torchdrug-0.1.0-py3.7.egg\torchdrug\data\molecule.py", line 183, in from_molecule
func = R.get("features.atom.%s" % name)
File "D:\soft\Anaconda3\envs\py37\lib\site-packages\torchdrug-0.1.0-py3.7.egg\torchdrug\core\core.py", line 208, in get
raise KeyError("Can't find `%s` in `%s`" % (key, ".".join(keys[:i])))
KeyError: "Can't find `reaction_reaction_identification` in `features.atom`"what is the problem? could you help me to solve it?
Thanks.
Metadata
Metadata
Assignees
Labels
documentationImprovements or additions to documentationImprovements or additions to documentation