-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrun.slurm.annual.large
38 lines (33 loc) · 1.07 KB
/
run.slurm.annual.large
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
#!/bin/bash
#SBATCH --job-name="python-xarray"
#SBATCH --output="python.%j.%N.out"
###SBATCH --partition=compute
#SBATCH --partition=large-shared
#SBATCH --nodes=1
#SBATCH --ntasks-per-node=24
#SBATCH --export=ALL
#SBATCH --time=48:00:00
#SBATCH --mem=800G
# Activate user installed python
### conda info
### conda config --show-sources
### conda info --envs
### source activate base [only works from terminal]
source ~/anaconda3/etc/profile.d/conda.sh
conda activate base
# Define variables
export input_dir='./input'
export output_dir='./output'
export data_dir='/oasis/scratch/comet/igarousi/temp_project'
export dataset='LDASOUT'
export nrcs_file='NRCS_SNOTEL_no_Alaska_Joint_w_CEC.csv'
export year=2007
export output_name_1='SNOTEL_indices_at_NWM.csv'
export output_name_2='NWM'
export file='./input/variables.txt'
# Run
for month in {01..12}
do for variable in `cat ./$file`
do python ./code/NWM_RRv2_Retrieve.py $input_dir $output_dir $data_dir $dataset $nrcs_file $year $month $variable $output_name_1 ${output_name_2}_${year}_${month}_${variable}
done
done