Skip to content

Commit

Permalink
Adding sbatch params for jobs supporting OpenMPI
Browse files Browse the repository at this point in the history
  • Loading branch information
skchronicles committed Nov 14, 2023
1 parent 6f9bf2d commit ec69f8b
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
13 changes: 12 additions & 1 deletion config/cluster.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@
"mem": "48g",
"partition": "norm",
"threads": "4",
"time": "1-18:00:00"
"time": "1-18:00:00",
"ntasks": "",
"ntasks_per_core": "",
"exclusive": ""
},
"trim": {
"mem": "64g",
Expand Down Expand Up @@ -89,5 +92,13 @@
"MACS2_narrow": {
"threads": "4",
"mem": "50g"
},
"MEME": {
"threads": "56",
"mem": "32g",
"time": "1-00:00:00",
"ntasks": "--ntasks=28",
"ntasks_per_core": "--ntasks-per-core=1",
"exclusive": "--exclusive"
}
}
4 changes: 2 additions & 2 deletions src/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ function submit(){
# --keep-remote --restart-times 3 -j 500 --use-singularity
# --singularity-args -B {}.format({bindpaths}) --local-cores 24
SLURM_DIR="$3/logfiles/slurmfiles"
CLUSTER_OPTS="sbatch --gres {cluster.gres} --cpus-per-task {cluster.threads} -p {cluster.partition} -t {cluster.time} --mem {cluster.mem} --job-name={params.rname} -e $SLURM_DIR/slurm-%j_{params.rname}.out -o $SLURM_DIR/slurm-%j_{params.rname}.out"
CLUSTER_OPTS="sbatch --gres {cluster.gres} --cpus-per-task {cluster.threads} -p {cluster.partition} -t {cluster.time} --mem {cluster.mem} --job-name={params.rname} -e $SLURM_DIR/slurm-%j_{params.rname}.out -o $SLURM_DIR/slurm-%j_{params.rname}.out {cluster.ntasks} {cluster.ntasks_per_core} {cluster.exclusive}"
# Check if NOT running on Biowulf
# Assumes other clusters do NOT
# have GRES for local node disk,
Expand All @@ -207,7 +207,7 @@ function submit(){
# SLURM is not configured to use
# GRES, remove prefix single quote
if [[ ${6#\'} != /lscratch* ]]; then
CLUSTER_OPTS="sbatch --cpus-per-task {cluster.threads} -p {cluster.partition} -t {cluster.time} --mem {cluster.mem} --job-name={params.rname} -e $SLURM_DIR/slurm-%j_{params.rname}.out -o $SLURM_DIR/slurm-%j_{params.rname}.out"
CLUSTER_OPTS="sbatch --cpus-per-task {cluster.threads} -p {cluster.partition} -t {cluster.time} --mem {cluster.mem} --job-name={params.rname} -e $SLURM_DIR/slurm-%j_{params.rname}.out -o $SLURM_DIR/slurm-%j_{params.rname}.out {cluster.ntasks} {cluster.ntasks_per_core} {cluster.exclusive}"
fi
# Create sbacth script to build index
cat << EOF > kickoff.sh
Expand Down

0 comments on commit ec69f8b

Please sign in to comment.