123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990 |
- #!/bin/bash
- # Submission script for Zenobe
- #PBS -N ECEC_post
- #PBS -r y
- #PBS -W group_list=ecearth
- #
- #PBS -l walltime=23:59:00
- #PBS -l select=1:ncpus=5:ompthreads=5:vmem=20480mb
- #PBS -l pvmem=4096mb
- #
- #PBS -M francois.klein@uclouvain.be
- #PBS -m abe
- exec > ${PBS_O_WORKDIR}/${PBS_JOBNAME}.${PBS_JOBID}.log
- echo "------------------ Work dir --------------------"
- cd ${PBS_O_WORKDIR} && echo ${PBS_O_WORKDIR}
- echo "------------------ Job Info --------------------"
- echo "jobid : $PBS_JOBID"
- echo "jobname : $PBS_JOBNAME"
- echo "job type : $PBS_ENVIRONMENT"
- echo "submit dir : $PBS_O_WORKDIR"
- echo "queue : $PBS_O_QUEUE"
- echo "user : $PBS_O_LOGNAME"
- echo "threads : $OMP_NUM_THREADS"
- set -ue
- set +x
- # =============================================================================
- # *** BEGIN User configuration
- # =============================================================================
- # -----------------------------------------------------------------------------
- # *** General configuration
- # -----------------------------------------------------------------------------
- # Experiment name (exactly 4 letters!)
- exp_name=ECEC
- # Directories
- start_dir=${PBS_O_WORKDIR}
- #start_dir=${PWD}
- # Architecture
- build_arch=ecconf
- nem_numproc=96
- # -----------------------------------------------------------------------------
- # *** Read platform dependent configuration
- # -----------------------------------------------------------------------------
- . ${PBS_O_WORKDIR}/ecconf.cfg
- configure
- # -----------------------------------------------------------------------------
- # *** Post NEMO
- # -----------------------------------------------------------------------------
- rebuild_nemo=${ecearth_src_dir}/util/rebuild_nemo/rebuild_nemo
- path=${run_dir}/output/nemo
- for dir in ${path}/*
- do
- cd ${dir}
- count=0
- for i in $(echo `ls | head -n 1` | tr "_" "\n")
- do
- count=$(( $count + 1 ))
- [[ $count -eq 3 ]] && expdate=${i}
- [[ $count -eq 4 ]] && expdate=${expdate}_${i}
- done
- basename="${exp_name}_1m_${expdate}_"
- $rebuild_nemo -t 5 ${basename}grid_T ${nem_numproc}
- $rebuild_nemo -t 5 ${basename}grid_U ${nem_numproc}
- $rebuild_nemo -t 5 ${basename}grid_V ${nem_numproc}
- $rebuild_nemo -t 5 ${basename}grid_W ${nem_numproc}
- #$rebuild_nemo -t 5 ${basename}icemoa ${nem_numproc}
- #$rebuild_nemo -t 5 ${basename}icemod ${nem_numproc}
- mv ${basename}??????.nc ..
- cd ..
- done
- if [ ! -d ${stdout_dir}/nemo ]
- then
- mkdir -p ${stdout_dir}/nemo
- fi
- cd ${path}
- mv -f *.nc ${stdout_dir}/nemo
- # -----------------------------------------------------------------------------
|