UFP Documentation

UFP is a Torch-first library for building, fitting, and using interatomic potentials from composable energy terms. It keeps ASE and simulation-engine objects at the boundary, then evaluates models on normalized torch tensors.

The documentation is organized around the main decisions a user or developer needs to make:

What UFP Provides

  • A shared UFPInput representation for atoms, cells, periodic flags, and neighbor lists.

  • Additive UFPModel objects built from one-body, pair, spline, three-body, four-body, repulsion, and alchemical terms.

  • Two fitting paths: direct linear least squares for coefficient-linear models and PyTorch training for differentiable models.

  • ASE calculator support, metatomic wrappers, torch-sim wrappers, and optional native C++/CUDA acceleration for selected three-body paths.

Units

UFP does not impose a unit registry. Most examples and ASE workflows use angstroms for length and electron volts for energy. Forces then have units of energy per length, typically eV/angstrom. Keep units consistent across input structures, fitted coefficients, and labels.