GLOMAP

Offline Oxidants fix

The location of the offline oxidants is set in the hand edit ~frjy/umui_jobs/hand_edits/config_offline_ncfiles_amekx.ed, which was setting UKCA_OFFLINE_DIR to /data/cr/cce/hadcj/ancil/offline_oxidants/Endgame. In here we have the five files, amekx_ox_H2O2.nc, amekx_ox_HO2.nc, amekx_ox_NO3.nc, amekx_ox_O3.nc and amekx_ox_OH.nc. These contain a global attribute `update_freq_in_hours', which was set to 1 hour - when it should be 5 days, which explains why so much time was spent in reading these files.

The attribute `update_freq_in_hours' has been changed to 120 hours (5 days) for the files in /data/cr/cce/hadcj/netcdf/n96, and I've re-run the Backward-Euler run.

Comparing the profiling for UKCA_MAIN1 before and after fix

In the table below, I've only looked at the routines involved in the fix (some of the other times will be slightly different, because any two runs will always have slightly different times).

Before fix

Routines Total mean time
UKCA_MAIN* (1,463s) 1,463s
UKCA_AERO_CTL (871s) UKCA_READ_OFFLINE_ OXIDANTS_CTL (212s) UKCA_ ACTIVATE (141s) 1,224s
UKCA_AERO_STEP (824s) UKCA_OFFLINE_ OXIDANTS_UPDATE (212s) UKCA_ ABDULRAZZAK_ GHAN (132s) 1,168s
UKCA_COAGWITHNUCL (368s) UKCA_ CONDEN (141s) UKCA_ CHECK_ MD_ND (70s, itself) UKCA_ CALCNUCRATE (69s) UKCA_ VOLUME_ MODE (50s) EM_GET_ DATA_REAL (116s, itself) EM_GET_ DATA_ REAL3D (65s, itself) Itself (125s) 1,004s
Itself (306s) UKCA_ SOLVECOAGNUCL _V (63s, itself) UKCA_ COND_ COFF_V (92s, itself) Itself (49s) UKCA_ BINAPARA (65s, itself) Itself (25s) 976s
*UCKA_MAIN also calls STASH.

After fix

Routines Total mean time
UKCA_MAIN* (1,272s) 1,272s
UKCA_AERO_CTL (871s) UKCA_READ_OFFLINE_ OXIDANTS_CTL (3s) UKCA_ ACTIVATE (141s) 1,015s
UKCA_AERO_STEP (824s) UKCA_OFFLINE_ OXIDANTS_UPDATE (3s) UKCA_ ABDULRAZZAK_ GHAN (132s) 959s
UKCA_COAGWITHNUCL (368s) UKCA_ CONDEN (141s) UKCA_ CHECK_ MD_ND (70s, itself) UKCA_ CALCNUCRATE (69s) UKCA_ VOLUME_ MODE (50s) EM_GET_ DATA_REAL (2s, itself) EM_GET_ DATA_ REAL3D (1s, itself) Itself (125s) 826s
Itself (306s) UKCA_ SOLVECOAGNUCL _V (63s, itself) UKCA_ COND_ COFF_V (92s, itself) Itself (49s) UKCA_ BINAPARA (65s, itself) Itself (25s) 798s
*UCKA_MAIN also calls STASH

Hence this fix has saved about 209s. This is reflected in the total mean time in UM_SHELL which with the tracer advection fix and this fix is 4,621s - a saving off 379s. (The code is 80.0% slower than CLASSIC now.)