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

[Bug]: 0.3.8 calls deprecated pymatgen Elementbase while 0.4.0 too restrictive on torch>=2.4.1 #221

Open
2 of 4 tasks
chiang-yuan opened this issue Jan 2, 2025 · 1 comment
Labels
bug Something isn't working

Comments

@chiang-yuan
Copy link

Email (Optional)

No response

Version

v0.3.8

Which OS(es) are you using?

  • MacOS
  • Windows
  • Linux

What happened?

chgnet==0.3.8 seems to call deprecated pymatgen Elementbase and breaks the test from 2025-01-01. See pytest on mlip-arena.

I tried to upgrade to chgnet==0.4.0 but found it too restrictive on torch>=2.4.1 and becomes incompatible with other packages. Is it possible to loosen the version pin on pytorch?

tags @janosh for awareness on monty and pymatgen side

Code snippet

No response

Log output

/opt/hostedtoolcache/Python/3.11.11/x64/lib/python3.11/site-packages/chgnet/model/__init__.py:3: in <module>
    from chgnet.model.dynamics import CHGNetCalculator, MolecularDynamics, StructOptimizer
/opt/hostedtoolcache/Python/3.11.11/x64/lib/python3.11/site-packages/chgnet/model/dynamics.py:24: in <module>
    from pymatgen.analysis.eos import BirchMurnaghan
/opt/hostedtoolcache/Python/3.11.11/x64/lib/python3.11/site-packages/pymatgen/analysis/eos.py:24: in <module>
    from pymatgen.util.plotting import add_fig_kwargs, get_ax_fig, pretty_plot
/opt/hostedtoolcache/Python/3.11.11/x64/lib/python3.11/site-packages/pymatgen/util/plotting.py:16: in <module>
    from pymatgen.core import Element
/opt/hostedtoolcache/Python/3.11.11/x64/lib/python3.11/site-packages/pymatgen/core/__init__.py:12: in <module>
    from pymatgen.core.composition import Composition
/opt/hostedtoolcache/Python/3.11.11/x64/lib/python3.11/site-packages/pymatgen/core/composition.py:22: in <module>
    from pymatgen.core.periodic_table import DummySpecies, Element, ElementType, Species, get_el_sp
/opt/hostedtoolcache/Python/3.11.11/x64/lib/python3.11/site-packages/pymatgen/core/periodic_table.py:63: in <module>
    class ElementBase(Enum):
/opt/hostedtoolcache/Python/3.11.11/x64/lib/python3.11/site-packages/pymatgen/core/periodic_table.py:751: in ElementBase
    @deprecated(
/opt/hostedtoolcache/Python/3.11.11/x64/lib/python3.11/site-packages/monty/dev.py:157: in deprecated
    raise_deadline_warning()
/opt/hostedtoolcache/Python/3.11.11/x64/lib/python3.11/site-packages/monty/dev.py:86: in raise_deadline_warning
    raise DeprecationWarning(
E   DeprecationWarning: This function should have been removed on 2025-01-01.

Code of Conduct

  • I agree to follow this project's Code of Conduct
@chiang-yuan chiang-yuan added the bug Something isn't working label Jan 2, 2025
@chiang-yuan
Copy link
Author

the problem arises from deprecated is_rare_earth_meal property in pymatgen ElementBase. Should be fixed after its removal. materialsproject/pymatgen#4243

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant