Changes between Version 1 and Version 2 of PDAF3_init_parallel


Ignore:
Timestamp:
Mar 28, 2026, 12:17:41 PM (3 days ago)
Author:
lnerger
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • PDAF3_init_parallel

    v1 v2  
    1212The interface is the following:
    1313{{{
    14   SUBROUTINE PDAF3_init_parallel(screen, type_parallel, online_coupling, n_modeltasks, dim_ens, &
     14  SUBROUTINE PDAF3_init_parallel(screen, type_parallel, online_coupling, dim_ens, n_modeltasks, &
    1515       COMM_model, mype_model, npes_model, COMM_assim, mype_assim, npes_assim, &
    1616       task_id)
    1717
     18    ! Input variables
    1819    INTEGER, INTENT(in)    :: screen          ! >0 for display information about the parallelization setup
    19 
    20     ! Input variables
    2120    INTEGER, INTENT(in) :: type_parallel      ! Type of parallelization (currently not uesed)
    2221    INTEGER, INTENT(in) :: online_cpl         ! 1: online DA coupling, 0: offline DA coupling
    2322    INTEGER, INTENT(in) :: dim_ens            ! Ensemble size
    2423
    25     ! Input variable that might be updated in the routine
     24    ! Input variables that might be updated in the routine
    2625    INTEGER, INTENT(inout) :: n_modeltasks    ! Number of model tasks
    27     INTEGER, INTENT(out) :: COMM_model        ! Input: Model MPI communicator
     26    INTEGER, INTENT(inout) :: COMM_model      ! Input: Model MPI communicator
    2827                                              ! Output: Model communicator split for model tasks
    29 
    3028    ! Output variables
    3129    INTEGER, INTENT(out) :: npes_model        ! Number of Processs in COMM_model
     
    4240* The template and tutorial codes show the use of `PDAF3_init_parallel` in the file `init_parallel_pdaf.F90`.
    4341* For the offline DA coupling, the routine always sets `n_modeltasks=1` independent of the input value.
     42* The routine can be called without a prior initialization of the MPI environment (i.e. call to MPI_init). In this case the routine will initialize MPI and then perform the the parallelization setup according to the values of `n_modeltasks` and `dim_ens`.
     43* The value of `n_modeltasks` cannot be larger than the number of processes in the execution of the DA program. If this is the case, the routine sets `n_modeltasks=npes_model`
     44* The value of `dim_ens` is used for consistency checking (`n_modeltasks` cannot be larger than `dim_ens`; if this is the case, the routine sets `n_modeltasks=dim_ens`). The check is deactivated with `dim_ens=0` is provided to the routine.