forked from paracrawl/cirrus-scripts
-
Notifications
You must be signed in to change notification settings - Fork 0
/
08.score.sh
executable file
·36 lines (31 loc) · 947 Bytes
/
08.score.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#!/bin/bash
## create and submit the batches on csd3 for alignment
set -euo pipefail
. ./env/init.sh
. ./config.sh
. ./functions.sh
collection=$1
shift
export SBATCH_ACCOUNT=t2-cs119-gpu
export SBATCH_PARTITION=pascal
export SLURM_TASKS_PER_NODE=1 # No parallelism in generic.slurm plz, they'll have to share the gpu otherwise.
export SBATCH_GRES=gpu:1
for lang in $*; do
bicleaner_ai_model $lang
batch_list=`make_batch_list 08 $collection $lang scored.gz fixed.gz hardruled.gz`
job_list=`make_job_list $batch_list`
if [ ! -z $job_list ]; then
prompt "Scheduling $job_list\n"
if confirm; then
schedule \
-J score-${lang%~*}-${collection} \
-a $job_list \
--time 24:00:00 \
-e ${SLURM_LOGS}/08.score-%A_%a.err \
-o ${SLURM_LOGS}/08.score-%A_%a.out \
${SCRIPTS}/generic.slurm $batch_list \
${SCRIPTS}/08.score ${collection} ${lang%~*} \
${COLLECTIONS[$collection]}-shards/${TARGET_LANG}
fi
fi
done