Skip to content

Commit e0ddde8

Browse files
authored
Merge branch 'main' into aggregation3
2 parents 404a544 + 2b76ecd commit e0ddde8

File tree

11 files changed

+43
-27
lines changed

11 files changed

+43
-27
lines changed

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
See issue #XXX for discussion of these changes.
22

33
# Release checklist
4-
- [ ] Authors updated in `cf-conventions.adoc`? Add in two places: on line 3 and under `.Additional Authors` in `About the authors`.
5-
- [ ] Next version in `cf-conventions.adoc` up to date? Versioning inspired by [SemVer](https://semver.org).
64
- [ ] `history.adoc` up to date?
75
- [ ] Conformance document up to date?
86

appa.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ Identifies the roles of mesh topology and location index set variables (see <<ap
114114
| S
115115
| C
116116
| <<climatological-statistics>>
117-
| Identifies a climatology variable.
117+
| Identifies a climatology boundary variable.
118118

119119
| **`comment`**
120120
| S

cf-conventions.adoc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
include::version.adoc[]
22
= NetCDF Climate and Forecast (CF) Metadata Conventions
3-
Brian{nbsp}Eaton; Jonathan{nbsp}Gregory; Bob{nbsp}Drach; Karl{nbsp}Taylor; Steve{nbsp}Hankin; John{nbsp}Caron; Rich{nbsp}Signell; Phil{nbsp}Bentley; Greg{nbsp}Rappa; Heinke{nbsp}Höck; Alison{nbsp}Pamment; Martin{nbsp}Juckes; Martin{nbsp}Raspaud; Randy{nbsp}Horne; Jon{nbsp}Blower; Timothy{nbsp}Whiteaker; David{nbsp}Blodgett; Charlie{nbsp}Zender; Daniel{nbsp}Lee; David{nbsp}Hassell; Alan{nbsp}D.{nbsp}Snow; Tobias{nbsp}Kölling; Dave{nbsp}Allured; Aleksandar{nbsp}Jelenak; Anders{nbsp}Meier{nbsp}Soerensen; Lucile{nbsp}Gaultier; Sylvain{nbsp}Herlédan; Fernando{nbsp}Manzano; Lars{nbsp}Bärring; Christopher{nbsp}Barker; Sadie{nbsp}Bartholomew; Bryan{nbsp}Lawrence; Neil{nbsp}Massey
3+
Brian{nbsp}Eaton; Jonathan{nbsp}Gregory; Bob{nbsp}Drach; Karl{nbsp}Taylor; Steve{nbsp}Hankin; John{nbsp}Caron; Rich{nbsp}Signell; Phil{nbsp}Bentley; Greg{nbsp}Rappa; Heinke{nbsp}Höck; Alison{nbsp}Pamment; Martin{nbsp}Juckes; Martin{nbsp}Raspaud; Randy{nbsp}Horne; Jon{nbsp}Blower; Timothy{nbsp}Whiteaker; David{nbsp}Blodgett; Charlie{nbsp}Zender; Daniel{nbsp}Lee; David{nbsp}Hassell; Alan{nbsp}D.{nbsp}Snow; Tobias{nbsp}Kölling; Dave{nbsp}Allured; Aleksandar{nbsp}Jelenak; Anders{nbsp}Meier{nbsp}Soerensen; Lucile{nbsp}Gaultier; Sylvain{nbsp}Herlédan; Fernando{nbsp}Manzano; Lars{nbsp}Bärring; Christopher{nbsp}Barker; Sadie{nbsp}Bartholomew; Thomas Lavergne; Bryan{nbsp}Lawrence; Neil{nbsp}Massey
44
:revnumber: {current-version}
55
:revdate: {docprodtime}
66
:doctype: book
@@ -72,6 +72,7 @@ include::toc-extra.adoc[]
7272
* Lars Bärring, SMHI
7373
* Christopher Barker, NOAA
7474
* Sadie Bartholomew, NCAS and University of Reading
75+
* Thomas Lavergne, MET Norway
7576
* Bryan Lawrence, NCAS and University of Reading
7677
* Neil Massey, NCAS and STFC
7778

ch01.adoc

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,9 @@ The word "apex" refers to position of this group at the vertex of the tree of gr
109109

110110
longitude dimension:: A dimension of a netCDF variable that has an associated longitude coordinate variable.
111111

112-
most rapidly varying dimension:: The dimension of a multidimensional variable for which elements are adjacent in storage. When netCDF is represented in CDL, the most rapidly varying dimension is the last one e.g. **`x`** in **`float data(z,y,x)`**. C and Python NumPy use the same order as C, also called "column-major order", but Fortran uses the opposite convention, also called "row-major order", so that when netCDF variables are accessed in Fortran the most rapidly varying dimension is the first one.
112+
most rapidly varying dimension:: The dimension of a multidimensional variable for which elements are adjacent in storage.
113+
When a netCDF dataset is represented in CDL, the most rapidly varying dimension is the last one e.g. **`x`** in **`float data(z,y,x)`**.
114+
C and Python NumPy use the same order as CDL, also called "row-major order", while Fortran and R use the alternative order, also called "column-major order", so that when netCDF variables are accessed in Fortran or R the most rapidly varying dimension is the first one.
113115

114116
multidimensional coordinate variable:: An auxiliary coordinate variable that is multidimensional.
115117

ch03.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ But since it is an optional attribute, applications that implement these standar
1111
[[units, Section 3.1, "Units"]]
1212
=== Units
1313

14-
The **`units`** attribute is required for all variables that represent dimensional quantities (except for boundary variables defined in <<cell-boundaries>> and climatology variables defined in <<climatological-statistics>>).
14+
The **`units`** attribute is required for all variables that represent dimensional quantities (except for boundary variables defined in <<cell-boundaries>> and climatology boundary variables defined in <<climatological-statistics>>).
1515
The **`units`** attribute is permitted but not required for dimensionless quantities (see <<dimensionless-units>>).
1616

1717
The value of the **`units`** attribute is a string that can be recognized by the UDUNITS package <<UDUNITS>>, with the exceptions that are given in <<dimensionless-units>> and <<units-multiples>>.

ch04.adoc

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -237,24 +237,25 @@ All the alternatives have exactly the same meaning in UDUNITS.
237237
For compatibility with other software, CF strongly recommends that `since` should be used.
238238

239239
The reference datetime string (appearing after the identifier **`since`**) is required.
240-
It may include date alone, or date and time, or date, time and time zone offset.
241-
Its format is __y__-__m__-__d__ [__H__:__M__:__S__ [__Z__]], where [...] indicates an optional element,
240+
It must include the date, which may optionally be followed by time or time zone offset or both. Its format is __y__-__m__-__d__ [__H__:__M__:__S__] [__Z__], where [...] indicates an optional element:
242241

243242
* _y_ is year, _m_ month, _d_ day, _H_ hour and _M_ minute, which are all integers of one or more digits, and _y_ may be prefixed with a sign (but note that some CF calendars do not permit negative years; see <<calendar>>),
244243

245244
* _S_ is second, which may be integer or floating point (see <<leap-seconds>> regarding __S__>59),
246245

247-
* _Z_ is the time zone offset with respect to UTC.
246+
* _Z_ is the time zone offset.
248247
This is an interval of time, specified in one of the formats described below.
249-
Only numbers (digits, `+`, `-` and `:`) are allowed in _Z_, not time zone names or acronyms.
248+
Only numbers (digits, `+`, `-` and `:`) or the letter "Z" are allowed in _Z_, not time zone names or acronyms.
250249

251250
The default time zone offset is zero.
252251
In a time zone with zero offset, time (approximately) equals mean solar time for 0 `degrees_east` of longitude.
253252
(Although this may be exact in a model, in reality the time with zero time zone offset differs by some seconds from mean solar time; see the discussion of UTC and leap seconds in <<calendar>>.)
254253
If both time and time zone offset are omitted the time is 00:00:00 (the beginning of the day i.e. midnight at 0 `degrees_east`).
255-
Thus, **`units = "days since 1990-1-1"`** means the same as **`units = "days since 1990-1-1 0:0:0"`**.
254+
Thus, **`units = "days since 1990-1-1"`** means the same as **`units = "days since 1990-1-1 00:00:00"`**.
256255

257-
The time zone offset _Z_ must be in one of the following four formats, any of which may be prefixed with a sign:
256+
The time zone offset _Z_ must be in one of the following five formats, where numeric hours may optionally be prefixed with a `+` or `-` sign:
257+
258+
** The letter `Z` indicating zero offset, sometimes referred to as "Zulu Time".
258259

259260
** _H_, the hour alone, of one or two digits e.g. **`-6`**, **`2`**, **`+11`**, which is sufficient for many time zones.
260261

@@ -264,6 +265,10 @@ The time zone offset _Z_ must be in one of the following four formats, any of wh
264265

265266
** three digits, of which the first is the hour (0--9) e.g. **`530`**.
266267

268+
If the time zone offset is the letter `Z` or begins with a sign, the space before it may be omitted.
269+
270+
While the default (of omitting the _Z_ component) is an offset of zero, we suggest that a zero offset be specified to avoid any confusion where omitting it might be misunderstood as indicating local time.
271+
267272
For example, **`seconds since 1992-10-8 15:15:42.5 -6:00`** indicates seconds since October 8th, 1992 at 3 hours, 15 minutes and 42.5 seconds in the afternoon, in a time zone where the datetime is six hours behind the default.
268273
Subtracting the time zone offset from a given datetime converts it to the equivalent datetime with zero time zone offset e.g. **`1989-12-31 18:00:00 -6`** identifies the same instant as **`1990-1-1 0:0:0`**.
269274

@@ -400,7 +405,7 @@ When these calendars are being be used for timelines _with_ leap seconds (i.e. c
400405
* A datetime in the excluded range must not be used as a reference datetime e.g. **`seconds since 2016-12-31 23:59:60`** is not a permitted value for **`units`**.
401406

402407
* The coordinate value does not count any leap seconds which occurred between the reference datetime and the datetime represented by the coordinate.
403-
For instance, 60 **`seconds after 23:59:00`** always means 00:00:00 on the next day, even if there is a leap second at 23:59:60, which makes the actual interval 61 seconds between 23:59:00 and 00:00:00 on the next day.
408+
For instance, 60 **`seconds after 23:59:00`** always means 0:0:0 on the next day, even if there is a leap second at 23:59:60, which makes the actual interval 61 seconds between 23:59:00 and 0:0:0 on the next day.
404409

405410
Because of the last point, the difference between two coordinate values with the same **`units`** string does not exactly equal the length of the interval between instants they represent if there were any leap seconds between them.
406411
This discrepancy can happen in cases 2, 3 and 4 of the **`standard`**, **`proleptic_gregorian`**, and **`julian`** calendars.

ch05.adoc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -192,6 +192,10 @@ A __grid mapping variable__ provides this information.
192192
If no __grid mapping variable__ is provided and the coordinate variables for a horizontal grid are not longitude and latitude, then it is required that the latitude and longitude coordinates are supplied via the `coordinates` attribute.
193193
Such coordinates may be provided in addition to the provision of a __grid mapping variable__, but that is not required.
194194

195+
When a data variable is representative of cells of non-zero size, and the coordinate variables are not longitude and latitude, __bounds__ variables should be provided for vertices of the cell boundaries in the horizontal coordinates of the grid (see <<cell-boundaries>>).
196+
The __grid mapping variable__ provides then the information to convert bounds in latitude and longitude coordinates, and it is optional for the dataset to provide these.
197+
If no __grid mapping variable__ is provided, then the cell extents in latitude and longitude coordinate system should be provided (see <<cell-boundaries>> and especially Example 7.2 for the common case of four-sided cells).
198+
195199
A grid mapping variable provides the description of the mapping via a collection of attached attributes.
196200
It is of arbitrary type since it contains no data.
197201
Its purpose is to act as a container for the attributes that define the mapping.

ch07.adoc

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ dimensions:
7070
variables:
7171
float time(time);
7272
time:standard_name = "time";
73-
time:units = "days since 2024-11-8 09:00:00";
73+
time:units = "days since 2024-11-8 09:00:00Z";
7474
time:bounds = "time_bnds";
7575
float time_bnds(time,nv);
7676
----
@@ -330,7 +330,7 @@ variables:
330330
ppn:cell_methods = "time: sum";
331331
double time(time);
332332
time:long_name = "time";
333-
time:units = "h since 1998-4-19 6:0:0";
333+
time:units = "h since 1998-4-19 6:0:0 Z";
334334
time:bounds = "time_bnds";
335335
double time_bnds(time,nv);
336336
data:
@@ -400,7 +400,7 @@ variables:
400400
TS_var:units="K2";
401401
TS_var:cell_methods="time: variance (interval: 1 hr comment: sampled instantaneously)";
402402
float time(time);
403-
time:units="days since 1990-01-01 00:00:00";
403+
time:units="days since 1990-01-01 00:00:00 Z";
404404
time:bounds="time_bnds";
405405
float time_bnds(time,nv);
406406
data:
@@ -520,9 +520,10 @@ In addition the two concepts may be used at once, for instance to indicate not A
520520
Climatological variables have a climatological time axis.
521521
Like an ordinary time axis, a climatological time axis may have a dimension of unity (for example, a variable containing the January average temperatures for 1961-1990), but often it will have several elements (for example, a climatological time axis with a dimension of 12 for the climatological average temperatures in each month for 1961-1990, a dimension of 3 for the January mean temperatures for the three decades 1961-1970, 1971-1980, 1981-1990, or a dimension of 24 for the hours of an average day).
522522
Intervals of climatological time are conceptually different from ordinary time intervals; a given interval of climatological time represents a set of subintervals which are not necessarily contiguous.
523-
To indicate this difference, a climatological time coordinate variable does not have a **`bounds`** attribute.
524-
Instead, it has a **`climatology`** attribute, which names a variable with dimensions (n,2), n being the dimension of the climatological time axis.
525-
Using the units and calendar of the time coordinate variable, element (i,0) of the climatology variable specifies the beginning of the first subinterval and element (i,1) the end of the last subinterval used to evaluate the climatological statistics with index i in the time dimension.
523+
To indicate this difference, a climatological time coordinate variable does not have a **`bounds`** attribute, instead it has a **`climatology`** attribute which names the climatological boundary variable.
524+
The climatological boundary variable must have dimensions (n,2), n being the dimension of the climatological time axis.
525+
The rules and recommendations for attributes of the climatological boundary variable are the same as those for boundary variables in general, as described in <<cell-boundaries>>.
526+
Using the units and calendar of the time coordinate variable, element (i,0) of the climatology boundary variable specifies the beginning of the first subinterval and element (i,1) the end of the last subinterval used to evaluate the climatological statistics with index i in the time dimension.
526527
The time coordinates should be values that are representative of the climatological time intervals, such that an application which does not recognise climatological time will nonetheless be able to make a reasonable interpretation.
527528

528529
For compatibility with the COARDS standard, a climatological time coordinate in the default **`standard`** and **`julian`** calendars may be indicated by setting the datetime reference string in the time coordinate's **`units`** attribute to midnight at 0 `degrees_east` on 1 January in year 0 (i.e., **`since 0-1-1`**).
@@ -679,8 +680,7 @@ It now applies to April from a 1961-1990 climatology.
679680
variables:
680681
float temperature(time,lat,lon);
681682
temperature:long_name="surface air temperature";
682-
temperature:cell_methods="time: mean within days ",
683-
"time: mean over days time: mean over years";
683+
temperature:cell_methods="time: mean within days time: mean over days time: mean over years";
684684
temperature:units="K";
685685
double time(time);
686686
time:climatology="climatology_bounds";

conformance.adoc

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ References can be absolute, relative or with no path, in which case, the variabl
180180

181181
*Requirements:*
182182

183-
* The **`units`** attribute is required for all variables that represent dimensional quantities (except for boundary variables defined in https://cfconventions.org/cf-conventions/cf-conventions.html#cell-boundaries[section 7.1] and climatology variables defined in https://cfconventions.org/cf-conventions/cf-conventions.html#climatological-statistics[section 7.4]).
183+
* The **`units`** attribute is required for all variables that represent dimensional quantities (except for boundary variables defined in https://cfconventions.org/cf-conventions/cf-conventions.html#cell-boundaries[section 7.1] and climatology boundary variables defined in https://cfconventions.org/cf-conventions/cf-conventions.html#climatological-statistics[section 7.4]).
184184
* The type of the **`units`** attribute is a string that must be recognizable by the UDUNITS package.
185185
Exceptions are the units **`level`**, **`layer`**, and **`sigma_level`**.
186186
* Dimensionless units for volume fractions defined by UDUNITS (**`ppv`**, **`ppmv`**, **`ppbv`**, **`pptv`**, **`ppqv`**) are not allowed in the **`units`** attribute of any variable which also has a **`standard_name`** attribute.
@@ -500,10 +500,10 @@ The _value_ must be a valid number and the _unit_ a string that is recognizable
500500
* The **`climatology`** attribute may only be attached to a time coordinate variable.
501501
* The type of the **`climatology`** attribute is a string whose value is a single variable name.
502502
The specified variable must exist in the file.
503-
* A climatology variable must have the same dimension as its associated time coordinate variable, and have a trailing dimension (CDL order) of size 2.
504-
* A climatology variable must be a numeric data type.
505-
* If a climatology variable has **`units`**, **`standard_name`**, or **`calendar`** attributes, they must agree with those of its associated variable.
506-
* A climatology variable must not have **`_FillValue`** or **`missing_value`** attributes.
503+
* A climatology boundary variable must have the same dimension as its associated time coordinate variable, and have a trailing dimension (CDL order) of size 2.
504+
* A climatology boundary variable must be a numeric data type.
505+
* If a climatology boundary variable has **`units`**, **`standard_name`**, or **`calendar`** attributes, they must agree with those of its associated variable.
506+
* A climatology boundary variable must not have **`_FillValue`** or **`missing_value`** attributes.
507507

508508
[[geometries]]
509509
=== 7.5 Geometries

history.adoc

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@
55
[[revhistory, Revision History]]
66
== Revision History
77

8+
=== Version 1.13-draft
9+
10+
* {issues}590[Issue #590]: Clarify that grid_mapping can also be used for converting spatial bounds
11+
* {issues}593[Issue #593]: Clarify that rules for attributes of boundary variables (including BI and BO) also apply for attributes of climatological boundary variables
12+
* {issues}583[Issue #583]: Correct "most rapidly varying dimension" in terminology section.
13+
* {issues}584[Issue #584]: Allow `Z` as time-zone offset, with a couple of examples, and allow time-zone offset with date alone, both being consistent with UDUNITS syntax.
814
* {issues}508[Issue #508]: Introduce aggregation variables
915

1016
=== Version 1.12 (04 December 2024)

0 commit comments

Comments
 (0)