-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathrun_one.srun
24 lines (19 loc) · 1.13 KB
/
run_one.srun
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/bash
#SBATCH --partition=kern,long,longfat
#SBATCH --job-name=onesim
#SBATCH --time=10-00:00:00
#SBATCH --mem 32G
#SBATCH --output=one.out ### File in which to store job output
#SBATCH --error=one.err ### File in which to store job error messages
module load cuda/9.0
module use /projects/apps/shared/modulefiles/
module load python3 tskit SLiM
ran=$(od -N 4 -t uL -An /dev/urandom | tr -d " ")
slim -m -t -d "SIM=${1}" -d N=${2} -d mu=${3} -d r=${4} -d L=${5} -d L0=${6} -d L1=${7} -d RAND=$ran -d m=${8} -d deff=${9} /home/murillor/projects/mimulus_sims/${10}
if [ -d /home/murillor/projects/mimulus_sims/N_${2}_mu_${3}_r_${4}_L_${5}_L0_${6}_L1_${7}_m_${8}_deff_${9} ] # for file "if [-f /home/rama/file]"
then
mv /tmp/*N_sim_"${1}"_RAND_"${ran}".trees /home/murillor/projects/mimulus_sims/N_${2}_mu_${3}_r_${4}_L_${5}_L0_${6}_L1_${7}_m_${8}_deff_${9}/
else
mkdir /home/murillor/projects/mimulus_sims/N_${2}_mu_${3}_r_${4}_L_${5}_L0_${6}_L1_${7}_m_${8}_deff_${9}
mv /tmp/*N_sim_"${1}"_RAND_"${ran}".trees /home/murillor/projects/mimulus_sims/N_${2}_mu_${3}_r_${4}_L_${5}_L0_${6}_L1_${7}_m_${8}_deff_${9}/
fi