Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use PYIRON_CORES and PYIRON_THREADS #73

Merged
merged 3 commits into from
Jun 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
2 changes: 1 addition & 1 deletion damask/bin/run_damask_3.0.0.sh
Original file line number Diff line number Diff line change
@@ -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
2 changes: 1 addition & 1 deletion damask/bin/run_damask_3.0.0_mpi.sh
Original file line number Diff line number Diff line change
@@ -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
2 changes: 0 additions & 2 deletions lammps/bin/run_lammps_2020.03.03.sh

This file was deleted.

2 changes: 0 additions & 2 deletions lammps/bin/run_lammps_2020.03.03_mpi.sh

This file was deleted.

2 changes: 2 additions & 0 deletions lammps/bin/run_lammps_2024.02.07.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/bash
mpiexec -n ${PYIRON_CORES:=1} --oversubscribe lmp_mpi -in control.inp;
2 changes: 2 additions & 0 deletions lammps/bin/run_lammps_2024.02.07_mpi.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/bash
mpiexec -n ${PYIRON_CORES:=$1} --oversubscribe lmp_mpi -in control.inp;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this intending to get the conda version of lammps from the pyiron/... module? Then I would like to make that more explicity by

Suggested change
mpiexec -n ${PYIRON_CORES:=$1} --oversubscribe lmp_mpi -in control.inp;
module purge
module pyiron
mpiexec -n ${PYIRON_CORES:=$1} --oversubscribe lmp_mpi -in control.inp;

and renaming the script to include conda or so "conda", since in the current way it's not actually guaranteed that we end up with lammps 2024 Feb07.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess we have some confusion here - these are the general pyiron resources people download when they install pyiron from conda, so yes it is using LAMMPS from conda and by default there is no module system available.

2 changes: 1 addition & 1 deletion mlip/bin/run_lammpsmlip_2020.12.24.sh
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#!/bin/bash
mpiexec -n 1 lmp_mpi -in control.inp
mpiexec -n ${PYIRON_CORES:=1} lmp_mpi -in control.inp
2 changes: 1 addition & 1 deletion mlip/bin/run_lammpsmlip_2020.12.24_mpi.sh
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#!/bin/bash
mpiexec -n $1 lmp_mpi -in control.inp
mpiexec -n ${PYIRON_CORES:=$1} lmp_mpi -in control.inp
2 changes: 1 addition & 1 deletion mlip/bin/run_mlip_1.0.0_mpi.sh
Original file line number Diff line number Diff line change
@@ -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
Expand Down
2 changes: 1 addition & 1 deletion mlip/bin/run_mlipjob_1.0.0_mpi.sh
Original file line number Diff line number Diff line change
@@ -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
2 changes: 1 addition & 1 deletion quantumespresso/bin/run_quantumespresso_6.3.sh
Original file line number Diff line number Diff line change
Expand Up @@ -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
2 changes: 1 addition & 1 deletion quantumespresso/bin/run_quantumespresso_6.3_mpi.sh
Original file line number Diff line number Diff line change
Expand Up @@ -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
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
1 change: 0 additions & 1 deletion templates/DemoScriptJob/input.json

This file was deleted.

9 changes: 0 additions & 9 deletions templates/DemoScriptJob/script.py

This file was deleted.

2 changes: 0 additions & 2 deletions vasp/bin/run_vasp_5.4.4_default_mpi.sh
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I still use this. Making 6 the default makes sense, but it's ok to keep the old version for a while.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is primarily a template as inspiration for users - these are not the resources we use one the cluster.

This file was deleted.

2 changes: 0 additions & 2 deletions vasp/bin/run_vasp_5.4.4_gam_mpi.sh

This file was deleted.

2 changes: 0 additions & 2 deletions vasp/bin/run_vasp_5.4.4_ncl_mpi.sh

This file was deleted.

2 changes: 0 additions & 2 deletions vasp/bin/run_vasp_5.4.4_std_mpi.sh

This file was deleted.

File renamed without changes.
2 changes: 2 additions & 0 deletions vasp/bin/run_vasp_6.4.3_default_mpi.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/bash
mpiexec -n ${PYIRON_CORES:=$1} vasp_std
File renamed without changes.
2 changes: 2 additions & 0 deletions vasp/bin/run_vasp_6.4.3_gam_mpi.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/bash
mpiexec -n ${PYIRON_CORES:=$1} vasp_gam
File renamed without changes.
2 changes: 2 additions & 0 deletions vasp/bin/run_vasp_6.4.3_ncl_mpi.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/bash
mpiexec -n ${PYIRON_CORES:=$1} vasp_ncl
File renamed without changes.
2 changes: 2 additions & 0 deletions vasp/bin/run_vasp_6.4.3_std_mpi.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/bash
mpiexec -n ${PYIRON_CORES:=$1} vasp_std
Loading