Version 7 (modified by 21 months ago) (diff) | ,
---|
Porting an Existing Implementation to OMI
PDAF-OMI Guide
If you have an implementation of the data assimilation with PDAF without OMI, you can port it to OMI with the following steps:
- Install the current PDAF version which includes the OMI functionality (V1.16 or later)
- In mod_assimilation declare an array
coords_l
for the coordinates of the local analysis domain. Then fillcoords_l
ininit_dim_l_pdaf
. These coordinates are later used ininit_dim_obs_l_pdafomi
. - Copy the template file
callback_obs_pdafomi.F90
to your code directory. - In
assimilate_pdaf
replace the call(s) to PDAF_put_state_X or PDAF_assimilate_X by the calls to PDAFomi_put_state_local/global or PDAFomi_assimilate_local/global (You can copy this from the template files in templates/) - In
assimilate_pdaf
further replace the declaration of the 'EXTERNAL' subroutines following the template (several of the routines are no longer present with PDAF-OMI, while those that remain now have the suffix_pdafomi
(like init_dim_obs_pdafomi) - For each observation type implement an obs-module as described in the documention on the observation modules
- Add a call to
deallocate_obs_pdafomi()
are the end of your routineprepoststep
. - Adapt the compilation to also compile
callback_obs_pdafomi.F90
and the obs-modules. - Modify the compilation such that the include-directory of your PDAF installation is defined as an include directory (i.e. specify -IPDAF_ROOT/include where PDAF_ROOT is the root directory of your PDAF installation.)
Notes:
- In the classical implementation variant one had to code separate routines for observation handling in global and local filters (e.g.
init_dim_obs
andinit_dim_obs_f_pdaf
. With OMI is it longer necessary to distinguish, as OMI takes case of the different operations in case of global or local filters. - With OMI we recommend to define the observation errors (
rms_obs_TYPE
) within each observation module instead of using the general modulemod_assimilation
. - While it is not done in the template and tutorial codes, one can move the localization parameters (locweight, cradius, sradius) into each observation module. This allos to easily define separate localization values for each observation type.