Skip to content

Commit 8b7ffb6

Browse files
Merge pull request #67 from microsoft/hanyang/update-deps
dep: update deps
2 parents b340f4f + 88cf9a3 commit 8b7ffb6

File tree

3 files changed

+13
-10
lines changed

3 files changed

+13
-10
lines changed

README.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,6 @@ To install the package, run the following command under the root of the folder:
7070
mamba env create -f environment.yaml
7171
mamba activate mattersim
7272
uv pip install -e .
73-
python setup.py build_ext --inplace
7473
```
7574

7675
## Pre-trained Models
@@ -96,20 +95,21 @@ and additional materials capabilities are available in
9695
### A minimal test
9796
```python
9897
import torch
98+
from loguru import logger
9999
from ase.build import bulk
100100
from ase.units import GPa
101101
from mattersim.forcefield import MatterSimCalculator
102102

103103
device = "cuda" if torch.cuda.is_available() else "cpu"
104-
print(f"Running MatterSim on {device}")
104+
logger.info(f"Running MatterSim on {device}")
105105

106106
si = bulk("Si", "diamond", a=5.43)
107107
si.calc = MatterSimCalculator(device=device)
108-
print(f"Energy (eV) = {si.get_potential_energy()}")
109-
print(f"Energy per atom (eV/atom) = {si.get_potential_energy()/len(si)}")
110-
print(f"Forces of first atom (eV/A) = {si.get_forces()[0]}")
111-
print(f"Stress[0][0] (eV/A^3) = {si.get_stress(voigt=False)[0][0]}")
112-
print(f"Stress[0][0] (GPa) = {si.get_stress(voigt=False)[0][0] / GPa}")
108+
logger.info(f"Energy (eV) = {si.get_potential_energy()}")
109+
logger.info(f"Energy per atom (eV/atom) = {si.get_potential_energy()/len(si)}")
110+
logger.info(f"Forces of first atom (eV/A) = {si.get_forces()[0]}")
111+
logger.info(f"Stress[0][0] (eV/A^3) = {si.get_stress(voigt=False)[0][0]}")
112+
logger.info(f"Stress[0][0] (GPa) = {si.get_stress(voigt=False)[0][0] / GPa}")
113113
```
114114

115115
In this release, we provide two checkpoints: `MatterSim-v1.0.0-1M.pth` and `MatterSim-v1.0.0-5M.pth`. By default, the `1M` version is loaded.

environment.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ dependencies:
66
- ca-certificates
77
- openssl
88
- numpy<2
9-
- phonopy==2.14.0
10-
- phono3py==2.3.0
9+
- phonopy
10+
- phono3py
1111
- cython>=0.29.32
1212
- setuptools>=45
1313
- wheel

pyproject.toml

+4-1
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,12 @@ dependencies = [
2929
"ase>=3.23.0",
3030
"azure-identity",
3131
"azure-storage-blob",
32+
"scikit-learn",
3233
"deprecated",
3334
"e3nn>=0.5.0",
34-
"emmet-core>=0.84",
35+
"atomate2",
36+
"emmet-core>=0.84; python_version >= '3.10'",
37+
"emmet-core<0.84; python_version < '3.10'",
3538
"loguru",
3639
"mp-api",
3740
"numpy<2",

0 commit comments

Comments
 (0)