From 72f459f805dad43542e22d995426123e53095145 Mon Sep 17 00:00:00 2001 From: Jan Janssen Date: Fri, 28 Jun 2024 11:01:19 +0200 Subject: [PATCH 1/3] use PYIRON_CORES and PYIRON_THREADS --- damask/bin/run_damask_3.0.0.sh | 2 +- damask/bin/run_damask_3.0.0_mpi.sh | 2 +- lammps/bin/run_lammps_2020.03.03.sh | 2 -- lammps/bin/run_lammps_2020.03.03_mpi.sh | 2 -- lammps/bin/run_lammps_2024.02.07.sh | 2 ++ lammps/bin/run_lammps_2024.02.07_mpi.sh | 2 ++ mlip/bin/run_lammpsmlip_2020.12.24.sh | 2 +- mlip/bin/run_lammpsmlip_2020.12.24_mpi.sh | 2 +- mlip/bin/run_mlip_1.0.0_mpi.sh | 2 +- mlip/bin/run_mlipjob_1.0.0_mpi.sh | 2 +- quantumespresso/bin/run_quantumespresso_6.3.sh | 2 +- quantumespresso/bin/run_quantumespresso_6.3_mpi.sh | 2 +- sphinx/bin/{run_sphinx_2.6.1.sh => run_sphinx_3.1.sh} | 0 .../{run_sphinx_2.6.1_mpi.sh => run_sphinx_3.1_mpi.sh} | 6 +++++- templates/DemoScriptJob/input.json | 1 - templates/DemoScriptJob/script.py | 9 --------- vasp/bin/run_vasp_5.4.4_default_mpi.sh | 2 -- vasp/bin/run_vasp_5.4.4_gam_mpi.sh | 2 -- vasp/bin/run_vasp_5.4.4_ncl_mpi.sh | 2 -- vasp/bin/run_vasp_5.4.4_std_mpi.sh | 2 -- ...n_vasp_5.4.4_default.sh => run_vasp_6.4.3_default.sh} | 0 vasp/bin/run_vasp_6.4.3_default_mpi.sh | 2 ++ .../bin/{run_vasp_5.4.4_gam.sh => run_vasp_6.4.3_gam.sh} | 0 vasp/bin/run_vasp_6.4.3_gam_mpi.sh | 2 ++ .../bin/{run_vasp_5.4.4_ncl.sh => run_vasp_6.4.3_ncl.sh} | 0 vasp/bin/run_vasp_6.4.3_ncl_mpi.sh | 2 ++ .../bin/{run_vasp_5.4.4_std.sh => run_vasp_6.4.3_std.sh} | 0 vasp/bin/run_vasp_6.4.3_std_mpi.sh | 2 ++ 28 files changed, 25 insertions(+), 31 deletions(-) delete mode 100755 lammps/bin/run_lammps_2020.03.03.sh delete mode 100755 lammps/bin/run_lammps_2020.03.03_mpi.sh create mode 100755 lammps/bin/run_lammps_2024.02.07.sh create mode 100755 lammps/bin/run_lammps_2024.02.07_mpi.sh rename sphinx/bin/{run_sphinx_2.6.1.sh => run_sphinx_3.1.sh} (100%) rename sphinx/bin/{run_sphinx_2.6.1_mpi.sh => run_sphinx_3.1_mpi.sh} (68%) delete mode 100644 templates/DemoScriptJob/input.json delete mode 100644 templates/DemoScriptJob/script.py delete mode 100644 vasp/bin/run_vasp_5.4.4_default_mpi.sh delete mode 100755 vasp/bin/run_vasp_5.4.4_gam_mpi.sh delete mode 100755 vasp/bin/run_vasp_5.4.4_ncl_mpi.sh delete mode 100755 vasp/bin/run_vasp_5.4.4_std_mpi.sh rename vasp/bin/{run_vasp_5.4.4_default.sh => run_vasp_6.4.3_default.sh} (100%) create mode 100644 vasp/bin/run_vasp_6.4.3_default_mpi.sh rename vasp/bin/{run_vasp_5.4.4_gam.sh => run_vasp_6.4.3_gam.sh} (100%) create mode 100755 vasp/bin/run_vasp_6.4.3_gam_mpi.sh rename vasp/bin/{run_vasp_5.4.4_ncl.sh => run_vasp_6.4.3_ncl.sh} (100%) create mode 100755 vasp/bin/run_vasp_6.4.3_ncl_mpi.sh rename vasp/bin/{run_vasp_5.4.4_std.sh => run_vasp_6.4.3_std.sh} (100%) create mode 100755 vasp/bin/run_vasp_6.4.3_std_mpi.sh diff --git a/damask/bin/run_damask_3.0.0.sh b/damask/bin/run_damask_3.0.0.sh index 0803fed..2f248e5 100755 --- a/damask/bin/run_damask_3.0.0.sh +++ b/damask/bin/run_damask_3.0.0.sh @@ -1,3 +1,3 @@ #!/bin/bash -export OMP_NUM_THREADS=1 +export OMP_NUM_THREADS="${PYIRON_CORES:=1}" DAMASK_grid -m material.yaml -l loading.yaml -g damask.vti diff --git a/damask/bin/run_damask_3.0.0_mpi.sh b/damask/bin/run_damask_3.0.0_mpi.sh index 865c2a8..47ae263 100755 --- a/damask/bin/run_damask_3.0.0_mpi.sh +++ b/damask/bin/run_damask_3.0.0_mpi.sh @@ -1,3 +1,3 @@ #!/bin/bash -export OMP_NUM_THREADS=$1 +export OMP_NUM_THREADS="${PYIRON_CORES:=$1}" DAMASK_grid -m material.yaml -l loading.yaml -g damask.vti diff --git a/lammps/bin/run_lammps_2020.03.03.sh b/lammps/bin/run_lammps_2020.03.03.sh deleted file mode 100755 index 0d75a19..0000000 --- a/lammps/bin/run_lammps_2020.03.03.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -mpiexec -n 1 --oversubscribe lmp_mpi -in control.inp; diff --git a/lammps/bin/run_lammps_2020.03.03_mpi.sh b/lammps/bin/run_lammps_2020.03.03_mpi.sh deleted file mode 100755 index 37f2148..0000000 --- a/lammps/bin/run_lammps_2020.03.03_mpi.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -mpiexec -n $1 --oversubscribe lmp_mpi -in control.inp; diff --git a/lammps/bin/run_lammps_2024.02.07.sh b/lammps/bin/run_lammps_2024.02.07.sh new file mode 100755 index 0000000..fd2661a --- /dev/null +++ b/lammps/bin/run_lammps_2024.02.07.sh @@ -0,0 +1,2 @@ +#!/bin/bash +mpiexec -n ${PYIRON_CORES:=1} --oversubscribe lmp_mpi -in control.inp; diff --git a/lammps/bin/run_lammps_2024.02.07_mpi.sh b/lammps/bin/run_lammps_2024.02.07_mpi.sh new file mode 100755 index 0000000..b6cdf92 --- /dev/null +++ b/lammps/bin/run_lammps_2024.02.07_mpi.sh @@ -0,0 +1,2 @@ +#!/bin/bash +mpiexec -n ${PYIRON_CORES:=$1} --oversubscribe lmp_mpi -in control.inp; diff --git a/mlip/bin/run_lammpsmlip_2020.12.24.sh b/mlip/bin/run_lammpsmlip_2020.12.24.sh index 355d9e8..1cf40d0 100755 --- a/mlip/bin/run_lammpsmlip_2020.12.24.sh +++ b/mlip/bin/run_lammpsmlip_2020.12.24.sh @@ -1,2 +1,2 @@ #!/bin/bash -mpiexec -n 1 lmp_mpi -in control.inp +mpiexec -n ${PYIRON_CORES:=1} lmp_mpi -in control.inp diff --git a/mlip/bin/run_lammpsmlip_2020.12.24_mpi.sh b/mlip/bin/run_lammpsmlip_2020.12.24_mpi.sh index 82056ce..3b86d35 100755 --- a/mlip/bin/run_lammpsmlip_2020.12.24_mpi.sh +++ b/mlip/bin/run_lammpsmlip_2020.12.24_mpi.sh @@ -1,2 +1,2 @@ #!/bin/bash -mpiexec -n $1 lmp_mpi -in control.inp +mpiexec -n ${PYIRON_CORES:=$1} lmp_mpi -in control.inp diff --git a/mlip/bin/run_mlip_1.0.0_mpi.sh b/mlip/bin/run_mlip_1.0.0_mpi.sh index 34da531..4b7158e 100755 --- a/mlip/bin/run_mlip_1.0.0_mpi.sh +++ b/mlip/bin/run_mlip_1.0.0_mpi.sh @@ -1,5 +1,5 @@ #!/bin/bash -export MLP_COMMAND_PARALLEL="mpiexec -n $1 mlp" +export MLP_COMMAND_PARALLEL="mpiexec -n ${PYIRON_CORES:=$1} mlp" export MLP_COMMAND_SERIAL="mlp" chmod +x mlip.sh diff --git a/mlip/bin/run_mlipjob_1.0.0_mpi.sh b/mlip/bin/run_mlipjob_1.0.0_mpi.sh index 75c8574..7ed9795 100755 --- a/mlip/bin/run_mlipjob_1.0.0_mpi.sh +++ b/mlip/bin/run_mlipjob_1.0.0_mpi.sh @@ -1,2 +1,2 @@ #!/bin/bash -mpiexec -n $1 mlp run mlip.ini --filename=structure.cfg +mpiexec -n ${PYIRON_CORES:=$1} mlp run mlip.ini --filename=structure.cfg diff --git a/quantumespresso/bin/run_quantumespresso_6.3.sh b/quantumespresso/bin/run_quantumespresso_6.3.sh index 00668f5..2bde16a 100755 --- a/quantumespresso/bin/run_quantumespresso_6.3.sh +++ b/quantumespresso/bin/run_quantumespresso_6.3.sh @@ -2,4 +2,4 @@ # DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" # export ESPRESSO_PSEUDO=${DIR}/../potentials export ESPRESSO_PSEUDO=${CONDA_PREFIX}/share/pslibrary/pbe/PSEUDOPOTENTIALS/ -mpirun -np 1 pw.x -in pyiron.pwi > pyiron.pwo +mpirun -np ${PYIRON_CORES:=1} pw.x -in pyiron.pwi > pyiron.pwo diff --git a/quantumespresso/bin/run_quantumespresso_6.3_mpi.sh b/quantumespresso/bin/run_quantumespresso_6.3_mpi.sh index dcd7afa..66d1d4e 100755 --- a/quantumespresso/bin/run_quantumespresso_6.3_mpi.sh +++ b/quantumespresso/bin/run_quantumespresso_6.3_mpi.sh @@ -2,4 +2,4 @@ # DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" # export ESPRESSO_PSEUDO=${DIR}/../potentials export ESPRESSO_PSEUDO=${CONDA_PREFIX}/share/pslibrary/pbe/PSEUDOPOTENTIALS/ -mpirun -np ${1} pw.x -in pyiron.pwi > pyiron.pwo +mpirun -np ${PYIRON_CORES:=$1} pw.x -in pyiron.pwi > pyiron.pwo diff --git a/sphinx/bin/run_sphinx_2.6.1.sh b/sphinx/bin/run_sphinx_3.1.sh similarity index 100% rename from sphinx/bin/run_sphinx_2.6.1.sh rename to sphinx/bin/run_sphinx_3.1.sh diff --git a/sphinx/bin/run_sphinx_2.6.1_mpi.sh b/sphinx/bin/run_sphinx_3.1_mpi.sh similarity index 68% rename from sphinx/bin/run_sphinx_2.6.1_mpi.sh rename to sphinx/bin/run_sphinx_3.1_mpi.sh index 3489bff..196b8ed 100755 --- a/sphinx/bin/run_sphinx_2.6.1_mpi.sh +++ b/sphinx/bin/run_sphinx_3.1_mpi.sh @@ -8,8 +8,12 @@ if [ ! -z $2 ]; then SX_THREADS=$2 NCORES=$(echo "$1/$SX_THREADS" | bc) export SX_THREADS +elif [ ! -z $PYIRON_THREADS ]; then + SX_THREADS=$PYIRON_THREADS + NCORES=$(echo "$PYIRON_CORES/$SX_THREADS" | bc) + export SX_THREADS else - NCORES=$1 + NCORES="${PYIRON_CORES:=$1}" fi mpiexec -n $NCORES sphinx --opts > sphinx.log mpiexec -n $NCORES sphinx >> sphinx.log diff --git a/templates/DemoScriptJob/input.json b/templates/DemoScriptJob/input.json deleted file mode 100644 index 662da50..0000000 --- a/templates/DemoScriptJob/input.json +++ /dev/null @@ -1 +0,0 @@ -{"a": 1, "b": [1, 2, 3]} diff --git a/templates/DemoScriptJob/script.py b/templates/DemoScriptJob/script.py deleted file mode 100644 index 7523daf..0000000 --- a/templates/DemoScriptJob/script.py +++ /dev/null @@ -1,9 +0,0 @@ -from pyiron_base import load, dump - - -input_dict = load() - -# Your code goes here! - -output_dict = input_dict.copy() -dump(output_dict) diff --git a/vasp/bin/run_vasp_5.4.4_default_mpi.sh b/vasp/bin/run_vasp_5.4.4_default_mpi.sh deleted file mode 100644 index a48a615..0000000 --- a/vasp/bin/run_vasp_5.4.4_default_mpi.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -mpiexec -n $1 vasp_std diff --git a/vasp/bin/run_vasp_5.4.4_gam_mpi.sh b/vasp/bin/run_vasp_5.4.4_gam_mpi.sh deleted file mode 100755 index db148f5..0000000 --- a/vasp/bin/run_vasp_5.4.4_gam_mpi.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -mpiexec -n $1 vasp_gam diff --git a/vasp/bin/run_vasp_5.4.4_ncl_mpi.sh b/vasp/bin/run_vasp_5.4.4_ncl_mpi.sh deleted file mode 100755 index 362d716..0000000 --- a/vasp/bin/run_vasp_5.4.4_ncl_mpi.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -mpiexec -n $1 vasp_ncl diff --git a/vasp/bin/run_vasp_5.4.4_std_mpi.sh b/vasp/bin/run_vasp_5.4.4_std_mpi.sh deleted file mode 100755 index a48a615..0000000 --- a/vasp/bin/run_vasp_5.4.4_std_mpi.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -mpiexec -n $1 vasp_std diff --git a/vasp/bin/run_vasp_5.4.4_default.sh b/vasp/bin/run_vasp_6.4.3_default.sh similarity index 100% rename from vasp/bin/run_vasp_5.4.4_default.sh rename to vasp/bin/run_vasp_6.4.3_default.sh diff --git a/vasp/bin/run_vasp_6.4.3_default_mpi.sh b/vasp/bin/run_vasp_6.4.3_default_mpi.sh new file mode 100644 index 0000000..e8bf668 --- /dev/null +++ b/vasp/bin/run_vasp_6.4.3_default_mpi.sh @@ -0,0 +1,2 @@ +#!/bin/bash +mpiexec -n ${PYIRON_CORES:=$1} vasp_std diff --git a/vasp/bin/run_vasp_5.4.4_gam.sh b/vasp/bin/run_vasp_6.4.3_gam.sh similarity index 100% rename from vasp/bin/run_vasp_5.4.4_gam.sh rename to vasp/bin/run_vasp_6.4.3_gam.sh diff --git a/vasp/bin/run_vasp_6.4.3_gam_mpi.sh b/vasp/bin/run_vasp_6.4.3_gam_mpi.sh new file mode 100755 index 0000000..6572796 --- /dev/null +++ b/vasp/bin/run_vasp_6.4.3_gam_mpi.sh @@ -0,0 +1,2 @@ +#!/bin/bash +mpiexec -n ${PYIRON_CORES:=$1} vasp_gam diff --git a/vasp/bin/run_vasp_5.4.4_ncl.sh b/vasp/bin/run_vasp_6.4.3_ncl.sh similarity index 100% rename from vasp/bin/run_vasp_5.4.4_ncl.sh rename to vasp/bin/run_vasp_6.4.3_ncl.sh diff --git a/vasp/bin/run_vasp_6.4.3_ncl_mpi.sh b/vasp/bin/run_vasp_6.4.3_ncl_mpi.sh new file mode 100755 index 0000000..65bc585 --- /dev/null +++ b/vasp/bin/run_vasp_6.4.3_ncl_mpi.sh @@ -0,0 +1,2 @@ +#!/bin/bash +mpiexec -n ${PYIRON_CORES:=$1} vasp_ncl diff --git a/vasp/bin/run_vasp_5.4.4_std.sh b/vasp/bin/run_vasp_6.4.3_std.sh similarity index 100% rename from vasp/bin/run_vasp_5.4.4_std.sh rename to vasp/bin/run_vasp_6.4.3_std.sh diff --git a/vasp/bin/run_vasp_6.4.3_std_mpi.sh b/vasp/bin/run_vasp_6.4.3_std_mpi.sh new file mode 100755 index 0000000..e8bf668 --- /dev/null +++ b/vasp/bin/run_vasp_6.4.3_std_mpi.sh @@ -0,0 +1,2 @@ +#!/bin/bash +mpiexec -n ${PYIRON_CORES:=$1} vasp_std From 8e7a89029fd604a3bda701266c5e672901ee801e Mon Sep 17 00:00:00 2001 From: Jan Janssen Date: Fri, 28 Jun 2024 11:06:55 +0200 Subject: [PATCH 2/3] Update test.yml --- .github/workflows/test.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 7ed646f..8f5871d 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -43,7 +43,6 @@ jobs: mv ../thermodynamics resources mv ../LICENSE resources mv ../damask resources - mv ../templates resources mkdir resources/lammps/potentials mv iprpy-data/share/iprpy/potentials_lammps.csv resources/lammps/potentials/potentials_lammps.csv mv iprpy-data/share/iprpy/potential_LAMMPS resources/lammps/potentials/potential_LAMMPS From bacc2659b392aad11b11377423a80b6ff2afbb13 Mon Sep 17 00:00:00 2001 From: Jan Janssen Date: Fri, 28 Jun 2024 11:07:09 +0200 Subject: [PATCH 3/3] Update deploy.yml --- .github/workflows/deploy.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 69bea2f..e6c8ce7 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -44,7 +44,6 @@ jobs: mv ../thermodynamics resources mv ../LICENSE resources mv ../damask resources - mv ../templates resources mkdir resources/lammps/potentials mv iprpy-data/share/iprpy/potentials_lammps.csv resources/lammps/potentials/potentials_lammps.csv mv iprpy-data/share/iprpy/potential_LAMMPS resources/lammps/potentials/potential_LAMMPS