Commit 186d4043 authored by Doak, Peter W's avatar Doak, Peter W
Browse files

showing example for existing VASP input dirs

parent a3a3a5c2
......@@ -25,33 +25,33 @@ declare -a vrundirs
#here we duplicate the example num runs amount
#you could also use a construct like
#########################################################################################################
# for vrun in $(seq 1 $NUM_RUNS) #
# do #
# rundir=(`printf "Fe-bcc-%0.2d" $vrun`) #
# cp -r Fe-bcc $rundir #
# vrundirs[$vrun]=$rundir #
# start=$(expr 1 + $(expr $(($vrun-1)) \* $CORES_PER_RUN )) #
# end=$(expr $vrun \* $CORES_PER_RUN) #
# echo "$start $end" #
# awk -v start=$start -v end=$end 'NR >= start && NR <= end' pbs_nodefile > ${rundir}/pbs_nodefile #
# done #
#########################################################################################################
# you could also use a construct like below if you had vaspdir1 etc. inside the PBS_O_WORKDIR you submitted from
# for vrun in $(seq 1 $NUM_RUNS)
# do
# rundir=(`printf "Fe-bcc-%0.2d" $vrun`)
# cp -r Fe-bcc $rundir
# vrundirs[$vrun]=$rundir
# start=$(expr 1 + $(expr $(($vrun-1)) \* $CORES_PER_RUN ))
# end=$(expr $vrun \* $CORES_PER_RUN)
# echo "$start $end"
# awk -v start=$start -v end=$end 'NR >= start && NR <= end' pbs_nodefile > ${rundir}/pbs_nodefile
# done
# you could also use a construct like below if you had vaspdir1 etc. inside the PBS_O_WORKDIR you submitted from
vrundirs=(vaspdir1 vaspdir2 vaspdir3 vaspdir4 vaspdir5 vaspdir6 vaspdir7 vaspdir8)
#in this case we'll make them
#for this test we'll make them
for rundir in ${vrundirs[@]}
do
cp -r Fe-bcc $rundir
done
vrdlent=${#vrundirs[@]}
#here we split up the nodefile amongst the jobs
vrdlen=${#vrundirs[@]}
for vrun in $(seq 1 $vrdlen)
do
rundir=$vrundirs[$vrun]
rundir=${vrundirs[$vrun]}
start=$(expr 1 + $(expr $(($vrun-1)) \* $CORES_PER_RUN ))
end=$(expr $vrun \* $CORES_PER_RUN)
echo "$start $end"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment