-
Notifications
You must be signed in to change notification settings - Fork 300
Closed
Description
Following the decision from #2599, we need to implement the approach we decide on
Reference:
- [FB] PR [FB] [PI-3478] Common metadata API #3583
- [FB] PR [FB] [PI-3478] Lenient metadata #3739
- [FB] PR [FB] [PI-3478] Lenient cube arithmetic #3774
- PR [PI-3478] Merge cube arithmetic feature branch #3785 (
cube-arithmeticfeature branch merge back tomaster) - [FB] PR [FB] [PI-3478] Fix resolve free flip of src/tgt mapping #3805
- [FB] PR [FB] [PI-3478] cube arithmetic whatsnew entries #3806
- [FB] PR [FB] [PI-3478] Add resolve doc-strings #3842
- [FB] PR [FB] [PI-3478] Metadata and cube maths documentation #3869
- PR Cube arithmetic docs to master #3890 (
cube-arithmetic-docsfeature branch merge back tomaster)
Acceptance Criteria
Core deliverables
- Add lenient infra-structure:
- client decorator
- service decorator
- context manager
- runtime options state manager (thread-safe)
- client/service active protocol
- Support lenient metadata functionality:
- comparison
- combination
- difference
- Support lenient coordinate (macroscopic) compliance checking
-
Add cube arithmetic switch to opt-in to previous/strict behaviour - Remove
AncillaryVariables andCellMeasures from resultant cube - Test coverage
- Discuss
metadatarename tosignature? @pp-mo - Add associated ASV metrics
- Resolve dilemma of whether
circularis part ofDimCoordmetadata- what are the implications of this?
- require
DimCoordMetadata,AuxCoordMetadataandCoordMetadata(common parent) support - utility of supporting cross-metadata setting for
DimCoordandAuxCoord
- require
- what are the implications of this?
- Close connective tissue PRs/Issues
- Add supporting documentation and examples etc
- Clarify metadata
namevsidentity - Define lenient/strict operations for
__eq__,combineanddifference <container>.metadatasetter/getter patterns
- Clarify metadata
- Add
whatsnewentry
Optional deliverables
Not sure whether some of these may get pulled into the core deliverables...
- Support lenient coodinate metadata in
iris.cube.Cube.coordsiris.cube.Cube.replace_coordiris.cube.Cube.remove_coord
- Unify metadata into a common API returning
namedtuplederived classes:-
Uselru_cachefor optimised LUT metadata generation- Issues with non-hashable metadata 😢
attributescoord_system
- Issues with non-hashable metadata 😢
- Create a common
BaseMetadataclass hierarchy- Use a
_BaseMetametaclass - Include Python2
<support ofNone
- Use a
-
iris.coords._DimensionalMetadata._is_defn->iris.coords._DimensionalMetadata.metadata(BaseMetadata) -
iris.coords.AncillaryVariable.metadata(BaseMetadata) -
iris.coords.CellMeasure._as_defn->iris.coords.CellMeasure.metadata(CellMeasureMetadata) -
iris.coords.Coord._as_defn->iris.coords.Coord.metadata(CoordMetadata) -
iris.iterate._CoordWrapper._as_defn->iris.iterate._CoordWrapper.metadata(CoordMetadata) -
iris.aux_factory.AuxCoordFactory._as_defn->iris.aux_factory.AuxCoordFactory.metadata - Resolve
STASHonly specific toiris.cube.Cube- fix
name()method - fix
namesproperty
- fix
-
- Deprecate:
-
iris.cube.Cube.is_compatible -
iris.coords.Coord.is_compatible -
iris.util.as_compatible_shape -
iris.util.describe_diff
-
-
Backport to2.3.0:-
Addfutureswitch for new arithmetic -
Add supporting documentation and examples etc -
Add awhatsnewentry
-
Future work
- Rename
iris.coords._DimensionalMetadatato... - Rename
iris.analysis._dimensional_metadata_comparisonto... -
RenameSTASHtostashinNamesnamedtuple - Optimise performance by keeping metadata state not in the container classes
- Default units clarification, see Default units #3585
- Create
iris.corewith associated re-organisation -
RemovecircularfromDimCoordequality and make it a calculated@property -
Unified treatment of attributesSTASH/GRIB_CODE - Support
@lenient_clientand@lenient_serviceon same function/method
rcomer