Skip to content

Commit

Permalink
slurm scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
djpasseyjr committed Feb 19, 2024
1 parent 1a3cbc6 commit fbf74fb
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 1 deletion.
2 changes: 1 addition & 1 deletion experiments/exp1/generate_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
"""

SAVE_FILE = f"{DIR_PATH}/{FILE_PREFIX}_output{PARAM_IDX}.pkl"
SAVE_FILE = f"{FILE_PREFIX}_output{PARAM_IDX}.pkl"

# Read the dynamic models param array and access at the command line arg index
with open(f"{DIR_PATH}/dynamic_models_small.pkl", "rb") as f:
Expand Down
Empty file.
16 changes: 16 additions & 0 deletions experiments/exp1/slurm_submit.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/bin/sh

# Expected number of hours to run one simulation (always overestimate so that slurm doesnt kill the sim)
HOURS_PER_SIM=24
# Directory to store the output data
DATADIR="/work/users/d/j/djpassey/interfere_exp1"

# Arguments for sbatch. Sets the appropriate time limit and directory
FLAGS="--ntasks=1 --cpus-per-task=1 --time=$HOURS_PER_SIM:00:00 --chdir=$DATADIR"

# Total number of jobs
NJOBS=300
for((n=0; n<$NJOBS; n+=1)); do
# Submit the multiple parameter job script to the clusters
sbatch $FLAGS /nas/longleaf/home/djpassey/interfere/experiments/exp1/single_slurm_job.sh $n
done

0 comments on commit fbf74fb

Please sign in to comment.