hghcomphys / pantea

A Python library for developing machine learning interatomic potentials, based on Google JAX.

Home Page:https://pantea.readthedocs.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Check jit static/dynamic attributes for a dataclass

hghcomphys opened this issue · comments

Finding the static and dynamic attributes of some data classes (e.g. structure, cutoff function, and symmetry functions) is based on defined BaseJaxPytreeDataClass. An additional checking when initializing those class ensures attributes are identified correctly.

A "_assert_jit_attributes" method was added to BaseJaxPytreeDataClass and was used in post init method of derived data classes.