-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathslurm_all.sh
executable file
·33 lines (24 loc) · 1.37 KB
/
slurm_all.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
#!/bin/bash
###TODO IN SETUP.PY:
# setup $MEZEHOME
###
###TODO How to activate correct environment?
N_LIGANDS=NUMBER_OF_LIGANDS
ENGINE=ENGINE
AFE_INPUT_DIR=AFE_PATH
export ligands_dat_file=LIGANDS_DATA_FILE
export transformations_file=TRANSFORMATIONS_DATA_FILE
source $MEZEHOME/parse.sh
solvation_job_id=$(sbatch --parsable --array=0-$((${N_LIGANDS}-1)) $AFE_INPUT_DIR/02_add_water.sh)
echo "Adding water with slurm job $solvation_job_id"
heating_job_id=$(sbatch --dependency=afterok:${solvation_job_id} --parsable --array=0-$((${N_LIGANDS}-1)) $AFE_INPUT_DIR/03_heat_meze.sh)
echo "Heating meze with slurm job $heating_job_id"
meze_job_id=$(sbatch --dependency=afterok:${heating_job_id} --parsable --array=0-$((${#transformations_array[@]}-1)) $AFE_INPUT_DIR/04_meze.sh)
echo "Preparing AFE with slurm job $meze_job_id"
for i in "${!transformations_array[@]}"
do
afe_job_id=$(sbatch --dependency=afterok:${meze_job_id} --parsable --job-name=${transformations_array[i]} --array=0-$((${n_windows_array[i]}-1)) $AFE_INPUT_DIR/05_run_$ENGINE.sh ${transformations_array[i]} "${lambdas_array[i]}")
echo "Submitted AFE slurm job $afe_job_id"
done
analysis_job_id=$(sbatch --dependency=afterok:${afe_job_id} --parsable --job-name=${transformations_array[i]} --array=0-$((${#transformations_array[@]}-1)) $AFE_INPUT_DIR/06_analyse.sh)
echo "Submitted analysis slurm job $analysis_job_id"