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

Planning for the transition to metatomic #2

Open
11 tasks
Luthaf opened this issue Jan 28, 2025 · 0 comments
Open
11 tasks

Planning for the transition to metatomic #2

Luthaf opened this issue Jan 28, 2025 · 0 comments

Comments

@Luthaf
Copy link
Member

Luthaf commented Jan 28, 2025

The code for atomistic models used to live in https://github.com/metatensor/metatensor, as part of the metatensor-torch package. We would like to separate it into a separate package (working name metatomic) to make the separation between the data storage and atomistic interface clearer.

This will also be the opportunity to make the model interface a bit more abstract and not reliant on TorchScript. TorchScript models will still be supported, but will only be one option among others (including e.g. pure python models or pure C++ models).

To minimize churn and user pain, here is a plan for the transition:

Phase 1: bring the new git repository up to speed

  • integrate with codecov for code coverage
  • make a first release of the metatomic and metatomic-torch Python packages
  • move issues from the metatensor repository

I'm not sure about the following: doing it early might help smooth the transition down the line, but could have unforseen issues with TorchScript

  • rename classes (MetatensorAtomisticModel => MetatomicModel; NeighborListOptions => PairListOptions; …). We will want to do this at some point anyway, and if we can re-export them with a different name in metatensor.torch.atomistic that should make the transition smoother (models exported with metatensor.torch.atomistic will work with metatomic).

Phase 3: Update engine to use metatomic

Before we can have model rely on the metatomic code, we will need to update all the simulation engine to use the new metatomic library

  • LAMMPS
  • PLUMED
  • i-PI
  • chemiscope

This update would still use the TorchScript version of the models directly, abstracting away from this will be done later down the line.

Phase 2: re-export metatomic.torch from metatensor.torch.atomistic

  • remove the code from metatensor-torch, and add a dependency on metatomic-torch there. Then metatensor.torch.atomistic can re-export the classes from metatomic.torch; giving source compatibility to most of the existing code. This re-export should also have a deprecation warning pointing people to use metatomic instead

Phase 4: Remove from metatensor-torch

  • After a while, remove the deprecated code from metatensor-torch

Not part of the transition, but required anyway

  • write developer documentation
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

1 participant