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

Problem on Prediction #2

Open
LTJer opened this issue Jan 24, 2023 · 4 comments
Open

Problem on Prediction #2

LTJer opened this issue Jan 24, 2023 · 4 comments

Comments

@LTJer
Copy link

LTJer commented Jan 24, 2023

I am trying running a prediction job through the whole "surface_DOS_dataset" and the "Surf_model.pth" in the 'saved_models' folder

command:
python main.py --data_path='../surface_DOS_dataset/' --model_path='Surf_model.pth' --run_mode='Predict'

The modifications in config file:

LMBTR_descriptor: "False" 
SOAP_descriptor: "False"

error message:

File "main.py", line 508, in <module>
    main()
  File "main.py", line 301, in main
    dataset, config["Training"]["loss"], config["Job"]
  File "/u/au/sa/liutsungwei/scratch/DOS/MatDeepLearn_DOS/matdeeplearn/training/training.py", line 663, in predict
    dos_out, scaling = model(data)
  File "/u/au/sa/liutsungwei/scratch/conda/envs/MDL/lib/python3.7/site-packages/torch/nn/modules/module.py", line 889, in _call_impl
    result = self.forward(*input, **kwargs)
  File "/u/au/sa/liutsungwei/scratch/DOS/MatDeepLearn_DOS/matdeeplearn/models/dospredict.py", line 114, in forward
    out = self.conv_list[i](out, data.edge_index, data.edge_attr)
  File "/u/au/sa/liutsungwei/scratch/conda/envs/MDL/lib/python3.7/site-packages/torch/nn/modules/module.py", line 889, in _call_impl
    result = self.forward(*input, **kwargs)
  File "/u/au/sa/liutsungwei/scratch/DOS/MatDeepLearn_DOS/matdeeplearn/models/dospredict.py", line 253, in forward
    out = self.propagate(edge_index, x=x, edge_attr=edge_attr, size=size)
  File "/u/au/sa/liutsungwei/scratch/conda/envs/MDL/lib/python3.7/site-packages/torch_geometric/nn/conv/message_passing.py", line 454, in propagate
    out = self.aggregate(out, **aggr_kwargs)
  File "/u/au/sa/liutsungwei/scratch/conda/envs/MDL/lib/python3.7/site-packages/torch_geometric/nn/conv/message_passing.py", line 578, in aggregate
    return self.aggr_module(inputs, index, ptr=ptr, dim_size=dim_size,
  File "/u/au/sa/liutsungwei/scratch/conda/envs/MDL/lib/python3.7/site-packages/torch/nn/modules/module.py", line 948, in __getattr__
    type(self).__name__, name))
AttributeError: 'GC_block' object has no attribute 'aggr_module'

Is there anything wrong with my input? or command?

Thanks a lot

@LTJer LTJer changed the title Problem on Predict Model Problem on Prediction Jan 24, 2023
@vxfung
Copy link
Owner

vxfung commented Jan 25, 2023

Looks like it may be something wrong on the pytorch geometric end - perhaps the version is not right. What is your current version?

@LTJer
Copy link
Author

LTJer commented Jan 25, 2023

Here are versions of torch relevant packages from my env

torch                1.8.0
torch-cluster        1.6.0
torch-geometric      2.2.0
torch-scatter        2.1.0
torch-sparse         0.6.12
torch-spline-conv    1.2.1
torchvision          0.9.0

@vxfung
Copy link
Owner

vxfung commented Jan 25, 2023

The package was tested on torch-geometric 1.7.0 so you may try to see if it helps if you downgrade torch-geometric to the appropriate version. A version of the code which is compatible with the newest torch-geometric is being developed, however it may need some more time to complete.

@LTJer
Copy link
Author

LTJer commented Feb 7, 2023

Thanks for your reply and patience.
Unfortunately, after I tried several different methods, my system could not accommodate the geometric 1.7.0.
Looking forward to the new version update.

Best~

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