Open trexfeathers opened 1 month ago
This might be a naive question, but is there a use case for having different grid mappings for different coordinates?
This might be a naive question, but is there a use case for having different grid mappings for different coordinates?
The CF data model actually attaches grid mappings to the data variables, which has often seemed odd to us. Following CF would force us to NOT have different grid mappings for different coordinates.
Of course Iris has done the more 'sensible' thing of storing coordinate systems on the coordinates themselves, since that is where they have meaning, so this allows coordinates to 'move around' and be used in different Cube
s. And it already allows for different grid mappings on different coordinates - they just can't be saved.
Whatever we do with this issue will need to account for different coordinates having different CoordSystem
s.
This might be a naive question, but is there a use case for having different grid mappings for different coordinates?
The CF data model actually attaches grid mappings to the data variables, which has often seemed odd to us. Following CF would force us to NOT have different grid mappings for different coordinates.
Of course Iris has done the more 'sensible' thing of storing coordinate systems on the coordinates themselves, since that is where they have meaning, so this allows coordinates to 'move around' and be used in different
Cube
s. And it already allows for different grid mappings on different coordinates - they just can't be saved.Whatever we do with this issue will need to account for different coordinates having different
CoordSystem
s.
Well, that's only the case for the "classic" grid-mapping syntax. There is provision in CF for different coord systems applying to different coordinates. .. but it's outstanding work for us to support it See : https://github.com/SciTools/iris/issues/3388
This might be on its way now, since we are hoping to make https://github.com/SciTools/iris/pull/4719 work
Probably I was misunderstanding the comment
... coordinate_system objects aren't shared across coordinates ...
as meaning that e.g. x and y coordinates could have different gridmappings attached to them. But, as was noted in #3388, referring to CF Example 5.10, a data variable, Cube
, may have several gridmappings, but each one is attached to the coordinates (plural) that define the grid.
@SciTools/peloton Sorry for any confusion, here's what we know:
We can't think of a use-case for different coord systems on x and y, although there might be one we don't know about. Iris can store this situation now, but all of Iris' operations assume that they will be identical. The CF extended grid mapping makes it possible to load and save different coord systems, see #3388 for making this possible in Iris.
From conversations on https://github.com/SciTools/iris/pull/4719: