Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MDA8 #863

Closed
WillemVanCaspel opened this issue May 22, 2023 · 8 comments · Fixed by #1224
Closed

MDA8 #863

WillemVanCaspel opened this issue May 22, 2023 · 8 comments · Fixed by #1224
Assignees
Labels
CAMS2_83 Issues related to the CAMS2_83 contract enhancement ✨ New feature or request good first issue Good for newcomers
Milestone

Comments

@WillemVanCaspel
Copy link
Collaborator

Hi everyone,

The daily maximum of the 8-hourly running mean ozone concentration (MDA8) is a metric often used by the WHO, and it would be really great if the observed values could be compared to EMEP (the model already outputs it). Is there any chance it would be possible to evaluate MDA8 using pyaerocom?

Willem

@jgriesfeller
Copy link
Member

In principle this should be easy to add since we calculate the variable vmro3max e.g. at EBAS (grepping through the code for vmro3max reveals this):

data/variables.ini:[vmro3max]
data/variables.ini:var_name = vmro3max
data/emep_variables.ini:vmro3max = "SURF_MAXO3"
data/ebas_config.ini:[vmro3max]
aux_var_helpers.py:def calc_vmro3max(data):
aux_var_helpers.py:    new_var_name = "vmro3max"
aux_var_helpers.py:    o3max = data[var_name]
aux_var_helpers.py:    return o3max
plugins/mep/aux_vars.py:def vmro3max_from_ds(ds: xr.Dataset) -> xr.DataArray:
plugins/mep/aux_vars.py:    return conc_to_vmr(ds["conco3"], vmr="vmro3max")
plugins/mep/reader.py:from .aux_vars import vmrno2_from_ds, vmro3_from_ds, vmro3max_from_ds
plugins/mep/reader.py:        "vmro3max": vmro3max_from_ds,
plugins/mscw_ctm/emep_variables.toml:vmro3max = "SURF_MAXO3"
aeroval/glob_defaults.py:    "vmro3max": {"scale": [0, 7.5, 15, 22.5, 30, 37.5, 45, 52.5, 60], "colmap": "coolwarm"},
aeroval/glob_defaults.py:    vmro3max=["O3Max", "3D", "Volume mixing ratios"],
io/read_ebas.py:    calc_vmro3max,
io/read_ebas.py:        "vmro3max": ["vmro3"],
io/read_ebas.py:        "vmro3max": calc_vmro3max,
io/read_eea_aqerep_base.py:    VAR_NAMES_FILE["vmro3max"] = "concentration"
io/read_eea_aqerep_base.py:        vmro3max="**/??_7_*_timeseries.csv*",
io/read_eea_aqerep_base.py:    CONV_FACTOR["vmro3max"] = np.float_(
io/read_eea_aqerep_base.py:    CONV_UNIT["vmro3max"] = "ppb"
io/read_eea_aqerep_base.py:        "vmro3max": ["conco3"],
io/read_eea_aqerep_base.py:        "vmro3max": NotImplementedError(),

so adding the calculation of the 8hourly running mean should be easy.

I suggest vmrmda8 as variable name

@lewisblake lewisblake added enhancement ✨ New feature or request good first issue Good for newcomers low-hanging-fruit-🍎 bare blåbær labels May 23, 2023
@lewisblake
Copy link
Member

Check the WHO definition for how this is computed. What is the minimum temporal coverage required to compute this statistics?

@lewisblake
Copy link
Member

Which project should allocate resources for this / how badly is it needed?

@WillemVanCaspel
Copy link
Collaborator Author

It's not needed very badly. Since posting this issue, I have made my own post-processing script that calculates peak season MDA8 from the co-location data files produced by Pyaerocom.

@lewisblake
Copy link
Member

Michael G says:

yes, MDA8 is needed for the FAIRMODE plots

I can also confirm that the 8-hour average is only to be calculated if at least 6 out of 8 measurements are available

what I haven't found out yet is which 8-hour means are to be calculated during a day. There are different methods found on the internet. E.g. 0-7, 1-8, ... 16-23, i.e. 17 averages per day. Some authors, as we know, consider a day to last from 6 UTC to 6 UTC. I've also read somewhere that there are 24 8-hour averages during one day (which sounds weird..) oh dear... I'll ask Meteo France what they've done during the last 10 years, and we'll do the same for continuity. I'll let you know.

@lewisblake lewisblake added the CAMS2_83 Issues related to the CAMS2_83 contract label Feb 7, 2024
@WillemVanCaspel
Copy link
Collaborator Author

From the EU directive document annex XI:

Eight hours values:         75 % of values (i.e. 6 hours)

Maximum daily 8-hour mean:  75 % of the hourly running eight hour
                            averages (i.e. 18 eight hour averages per
                            day)
                            
The maximum daily eight hour mean concentration will be selected by examining 
eight hour running averages, calculated from hourly data and updated each hour. 
Each eight hour average so calculated will be assigned to the day on which it 
ends i.e. the first calculation period for any one day will be the period from 
17:00 on the previous day to 01:00 on that day; the last calculation period for 
any one day will be the period from 16:00 to 24:00 on that day.

@michaelgau
Copy link
Collaborator

yeah, sorry I was slow, had a visitor over lunch. So Willem is write, and this is also what MeteoF is doing.

@michaelgau
Copy link
Collaborator

In CAMS2_83 we have to evaluate 1-day analyses and 4-day forecasts. The 8-hour averages starting on the previous day cannot be processed in the case of the first days. Thus I think for the one day of the analysis and the 1st day of the forecast we can calculate only 17 averages. ...unless we mix data from analyses/forecasts that are issued on different days, but that would make it a bit messy.

@heikoklein heikoklein added this to the m2024-05 milestone Apr 10, 2024
@lewisblake lewisblake removed the low-hanging-fruit-🍎 bare blåbær label May 6, 2024
@lewisblake lewisblake modified the milestones: m2024-05, m2024-06 May 8, 2024
@thorbjoernl thorbjoernl mentioned this issue May 8, 2024
9 tasks
@heikoklein heikoklein modified the milestones: m2024-06, m2024-07 Jun 5, 2024
@thorbjoernl thorbjoernl mentioned this issue Jun 24, 2024
9 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CAMS2_83 Issues related to the CAMS2_83 contract enhancement ✨ New feature or request good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants