-
Notifications
You must be signed in to change notification settings - Fork 0
/
create_htar_6hgfs.sh
executable file
·47 lines (32 loc) · 1.14 KB
/
create_htar_6hgfs.sh
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
45
46
#!/bin/bash
# Author: Alicia Bentley
#####################################
# Script for submitting jobs on Hera
# that download data from HPSS
#####################################
echo ${DATA_PATH}/${CASE}/${CYCLE}
echo ${FHR_INC}
echo ${FHR_START}
echo ${FHR_END}
mkdir -p ${DATA_PATH}/${CASE}/${CYCLE}
'cp' ${SCRIPTS_PATH}/htar_gfs.ncl ${DATA_PATH}/${CASE}/${CYCLE}/.
cd ${DATA_PATH}/${CASE}/
cat > ${DATA_PATH}/${CASE}/${CYCLE}/htar_gfs.csh <<EOF
#!/bin/csh
#SBATCH --account=ovp
#SBATCH --job-name=gfs_htar
#SBATCH --output=gfs_htar.%j.out
#SBATCH --ntasks=1
#SBATCH --partition=service
#SBATCH --time=4:00:00
cd ${DATA_PATH}/${CASE}/${CYCLE}/
/bin/rm -rf ../htar_gfs_${CYCLE}_done
echo ncl 'scriptyyyymmddhh="${CYCLE}"' 'eventname="${CASE}"' 'fhr_inc="${FHR_INC}"' 'fhr_start="${FHR_START}"' 'fhr_end="${FHR_END}"' ${DATA_PATH}/${CASE}/${CYCLE}/htar_gfs.ncl
ncl 'scriptyyyymmddhh="${CYCLE}"' 'eventname="${CASE}"' 'fhr_inc="${FHR_INC}"' 'fhr_start="${FHR_START}"' 'fhr_end="${FHR_END}"' ${DATA_PATH}/${CASE}/${CYCLE}/htar_gfs.ncl
#sleep 5
touch ../htar_gfs_${CYCLE}_done
exit
EOF
sbatch ${DATA_PATH}/${CASE}/${CYCLE}/htar_gfs.csh
sleep 5
exit