-
Notifications
You must be signed in to change notification settings - Fork 98
/
Copy pathbindcraft.slurm
44 lines (38 loc) · 1.31 KB
/
bindcraft.slurm
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
37
38
39
40
41
42
43
44
#!/bin/bash
#SBATCH --nodes 1
#SBATCH --ntasks 1
#SBATCH --cpus-per-task 1
#SBATCH --partition=gpu
#SBATCH --qos=gpu
#SBATCH --gres=gpu:1
#SBATCH --mem 42gb
#SBATCH --time 72:00:00
#SBATCH --output=bindcraft_%A.log
# Initialise environment and modules
CONDA_BASE=$(conda info --base)
source ${CONDA_BASE}/bin/activate ${CONDA_BASE}/envs/BindCraft
export LD_LIBRARY_PATH=${CONDA_BASE}/lib
# alternatively you can source the environment directly
#source /path/to/mambaforge/bin/activate /path/to/mambaforge/envs/BindCraft
# Get the directory where the bindcraft script is located
SCRIPT_DIR=$(dirname "$0")
# Parsing command line options
SETTINGS=""
FILTERS=""
ADVANCED=""
TEMP=$(getopt -o s:f:a: --long settings:,filters:,advanced: -n 'bindcraft.slurm' -- "$@")
eval set -- "$TEMP"
while true ; do
case "$1" in
-s|--settings) SETTINGS="$2" ; shift 2 ;;
-f|--filters) FILTERS="$2" ; shift 2 ;;
-a|--advanced) ADVANCED="$2" ; shift 2 ;;
--) shift ; break ;;
*) echo "Invalid Option" ; exit 1 ;;
esac
done
echo "Running the BindCraft pipeline"
echo "Running binder design for target ${SETTINGS}"
echo "Design settings used: ${ADVANCED}"
echo "Filtering designs based on ${FILTERS}"
python -u "${SCRIPT_DIR}/bindcraft.py" --settings "${SETTINGS}" --filters "${FILTERS}" --advanced "${ADVANCED}"