File indexing completed on 2026-10-15 08:17:26
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014 PROJDIR=${CORRAL_DIR:-$(cd "$(dirname "$(readlink -f "$0")")" && pwd)}
0015 export CORRAL_DIR=$PROJDIR
0016 SET=$1
0017 if [ -z "$SET" ] || [ ! -f $PROJDIR/lists/$SET/manifest.txt ]; then
0018 echo "usage: $0 <set> [array-range] (no lists/$SET/manifest.txt -- run lists/make_lists.bash first)"; exit 1
0019 fi
0020 NL=$(awk '$1=="nlists"{print $2}' $PROJDIR/lists/$SET/manifest.txt)
0021 RANGE=${2:-0-$((NL-1))}
0022 OUT=$SET
0023 VAR=$CORRAL_VARIANT
0024 CRS=$CORRAL_RS
0025 if [ -n "$CRS" ] && [ -z "$VAR" ]; then echo "CORRAL_RS='$CRS' needs a CORRAL_VARIANT=<name> (outputs go to <set>_<name>/)"; exit 1; fi
0026 if [ -n "$VAR" ]; then
0027 [ -z "$CRS" ] && echo "variant $VAR: the code defaults (no run string), e.g. a new code version next to the old outputs"
0028 OUT=${SET}_$VAR
0029 [ -e $PROJDIR/lists/$OUT ] || ln -s $SET $PROJDIR/lists/$OUT
0030 fi
0031 mkdir -p $PROJDIR/root/$OUT/chunks $PROJDIR/pdf/$OUT/chunks $PROJDIR/log/$OUT/chunks
0032 cp -v $PROJDIR/corral $PROJDIR/log/$OUT/chunks/corral.snapshot
0033 echo "set $SET -> $OUT: $NL lists, run string '${CRS}', submitting array $RANGE"
0034
0035
0036 EXCLUDE=${EXCLUDE-hax[1-18],rpr[1-24]}
0037 sbatch --partition=prip --time=2-23:59:59 ${EXCLUDE:+--exclude=$EXCLUDE} \
0038 --array=$RANGE \
0039 --job-name=crm_$OUT \
0040 --output=$PROJDIR/log/$OUT/chunks/corral_%2a.log \
0041 --error=$PROJDIR/log/$OUT/chunks/corral_%2a.log \
0042 --mem=8G \
0043 --export=ALL \
0044 $PROJDIR/run_m_array.slurm $SET $OUT $CRS