Changes between Initial Version and Version 1 of Porting_to_OMI_PDAF3


Ignore:
Timestamp:
May 27, 2025, 3:56:41 PM (6 days ago)
Author:
lnerger
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Porting_to_OMI_PDAF3

    v1 v1  
     1= Porting an Existing Implementation to OMI =
     2
     3{{{
     4#!html
     5<div class="wiki-toc">
     6<h4>PDAF-OMI Guide</h4>
     7<ol><li><a href="PDAF_OMI_Overview_PDAF3">Overview</a></li>
     8<li><a href="OMI_Callback_obs_pdafomi_PDAF3">callback_obs_pdafomi.F90</a></li>
     9<li><a href="OMI_observation_modules_PDAF3">Observation Modules</a></li>
     10<li><a href="OMI_observation_operators_PDAF3">Observation operators</a></li>
     11<li><a href="OMI_error_checking_PDAF3">Checking error status</a></li>
     12<li><a href="OMI_debugging_PDAF3">Debugging functionality</a></li>
     13<li><a href="OMI_additional_functionality_PDAF3">Additional OMI Functionality</a></li>
     14<li><a href="Porting_to_OMI_PDAF3">Porting an existing implemention to OMI</a></li>
     15<br>
     16<li>Related pages in Implementation Guide<li>
     17<ol>
     18<li><a href="ImplementationofAnalysisStep_PDAF3">Implementing the analysis step</a></li>
     19<li><a href="nondiagonal_observation_error_covariance_matrices_PDAF3">Using nondiagonal R-matrices</a></<li>
     20</ol>
     21</ol>
     22</div>
     23}}}
     24
     25If you have an implementation of the data assimilation with PDAF without OMI, you can port it to OMI with the following steps:
     26
     271.      Install the current PDAF version which includes the OMI functionality (PDAF3.0 or later; we recommend to use the latest version)
     281.      In mod_assimilation declare an array `coords_l` for the coordinates of the local analysis domain. Then fill `coords_l` in `init_dim_l_pdaf`. These coordinates are later used in `init_dim_obs_l_pdafomi`.
     291.      Copy the template file `callback_obs_pdafomi.F90` to your code directory.
     301.      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/)
     311.      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)
     321.      For each observation type implement an obs-module as described in the [wiki:OMI_observation_modules_PDAF3 documention on the observation modules]
     331.      Add a call to `deallocate_obs_pdafomi()` are the end of your routine `prepoststep`.
     341.      Adapt the compilation to also compile `callback_obs_pdafomi.F90` and the obs-modules.
     351.      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.)
     36
     37'''Notes:'''
     38- In the implementation variant using PDAF's full interface one had to code separate routines for observation handling in global and local filters (e.g. `init_dim_obs` and `init_dim_obs_f_pdaf`. With OMI one no longer needs to distinguish, as OMI takes case of the different operations in case of global or local filters.
     39- With OMI we recommend to define the observation errors (`rms_obs_TYPE`) within each observation module instead of using the general module `mod_assimilation`.
     40- 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.