diff --git a/inst/doc/practical_guide.md b/inst/doc/practical_guide.md index b22c6292c2923f54f2119fdbb5af3898a6c9af5d..91c11ee627b0a679325dda8ea6e2c1ced06e2baa 100644 --- a/inst/doc/practical_guide.md +++ b/inst/doc/practical_guide.md @@ -746,6 +746,7 @@ To have the good practice, note down the expid if it is automatically created by - `hpc_user`: Your user ID on the HPC (i.e., "bsc32xxx"). It is required if "queue_host" is not 'local'. - `data_dir`: The path to the data repository if the data is not shared. - `lib_dir`: directory on the HPC where the startR R package and other required R packages are installed, accessible from all HPC nodes. These installed packages must be compatible with the R module specified in `r_module`. This parameter is optional; only required when the libraries are not installed in the R module. +- `run_dir`: The directory to run the startR jobs. It is useful when the self-defined function has relative path. - `init_commands`: The initial commands in bash script before R script runs. For example, the modules required by computation can be loaded here. - `r_module`: Name of the UNIX environment module to be used for R. If not specified, `module load R` will be used. - `CDO_module`: Name of the UNIX environment module to be used for CDO. If not specified, it is NULL and no CDO module will be loaded. Make sure to assign it if `tranform` is required in Start(). diff --git a/inst/doc/usecase/ex2_1_timedim.R b/inst/doc/usecase/ex2_1_timedim.R index 15ef37da6dd8c955dcd433a73c5aa470e3b799d4..0c0f36c0a981e0abfd45e23fcd86d8f22406919f 100644 --- a/inst/doc/usecase/ex2_1_timedim.R +++ b/inst/doc/usecase/ex2_1_timedim.R @@ -45,9 +45,9 @@ library(startR) ## on Power9 #-----------modify according to your personal info--------- - queue_host = 'cte-power' #your own host name for power9 - temp_dir = '/gpfs/scratch/bsc32/bsc32339/startR_hpc/' - ecflow_suite_dir = '/home/Earth/nperez/startR_local/' #your own local directory + queue_host <- 'cte-power' #your own host name for power9 + temp_dir <- '/gpfs/scratch/bsc32/bsc32339/startR_hpc/' + ecflow_suite_dir <- '/home/Earth/nperez/startR_local/' #your own local directory #------------------------------------------------------------ res <- Compute(wf1, chunks = list(ensemble = 20, @@ -66,11 +66,12 @@ library(startR) ecflow_suite_dir = ecflow_suite_dir, wait = TRUE) -## on Nord3 + +## on Nord3 with ecFlow #-----------modify according to your personal info--------- - queue_host = 'nord4' - temp_dir = '/gpfs/scratch/bsc32/bsc32339/startR_hpc/' - ecflow_suite_dir = '/home/Earth/nperez/startR_local/' #your own local directory + queue_host <- 'nord4' + temp_dir <- '/gpfs/scratch/bsc32/bsc32339/startR_hpc/' + ecflow_suite_dir <- '/home/Earth/nperez/startR_local/' #your own local directory #------------------------------------------------------------ res <- Compute(wf1, chunks = list(ensemble = 20, @@ -88,3 +89,32 @@ library(startR) ecflow_suite_dir = ecflow_suite_dir, wait = TRUE) + + +## on Nord3 with Autosubmit +#-----------modify according to your personal info--------- + hpc_user <- "bsc32xxx" + expid <- "xxxx" # autosubmit exp id; can be NULL + autosubmit_suite_dir <- "/home/Earth//startR_local_autosubmit/" +#------------------------------------------------------------ + res <- Compute(wf1, + chunks = list(ensemble = 20, sdate = 2), + threads_load = 2, + threads_compute = 4, + cluster = list( + queue_host = 'nord3', + r_module = "R/4.1.2-foss-2019b", + autosubmit_module = 'autosubmit/4.0.0b-foss-2015a-Python-3.7.3', + cores_per_job = 2, + job_wallclock = '01:00:00', + max_jobs = 40, + polling_period = 10, + extra_queue_params = list('#SBATCH --constraint=medmem', '#SBATCH --exclusive'), + expid = NULL, + hpc_user = hpc_user + ), + workflow_manager = 'autosubmit', + autosubmit_suite_dir = autosubmit_suite_dir, + autosubmit_server = NULL, #'bscesautosubmit01', + wait = TRUE + )