MACE Inference¶
What is MACE Inference?¶
MACE Inference is a user-friendly Python library that provides a high-level interface for performing atomistic simulations using MACE machine learning interatomic potentials.
Instead of writing complex setup code, you can perform common computational chemistry tasks with just a few lines:
from mace_inference import MACEInference
from ase.io import read
# Initialize calculator
calc = MACEInference(model="medium", device="auto")
# Load structure and calculate
atoms = read("structure.cif")
result = calc.single_point(atoms)
print(f"Energy: {result['energy']:.4f} eV")
print(f"Max force: {result['max_force']:.4f} eV/Å")
Key Features¶
-
Easy to Use
Simple, intuitive API for common atomistic simulation tasks
-
Comprehensive Tasks
Single-point, optimization, MD, phonons, mechanics, adsorption
-
GPU Accelerated
Automatic device detection with CUDA/MPS support
-
D3 Correction
Optional DFT-D3 dispersion correction for van der Waals systems
Supported Tasks¶
| Task | Method | Description |
|---|---|---|
| Single-point | single_point() |
Calculate energy, forces, stress |
| Optimization | optimize() |
Geometry relaxation with BFGS/FIRE |
| NVT MD | run_md() |
Constant temperature dynamics |
| NPT MD | run_md() |
Constant pressure dynamics |
| Phonons | phonon() |
Phonon spectrum & thermal properties |
| Bulk Modulus | bulk_modulus() |
Elastic properties via EOS fitting |
| Adsorption | adsorption_energy() |
Gas-framework binding energy |
| Coordination | coordination() |
Coordination number analysis |
Quick Links¶
-
Get started by installing MACE Inference
-
Learn the basics with a simple example
-
Detailed guides for each feature
-
Complete API documentation
Requirements¶
- Python 3.9+
- ASE (Atomic Simulation Environment)
- mace-torch
- phonopy (for phonon calculations)
- torch-dftd (optional, for D3 correction)
License¶
MACE Inference is released under the MIT License. See LICENSE for details.