climate_ref_core.cmor
#
CMOR controlled vocabularies shared across source types.
frequency_from_mip_table(value)
#
Reduce a CMOR MIP table name to its CMIP6 frequency CV value.
Some datasets record frequency and not the MIP table.
This maps a table (e.g. Amon -> mon) onto the same axis.
A value that is already a valid frequency is returned unchanged,
so a caller reading a layout that stores mon or day can use this without branching.
day and fx are both a table name and a frequency, and map to themselves either way.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
value
|
str
|
A CMOR MIP table name ( |
required |
Returns:
| Type | Description |
|---|---|
str
|
The corresponding CMIP6 frequency. |
Raises:
| Type | Description |
|---|---|
ValueError
|
If the value is neither a known MIP table nor a known frequency. Failing loudly is
deliberate: silently defaulting would let a mis-parsed path collapse two datasets that
differ only by frequency onto one |