From ecb1f701ae0ce940c5b1436fd34ab036d0412284 Mon Sep 17 00:00:00 2001 From: Marcin Dulak Date: Sun, 13 Oct 2024 12:42:08 +0200 Subject: [PATCH] Release gpaw-24.6.0-1 --- .github/workflows/main.yml | 2 +- Dockerfile | 6 +++--- docker-compose.ci.yml | 3 +-- docker-compose.myjob.yml | 3 +-- docker-compose.test.yml | 5 ++--- myjob/h2.py | 2 +- 6 files changed, 9 insertions(+), 12 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index de5f5d6..ace1d88 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -32,4 +32,4 @@ jobs: - name: test the image run: | set -eo pipefail - docker-compose -f docker-compose.ci.yml up --exit-code-from gpaw + docker compose -f docker-compose.ci.yml up --exit-code-from gpaw diff --git a/Dockerfile b/Dockerfile index 1bd12aa..6efd331 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ # Discover the sha by removing the @sha part and running: timeout 5 docker buildx build --pull --no-cache . -# Dockerhub used to not show the overall sha https://github.com/docker/roadmap/issues/262 -FROM fedora:40@sha256:5ce8497aeea599bf6b54ab3979133923d82aaa4f6ca5ced1812611b197c79eb0 +# Alternatively find the sha in Dockerhub UI https://github.com/docker/roadmap/issues/262 +FROM fedora:40@sha256:d0207dbb078ee261852590b9a8f1ab1f8320547be79a2f39af9f3d23db33735e # https://docs.docker.com/engine/reference/builder/#automatic-platform-args-in-the-global-scope ARG TARGETPLATFORM @@ -13,7 +13,7 @@ RUN echo uname -m $(uname -m) LABEL name="GPAW Openmpi" \ url="https://wiki.fysik.dtu.dk/gpaw/" -ENV GPAW_VERSION 24.1.0 +ENV GPAW_VERSION 24.6.0 ENV FEDORA_RELEASE 1.fc40 RUN set -x \ diff --git a/docker-compose.ci.yml b/docker-compose.ci.yml index d7aaf28..2752871 100644 --- a/docker-compose.ci.yml +++ b/docker-compose.ci.yml @@ -1,4 +1,3 @@ -version: '3' services: gpaw: image: 'gpaw-openmpi:latest' @@ -12,6 +11,6 @@ services: module use /usr/share/modulefiles module load mpi/openmpi cd /mnt - export PYTHONPATH=$MPI_PYTHON3_SITEARCH + export PYTHONPATH=$$MPI_PYTHON3_SITEARCH export OMP_NUM_THREADS=1 mpiexec --allow-run-as-root -np 1 python3 h2.py && grep "Free energy" h2.txt diff --git a/docker-compose.myjob.yml b/docker-compose.myjob.yml index 03e4b1b..10a7ce8 100644 --- a/docker-compose.myjob.yml +++ b/docker-compose.myjob.yml @@ -1,4 +1,3 @@ -version: '3' services: gpaw: image: 'marcindulak/gpaw-openmpi:latest' @@ -12,6 +11,6 @@ services: module use /usr/share/modulefiles module load mpi/openmpi cd /mnt - export PYTHONPATH=$MPI_PYTHON3_SITEARCH + export PYTHONPATH=$$MPI_PYTHON3_SITEARCH export OMP_NUM_THREADS=1 mpiexec --allow-run-as-root -np 2 python3 h2.py && grep "Free energy" h2.txt diff --git a/docker-compose.test.yml b/docker-compose.test.yml index d91da14..3742741 100644 --- a/docker-compose.test.yml +++ b/docker-compose.test.yml @@ -1,4 +1,3 @@ -version: '3' services: sut: build: . @@ -9,7 +8,7 @@ services: . /etc/profile.d/modules.sh module use /usr/share/modulefiles module load mpi/openmpi - export PYTHONPATH=$MPI_PYTHON3_SITEARCH + export PYTHONPATH=$$MPI_PYTHON3_SITEARCH export OMP_NUM_THREADS=1 python3 -c "import gpaw.mpi; print(gpaw.mpi.rank)" cat <<'EOF' > h2.py @@ -17,7 +16,7 @@ services: from gpaw import GPAW, PW h2 = Atoms('H2', [(0, 0, 0), (0, 0, 0.74)]) h2.center(vacuum=2.5) - h2.set_calculator(GPAW(xc='PBE', mode=PW(300), txt='h2.txt')) + h2.calc = GPAW(xc='PBE', mode=PW(300), txt='h2.txt') h2.get_potential_energy() h2.get_forces() EOF diff --git a/myjob/h2.py b/myjob/h2.py index e80b147..1c47346 100644 --- a/myjob/h2.py +++ b/myjob/h2.py @@ -2,6 +2,6 @@ from gpaw import GPAW, PW h2 = Atoms('H2', [(0, 0, 0), (0, 0, 0.74)]) h2.center(vacuum=2.5) -h2.set_calculator(GPAW(xc='PBE', mode=PW(300), txt='h2.txt')) +h2.calc = GPAW(xc='PBE', mode=PW(300), txt='h2.txt') h2.get_potential_energy() h2.get_forces()