MaterSim / PyXtal

A code to generate atomic structure with symmetry
MIT License
269 stars 68 forks source link

pyxtal().from_seed fails for some structures #246

Closed kazeevn closed 8 months ago

kazeevn commented 8 months ago

Hello! pyxtal().from_seed fails to read some structures with the following error message: Cannot extract the right mapping from spglib. I'm attaching a script to reproduce the issue, and the structures in question. The issue is only showing for some values of tol . Naively that might be caused by float arithmetic issues or pyxtal's definition of tolerance being different from spglib's. pyxtal_from_seed_reproduction.zip

tol=0.1 is a particularly important value, as it's used by the Materials Project Libraries versions:

pyxtal==0.6.3
spglib==2.3.1
pymatgen==2023.12.18

Full pip freeze is attached. requirements.txt

Appreciate your work on the library, and hope for a resolution.

qzhu2017 commented 8 months ago

@kazeevn Thanks for your report. This should be resolved after https://github.com/qzhu2017/PyXtal/commit/e489ebbfb299c374894a577dc96b371f4ca5fa69 Can you try

 pip install --upgrade git+https://github.com/qzhu2017/PyXtal.git@master

and then rerun your examples? Feel free to run more examples if you have.

kazeevn commented 8 months ago

Thank you! The attached structures were loaded successfully. I've also successfully loaded the whole MP-20 dataset.