Open gaole1111 opened 7 months ago
Hello, how to solve this problem
Hi, it seems like the pymatgen
package is not installed in your current environment, according to the error:
ModuleNotFoundError: No module named 'pymatgen.core'
You could install it by
pip install pymatgen==2022.9.21
Hi, we find that downloading the 2022.9.21
version of pymatgen
via pip would encounter an error now. An available and compatible version is 2023.8.10
. You could try again with
pip install pymatgen==2023.8.10
Thanks quite a lot for pointing out the problem!
(gl) root@ubuntu:/data2/gl/DiffCSP-main# python diffcsp/run.py data=perov_5 expname=test1
Global seed set to 42
[2024-03-08 16:56:18,016][hydra.utils][INFO] - Instantiating
Hi, could you please provide more details about your environment? This will help us reproduce the error and offer a solution.
Could you export the minimal Conda environment leading to the segmentation fault and share it with us? You can do this by running the following command:
conda env export > env.yaml
Once you've done that, please paste the contents of env.yaml
here. With this information, we'll be better equipped to diagnose and resolve the problem you're facing.
(gl) root@ubuntu:/data2/gl/DiffCSP-main# python diffcsp/run.py data=perov_5 expname=test1 Global seed set to 42 [2024-03-08 16:56:18,016][hydra.utils][INFO] - Instantiating
Segmentation fault
I have the same problem as you, have you solved it and can you reply me, thanks a lot!
(gl) root@ubuntu:/data2/gl/DiffCSP-main# python diffcsp/run.py data=perov_5 expname=reproduction_diffcsp_perov diffcsp/run.py:172: UserWarning: The version_base parameter is not specified. Please specify a compatability version level, or None. Will assume defaults for version 1.1 @hydra.main(config_path=str(PROJECT_ROOT / "conf"), config_name="default") /data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/defaults_list.py:251: UserWarning: In 'default': Defaults list is missing
Error executing job with overrides: ['data=perov_5', 'expname=reproduction_diffcsp_perov']
Traceback (most recent call last):
File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/utils.py", line 644, in _locate
obj = getattr(obj, part)
AttributeError: module 'diffcsp.pl_data' has no attribute 'datamodule'
_self_
. See https://hydra.cc/docs/1.2/upgrades/1.0_to_1.1/default_composition_order for more information warnings.warn(msg, UserWarning) /data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/hydra.py:119: UserWarning: Future Hydra versions will no longer change working directory at job runtime by default. See https://hydra.cc/docs/1.2/upgrades/1.1_to_1.2/changes_to_job_working_dir/ for more information. ret = run_job( Global seed set to 42 [2024-03-06 20:05:23,548][hydra.utils][INFO] - InstantiatingDuring handling of the above exception, another exception occurred:
Traceback (most recent call last): File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/utils.py", line 650, in _locate obj = import_module(mod) File "/data1/anaconda3/envs/gl/lib/python3.8/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1014, in _gcd_import
File "", line 991, in _find_and_load
File "", line 975, in _find_and_load_unlocked
File "", line 671, in _load_unlocked
File "", line 843, in exec_module
File "", line 219, in _call_with_frames_removed
File "/data2/gl/DiffCSP-main/./diffcsp/pl_data/datamodule.py", line 15, in
from diffcsp.common.data_utils import get_scaler_from_data_list
File "/data2/gl/DiffCSP-main/./diffcsp/common/data_utils.py", line 8, in
from pymatgen.core.structure import Structure
ModuleNotFoundError: No module named 'pymatgen.core'
The above exception was the direct cause of the following exception:
Traceback (most recent call last): File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/instantiate/_instantiate2.py", line 134, in _resolve_target target = _locate(target) File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/utils.py", line 653, in _locate raise ImportError( ImportError: Error loading 'diffcsp.pl_data.datamodule.CrystDataModule': ModuleNotFoundError("No module named 'pymatgen.core'") Are you sure that 'datamodule' is importable from module 'diffcsp.pl_data'?
The above exception was the direct cause of the following exception:
Traceback (most recent call last): File "diffcsp/run.py", line 178, in
main()
File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/main.py", line 94, in decorated_main
_run_hydra(
File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/utils.py", line 394, in _run_hydra
_run_app(
File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/utils.py", line 457, in _run_app
run_and_report(
File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/utils.py", line 223, in run_and_report
raise ex
File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/utils.py", line 220, in run_and_report
return func()
File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/utils.py", line 458, in
lambda: hydra.run(
File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/internal/hydra.py", line 132, in run
= ret.return_value
File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/core/utils.py", line 260, in return_value
raise self._return_value
File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/core/utils.py", line 186, in run_job
ret.return_value = task_function(task_cfg)
File "diffcsp/run.py", line 174, in main
run(cfg)
File "diffcsp/run.py", line 93, in run
datamodule: pl.LightningDataModule = hydra.utils.instantiate(
File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/instantiate/_instantiate2.py", line 226, in instantiate
return instantiate_node(
File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/instantiate/_instantiate2.py", line 333, in instantiate_node
target = _resolve_target(node.get(_Keys.TARGET), full_key)
File "/data1/anaconda3/envs/gl/lib/python3.8/site-packages/hydra/_internal/instantiate/_instantiate2.py", line 139, in _resolve_target
raise InstantiationException(msg) from e
hydra.errors.InstantiationException: Error locating target 'diffcsp.pl_data.datamodule.CrystDataModule', set env var HYDRA_FULL_ERROR=1 to see chained exception.
full_key: data.datamodule