Changes between Version 5 and Version 6 of OfflineAddingMemoryandTimingInformation
- Timestamp:
- May 18, 2025, 7:52:59 PM (5 hours ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
OfflineAddingMemoryandTimingInformation
v5 v6 24 24 PDAF provides functions to display the memory required by the array allocated inside PDAF. In addition, information about the execution duration of different parts of PDAF can be displayed. These information can be obtained by calling the routine `PDAF_print_info`. 25 25 26 The calls described here are implemented in `finalize_pdaf.F90` in the template and tutorial codes. One can directly use these routines without changes. 27 26 28 == Displaying memory information == 27 29 28 Information about the memory required by PDAF through allocated arrays can be obtained by inserting into the program the line30 Information about the memory required by PDAF through allocated arrays is provided by the call 29 31 {{{ 30 CALL PDAF_print_info(2)32 if (mype_world==0) CALL PDAF_print_info(10) 31 33 }}} 32 34 The function displays the following information … … 46 48 }}} 47 49 48 Currently only the memory required by the first process of the filter processes is displayed. Thus the total required memory should be the displayed memory multiplied by the number of processes in `COMM_filter`. 50 This memory information shows only the memory required by a single filter processes. In the example codes, this is the process with `mype_world=0`. One can also display the overall allocated memory by adding 51 {{{ 52 CALL PDAF_print_info(11) 53 }}} 54 to the routine `finalize_pdaf`. 49 55 50 56 == Displaying timing information == 51 57 52 Timing information can be displayed by adding58 Timing information is displayed by the call 53 59 {{{ 54 CALL PDAF_print_info( 1)60 CALL PDAF_print_info(3) 55 61 }}} 56 62 to the code. This will provide an output like 57 63 {{{ 58 PDAF Timing information 59 --------------------------------------------- 60 Generate state ensemble: 0.513 s 61 Time of forecasts: 0.010 s 62 Time for assimilation: 0.200 s 63 ensemble transformation: 0.245 s 64 Time of prepoststep: 0.016 s 64 PDAF PDAF Timing information - call-back routines 65 PDAF ---------------------------------------------------- 66 PDAF Initialize PDAF: 2.761 s 67 PDAF init_ens_pdaf: 2.760 s 68 PDAF LESTKF analysis: 62.393 s 69 PDAF PDAF-internal operations: 32.830 s 70 PDAF OMI-internal routines: 12.946 s 71 PDAF init_n_domains_pdaf: 0.000 s 72 PDAF init_dim_l_pdaf: 0.031 s 73 PDAF Time in OMI observation module routines 74 PDAF init_dim_obs_pdafomi: 0.410 s 75 PDAF obs_op_pdafomi: 0.006 s 76 PDAF init_dim_obs_l_pdafomi: 15.759 s 77 PDAF prepoststep_pdaf: 4.473 s 65 78 }}} 66 Mode detailed information can be obtained using a value of 3 or 4 in the call to `PDAF_print_info`. 79 This timing display is particularly aimed at distinguishing the time spent in call-back routines from the time spent in PDAF-internal routines or PDAF-OMI internal routines. This timing information indicate those call-back routines that need particularly much time. 67 80 81 Less detailed information cab be obtained using a value of 1, and more detailed information can be obtained using a value of 4 in the call to `PDAF_print_info`. 82