PET-MAD (UPET Backend)¶
Optional dependency
PetMadCalculator requires the petmad extra.
PetMadCalculator
¶
PetMadCalculator(
model: str = "pet-mad-s",
version: str = "latest",
checkpoint_path: str | None = None,
device: Literal["cuda", "cpu", "mps"] = "cpu",
**kwargs: Any,
)
Calculator for material property calculations and structure relaxation using PET-MAD models served by UPET.
Attributes:
| Name | Type | Description |
|---|---|---|
AVAILABLE_PROPERTIES |
list[str]
|
A list of properties that this calculator can compute, including "energy", "forces", and "stresses". |
References
- UPET: https://github.com/lab-cosmo/upet
Initializes the PetMadCalculator with the specified model and calculation settings.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model
|
str
|
PET-MLIP model to use. Default is "pet-mad-s". Ignored if |
'pet-mad-s'
|
version
|
str
|
Version of the model to use. Default is "latest". Ignored if |
'latest'
|
checkpoint_path
|
str
|
Path to the model checkpoint file. If not provided, the model will be downloaded using the "version" parameter. |
None
|
device
|
Literal['cuda', 'cpu', 'mps']
|
The device to use for calculations. Defaults to "cpu". |
'cpu'
|
**kwargs
|
Any
|
Additional keyword arguments passed to the |
{}
|
calculator
¶
Lazily builds the ASE Calculator object for the PET-MAD model, using UPET.
Returns:
| Name | Type | Description |
|---|---|---|
Calculator |
Calculator
|
The ASE Calculator object configured via UPET. |