Releases: NCAS-CMS/cf-python
Releases · NCAS-CMS/cf-python
3.18.1
2025-08-20
- New methods to allow changing units in a chain:
cf.Field.to_units
,cf.Data.to_units
(#874) - Allow multiple conditions for the same axis in
cf.Field.subspace
andcf.Field.indices
(#881) - Fix bug in
cf.Field.collapse
that causes aValueError
to be raised for missing external cell measures data (#885) - New dependency:
distributed>=2025.5.1
- Changed dependency:
cfdm>=1.12.3.0, <1.12.4.0
What's Changed
- Docs: fix DOI badge at source & patch in built docs (to avoid rebuild) by @sadielbartholomew in #877
- New
to_units
methods to allow changing units in a chain by @davidhassell in #875 - Add
distributed
as required dependency with version pin by @sadielbartholomew in #880 cf.Field.subspace
- allow multiple subspacing conditions for the same axis by @davidhassell in #882cf.Field.collapse
fails when cell measure has external data by @davidhassell in #886- Added troubleshooting for installing cf next to Jupyter and conda by @ThatDesert in #884
New Contributors
- @ThatDesert made their first contribution in #884
Full Changelog: v3.18.0...v3.18.1
3.18.0
2025-06-05
- Implement lossy compression via quantization (#870)
- New quantization class:
cf.Quantization
(#870) - New quantization methods:
cf.Field.get_quantization
,cf.Field.get_quantize_on_write
,cf.Field.set_quantize_on_write
,cf.Field.del_quantize_on_write
(#870) - New keyword parameter to
cf.write
:chunk_cache
(#871) - Read Zarr datasets with
cf.read
(#863) - Update CF aggregation keywords (#868)
- New keyword parameter to
cf.DimensionCoordinate.create_bounds
:inplace
(#855) - Set new minimum version of
dask
:2025.5.1
(#866) - Changed dependency:
cfdm>=1.12.2.0, <1.12.3.0
- Changed dependency:
dask>=2025.5.1
3.17.0
2025-04-02
- Set new minimum version of
dask
:2025.2.0
(#849) - Set a new minimum version of
numpy
:2.0.0
(#843) - Replace dataset aggregation functionality (CFA) with that imported from
cfdm
(#841) - New keyword parameter to
cf.Field.compute_vertical_coordinates
:key
(#802) - New keyword parameter to
cf.histogram
:density
(#794) - Fix bug that caused
Data._axes
to be incorrect after a call tocf.Field.collapse
(#857) - Fix bug that caused wrong directions from
cf.DimensionCoordinate.direction
(#859) - Changed dependency:
Python>=3.9.0
- Changed dependency:
numpy>=2.0.0
- Changed dependency:
cfdm>=1.12.1.0, <1.12.2.0
- Changed dependency:
dask>=2025.2.0, <=2025.3.0
- Changed dependency:
netCDF4>=1.7.2
- Changed dependency:
cftime>=1.6.4
- Changed optional dependency:
esmpy>=8.7.0
- Removed dependency (now incorporated into
cfdm
):h5py
- Removed dependency (now incorporated into
cfdm
):h5netcdf
- Removed dependency (now incorporated into
cfdm
):s3fs
3.16.3
2025-01-28
- Allow
'nearest_dtos'
2-d regridding to work with discrete sampling geometry source grids (#832) - New method:
cf.Field.filled
(#811) - New method:
cf.Field.is_discrete_axis
(#784) - Include the UM version as a field property when reading UM files (#777)
- Fix bug that caused climatological time collapses within/over days to fail (#809)
- New keyword parameter to
cf.Field.derivative
:ignore_coordinate_units
(#807) - Allow access to netCDF-4 files in S3 object stores (#712)
- New class
cf.H5netcdfArray
- New class
cf.NetCDF4Array
- New class
cf.CFAH5netcdfArray
- New class
cf.CFANetCDF4Array
- Replace core
dask
functionality with that imported fromcfdm
(#839) - Fix bug that sometimes puts an incorrect
radian-1
orradian-2
in the returned units of the differential operator methods and functions (#807) - Fix bug where
cf.example_fields
returned alist
of Fields rather than aFieldlist
(#725) - Fix bug where combining UGRID fields erroneously creates an extra axis and broadcasts over it (#784)
- Fix bug where
cf.normalize_slice
doesn't correctly handle certain cyclic slices (#774) - Fix bug where
cf.Field.subspace
doesn't always correctly handle global or near-global cyclic subspaces (#828) - New dependency:
h5netcdf>=1.3.0
- New dependency:
h5py>=3.10.0
- New dependency:
s3fs>=2024.6.0
- Changed dependency:
numpy>=1.15,<2.0
- Changed dependency:
1.11.2.0<=cfdm<1.11.3.0
- Changed dependency:
cfunits>=3.3.7
- Changed dependency:
dask>=2024.6.0,<=2024.7.1
3.16.2
2024-04-26
- Improve the performance of reading and accessing the data of PP and UM fields files (#746)
- Improve
cf.Field.collapse
performance by lazily computing reduced axis coordinates (#741) - Improve
cf.Field.__getitem__
performance by not re-calculating axis cyclicity (#744) - Reduce output CFA netCDF file size by setting the HDF5 chunksizes of CFA variables to be no larger than required (#739)
- Allow a halo to be added by
cf.Field.indices
andcf.Field.subspace
(#759) - Added spherical regridding to discrete sampling geometry destination grids (#716)
- Added 3-d spherical regridding to
cf.Field.regrids
, and the option to regrid the vertical axis in logarithmic coordinates tocf.Field.regrids
andcf.Field.regridc
(#715) - New keyword parameter to
cf.Field.regrids
andcf.Field.regridc
:return_esmpy_regrid_operator
(#766) - New keyword parameters to
cf.wi
:open_lower
andopen_upper
(#740) - Fix misleading error message when it is not possible to create area weights requested from
cf.Field.collapse
(#731) - Fix bug in
cf.read
when reading UM files that caused LBPROC value 131072 (Mean over an ensemble of parallel runs) to be ignored (#737) - Fix bug in
cf.aggregate
that sometimes put a null transpose operation into the Dask graph when one was not needed (#754) - Fix bug in
cf.aggregate
that caused a failure when property values werenumpy
arrays with two or more elements (#764) - Fix bug in
cf.aggregate
that didn't correctly handle the "actual_range" CF attribute (#764) - Fix bug whereby
Field.cyclic
is not updated after aField.del_construct
operation (#758) - Fix bug that meant
cyclic()
always returned an empty set for domains produced bycf.Field.domain
(#762) - Changed dependency:
cfunits>=3.3.7
- Changed dependency:
netCDF4>=1.6.5
3.16.1
2024-03-01
- Allow DSG trajectories with identical
trajectory_id
values to be aggregated (#723) - New methods:
cf.Field.pad_missing
andcf.Data.pad_missing
(#717) - Fix occasional bug when calculating UGRID cell areas when non-spatial coordinates span the discrete axis (#721)
- New keyword parameter to
cf.Field.insert_dimension
:constructs
(#719) - Added the
cell_measures
andcoordinates
keyword arguments tocf.Field.weights
(#709) - Added the
cell_measures
,coordinates
,return_cell_measure
, andmethods
keyword arguments tocf.Field.cell_area
(#709) - Allow
cf.Data
to be initialised withxarray.DataAarray
(#706) - Fix bug that caused
cf.Field.del_file_location
to fail when updating its metadata constructs (#707) - Fix bug that caused incorrect data arrays in some cyclic subspaces created by
cf.Field.subspace
andcf.Field.__getitem__
(#713) - Changed dependency:
1.11.1.0<=cfdm<1.11.2.0
3.16.0
2023-12-06
- Implemented the reading and manipulation of UGRID mesh topologies (#696)
- New methods:
cf.Field.cell_connectivity
,cf.Field.cell_connectivities
(#696) - New methods:
cf.Field.domain_topology
,cf.Field.domain_topologies
(#696) - New method:
cf.Data.masked_values
(#696) - New method:
cf.Data.arctan2
(#38) - Fix bug that caused
cf.Field.collapse
to give incorrect results for the "sum", "sum_of_weights" and "sum_of_weights2" methods, only in the case that weights have been requested (#701) - Changed dependency:
1.11.0.0<=cfdm<1.11.1.0
- New dependency:
scipy>=1.10.0
3.15.4
2023-10-10
- Record dimension coordinate cell characteristics (#692)
- New set of methods to query, set, del, and
get_cell_characteristics
- Fix bug in
cf.Field.match_by_construct
that always returned True for 1-d constructs whose axis is not in the data, even when the
criterion was not matched (#691) - Fix bug that prevented "https://" netCDF files from being read (#699)
3.15.3
3.15.2
2023-07-21
- Performance improvements to
cf.Field.regrids
andcf.Field.regridc
(#675) - Performance improvements to
cf.read
when reading datasets with compression-by-convention (#671) - New keyword parameter to
cf.Field.regrids
andcf.Field.regridc
:weights_file
(#675) - New keyword parameter to
cf.aggregate
:cells
(#452) - New function:
cf.isclose
(#661) - Allow
cf.Data
and other objects that have data (such ascf.DimensionCoordinate
) to be used as indices (#677) - Fix bug that caused
cf.Field.regrids
andcf.Field.regridc
to fail when the regrid axes are chunked with more than one chunk (#665) - Fix bug that caused
cf.read
to fail for some PP data with a single vertical level (#667) - Changed dependency:
1.10.1.1<=cfdm<1.10.2.0