Skip to content

Commit 788f216

Browse files
committed
installation instructions
1 parent 0b6d370 commit 788f216

File tree

7 files changed

+37
-11
lines changed

7 files changed

+37
-11
lines changed

.github/workflows/run_pytest.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ jobs:
3636
pip install --no-cache-dir git+https://github.com/i-pi/i-pi.git@v3.0.0-beta4
3737
pip install torch==2.5.1
3838
pip install git+https://github.com/acesuit/MACE.git@v0.3.5
39-
apptainer exec oras://ghcr.io/molmod/cp2k:2024.1 ls
39+
apptainer exec docker://cp2k/cp2k:2025.2_mpich_x86_64_psmp ls
4040
apptainer exec oras://ghcr.io/molmod/gpaw:24.1 ls
4141
- name: Checkout specific commit
4242
uses: actions/checkout@v4

install_local.sh

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# Create a psiflow installation including ModelTraining and ModelEvaluation dependencies
2+
3+
ENV_NAME="psiflow-dev"
4+
micromamba env create -n $ENV_NAME python=3.14 -c conda-forge
5+
micromamba activate $ENV_NAME
6+
7+
# install workqueue
8+
micromamba install ndcctools -c conda-forge
9+
10+
# install psiflow
11+
pip install -e psiflow[dev]
12+
13+
# install PyTorch and MACE
14+
pip install torch --index-url https://download.pytorch.org/whl/cu128
15+
pip install mace-torch
16+
pip install cuequivariance cuequivariance-torch cuequivariance-ops-torch-cu12
17+
18+
# install basic PLUMED and python API
19+
micromamba install plumed -c conda-forge
20+
pip install plumed
21+
22+
# make PLUMED visible to the py-plumed interface
23+
PLUMED_KERNEL="$CONDA_PREFIX/lib/libplumedKernel.so"
24+
echo "{\"env_vars\": {\"PLUMED_KERNEL\": \"$PLUMED_KERNEL\"}}" >> "$CONDA_PREFIX/conda-meta/state"
25+
26+
# install simple-dftd3
27+
micromamba install simple-dftd3 dftd3-python -c conda-forge
28+
29+
# install cp2k-input-tools
30+
# (its dependencies are a right mess, so we fix some and pip will complain)
31+
pip install cp2k-input-tools
32+
pip install --force-reinstall Pint

psiflow/execution.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -546,10 +546,6 @@ def multi_gpu(self) -> bool:
546546
# only for WQ
547547
return (self.spec or {}).get("gpus", 0) > 1
548548

549-
def train_command(self, initialize: bool = False):
550-
command = "psiflow-mace-train"
551-
return self.wrap_in_timeout(command)
552-
553549
def wq_resources(self, *args, **kwargs) -> dict:
554550
if self.spec is None:
555551
return {} # threadpool

psiflow/functions.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,7 @@ def __call__(
177177

178178
@dataclass(frozen=True)
179179
class MACEFunction(Function):
180+
# TODO: why are some arguments separated and others 'calc_kwargs'?
180181
model_path: str | Path
181182
ncores: int
182183
device: str

psiflow/models/mace.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,16 @@
33
import logging
44
from pathlib import Path
55
from enum import StrEnum
6-
from typing import Optional, Callable, Any
6+
from typing import Optional, Any
77
from collections.abc import Sequence
8-
from functools import partial
98

109
import ase
1110
import ase.io
1211
import yaml
1312
import parsl
1413
from ase.data import atomic_numbers
1514
from parsl import bash_app, python_app, File, join_app
16-
from parsl.dataflow.futures import AppFuture, DataFuture, Future
15+
from parsl.dataflow.futures import AppFuture, Future
1716

1817
import psiflow
1918
from psiflow.data import Dataset

psiflow/reference/gpaw_.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ def parse_output(stdout: str, properties: Sequence[str]) -> dict:
4949
@psiflow.register_serializable
5050
class GPAW(Reference):
5151
executor: str = "GPAW"
52-
_execute_label = "gpaw_singlepoint"
52+
_execute_label: str = "gpaw_singlepoint"
5353
parameters: dict
5454
script: str
5555

@@ -59,7 +59,6 @@ def __init__(self, parameters: dict, script: str | Path = FILEPATH, **kwargs):
5959
assert (script := Path(script)).is_file()
6060
self.script = str(script.resolve()) # absolute path
6161
self.bash_template = make_bash_template(self.executor, self.script)
62-
print(self.bash_template)
6362

6463
def compute_atomic_energy(self, element, box_size=None) -> AppFuture:
6564
return copy_app_future(0.0) # GPAW computes formation energy by default

psiflow/sampling/sampling.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
from parsl.app.app import bash_app
1010
from parsl.data_provider.files import File
1111
from parsl.dataflow.futures import AppFuture, DataFuture
12-
from sympy import print_glsl
1312

1413
import psiflow
1514
from psiflow.data import Dataset

0 commit comments

Comments
 (0)