-
Notifications
You must be signed in to change notification settings - Fork 1
/
grs_mpi_launcher.pbs
executable file
·52 lines (40 loc) · 2.1 KB
/
grs_mpi_launcher.pbs
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
47
48
49
50
51
52
# launch with qsub (PBS job)
#!/bin/bash
#PBS -N grs2_obs2
#PBS -l select=1:ncpus=40:mpiprocs=8:mem=180gb:generation=g2019
#PBS -l walltime=48:00:00
#mpiprocs=4:
# echo /home/eh/harmelt/proxyfile.txt | source /home/eh/harmelt/set_proxy.sh
#
# set file path with list of images to process
# format/header of the file in csv:
# process (yes if 1),Site Name,start_date,end_date,satellite,tile,resolution (m), flag
list_file=list_grs_cnes_obs2mod.csv
#list_file=list_grs_ukraine.csv
#list_file=list_grs_cordoba.csv
#list_file=list_landsat_jegou.csv
GRSHOME=/work/scratch/harmelt/dev/grs2
list_filepath=$GRSHOME/exe/list/$list_file
module load conda
# ------------------------
# first section: load L1C and L2A images with Amalthee
# ------------------------
path_of_env=/softs/rh7/conda-envs/amalthee_prod_client
conda activate $path_of_env
$path_of_env/bin/python $GRSHOME/exe/call_amalthee.py $list_filepath
# ------------------------
# second section: process available couples of L1C/L2A images with GRS
# ------------------------
##activate conda environement
path_of_env=grs_v2
conda activate $path_of_env
export OMP_NUM_THREADS=6
#open monitoring tool
module load monitoring/1.0
start_monitoring.sh --name GRS_$PBS_JOBID
python $GRSHOME/exe/grs_tiles_cnes_v2.py $list_filepath $OMP_NUM_THREADS
stop_monitoring.sh --name GRS_$PBS_JOBID
# test example:
# grs /datalake/S2-L1C/33PVR/2020/12/19/S2A_MSIL1C_20201219T092411_N0209_R093_T33PVR_20201219T103844.SAFE -o /datalake/watcal/S2-L2GRS/33PVR/2020/12/19/33PVR/S2A_MSIl2grs_20201219T092411_N0209_R093_T33PVR_20201219T103844 --aerosol cams_forecast --maja /datalake/S2-L2A-THEIA/33PVR/2020/12/19/SENTINEL2A_20201219-093647-800_L2A_T33PVR_C_V2-2/SENTINEL2A_20201219-093647-800_L2A_T33PVR_C_V2-2_MTD_ALL.xml --dem
# grs test/data/S2B_MSIL1C_20180927T103019_N0206_R108_T31TGK_20180927T143835.SAFE --shape test/data/shape/SPO04.shp --odir test/results/ --aerosol cams_forecast --dem --resolution 20
# grs /datalake/watcal/L8_L1_C2/008231/2022/05/31/LC08_L1TP_008231_20220531_20220609_02_T1.tar --odir /datalake/watcal/L8_L2GRS_C2/008231/2022/05/31/ --aerosol cams_forecast --dem --resolution 20