runBase.sh 909 Bytes
Newer Older
iker_martin's avatar
iker_martin committed
1
2
#!/bin/bash

3
#SBATCH -p P1
4
#SBATCH -N 1
5
#SBATCH --exclude=c01,c00,c02
iker_martin's avatar
iker_martin committed
6

7
dir="/home/martini/malleability_benchmark"
8
9
partition='P1'

10
codeDir="/Codes"
11
12
execDir="/Exec"
cores=$(bash $dir$execDir/BashScripts/getCores.sh $partition)
13

14
15
nodelist=$SLURM_JOB_NODELIST
nodes=$SLURM_JOB_NUM_NODES
16
configFile=$1
iker_martin's avatar
iker_martin committed
17
18
19
20
21
22

outIndex=0
if [ $# -ge 2 ]
then
  outIndex=$2
fi
23

iker_martin's avatar
iker_martin committed
24
25
26
echo "MPICH"
#export HYDRA_DEBUG=1

27
28
29
30
31
numP=$(bash $dir$execDir/BashScripts/getNumPNeeded.sh $configFile 0)
initial_nodelist=$(bash $dir$execDir/BashScripts/createInitialNodelist.sh $numP $cores $nodelist)
echo $initial_nodelist
echo "Test PreRUN $numP $nodelist"
mpirun -hosts $initial_nodelist -np $numP $dir$codeDir/build/a.out $configFile $outIndex $nodelist $nodes
32

33
echo "END RUN"
34
sed -i 's/application called MPI_Abort(MPI_COMM_WORLD, -100) - process/shrink cleaning/g' slurm-$SLURM_JOB_ID.out
35
sed -i 's/Abort(-100)/shrink cleaning/g' slurm-$SLURM_JOB_ID.out