Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 9 additions & 4 deletions Changelog.rst
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
version 3.17.0
--------------

**2025-??-??**
**2025-03-??**

* Set new minimum version of `dask`: ``2025.2.0``
(https://github.com/NCAS-CMS/cf-python/issues/849)
* Set a new minimum version of `numpy`: ``2.0.0``
(https://github.com/NCAS-CMS/cf-python/issues/843)
* Replace dataset aggregation functionality (CFA) with that imported
Expand All @@ -14,6 +16,9 @@ version 3.17.0
* Changed dependency: ``Python>=3.9.0``
* Changed dependency: ``numpy>=2.0.0``
* Changed dependency: ``cfdm>=1.12.0.0, <1.12.1.0``
* Changed dependency: ``dask>=2025.2.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``
Expand All @@ -26,6 +31,8 @@ version 3.16.3

**2025-01-28**

* Implementation of active storage reduction operations
(https://github.com/NCAS-CMS/cf-python/issues/501)
* Allow ``'nearest_dtos'`` 2-d regridding to work with discrete
sampling geometry source grids
(https://github.com/NCAS-CMS/cf-python/issues/832)
Expand All @@ -44,8 +51,6 @@ version 3.16.3
(https://github.com/NCAS-CMS/cf-python/issues/712)
* New class `cf.H5netcdfArray`
* New class `cf.NetCDF4Array`
* New class `cf.CFAH5netcdfArray`
* New class `cf.CFANetCDF4Array`
* Replace core `dask` functionality with that imported from `cfdm`
(https://github.com/NCAS-CMS/cf-python/issues/839)
* Fix bug that sometimes puts an incorrect ``radian-1`` or
Expand All @@ -65,7 +70,7 @@ version 3.16.3
global or near-global cyclic subspaces
(https://github.com/NCAS-CMS/cf-python/issues/828)
* New dependency: ``h5netcdf>=1.3.0``
* New dependency: ``h5py>=3.10.0``
* New dependency: ``h5py>=3.12.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``
Expand Down
20 changes: 7 additions & 13 deletions cf/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,8 @@

"""

__date__ = "2025-01-28"
__version__ = "3.16.3"
__date__ = "2025-03-??"
__version__ = "3.17.0"

_requires = (
"numpy",
Expand Down Expand Up @@ -124,9 +124,8 @@
_minimum_vn = "1.12.0.0"
_maximum_vn = "1.12.1.0"
_cfdm_version = Version(cfdm.__version__)
if (
_cfdm_version < Version(_minimum_vn) or
_cfdm_version >= Version(_maximum_vn)
if _cfdm_version < Version(_minimum_vn) or _cfdm_version >= Version(
_maximum_vn
):
raise RuntimeError(
"Bad cfdm version: cf requires "
Expand Down Expand Up @@ -202,15 +201,10 @@
except ImportError as error1:
raise ImportError(_error0 + str(error1))
else:
_minimum_vn = "2024.6.1"
_maximum_vn = "2024.7.1"
if (
Version(dask.__version__) < Version(_minimum_vn) or
Version(dask.__version__) > Version(_maximum_vn)
):
_minimum_vn = "2025.2.0"
if Version(dask.__version__) < Version(_minimum_vn):
raise ValueError(
"Bad dask version: cf requires "
f"{_minimum_vn}<=dask<={_maximum_vn}. "
f"Bad dask version: cf requires dask>={_minimum_vn}. "
f"Got {dask.__version__} at {dask.__file__}"
)

Expand Down
2 changes: 1 addition & 1 deletion cf/dimensioncoordinate.py
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ def anchor(self, value, cell=False, parameters=None, inplace=False):
*value*; or is the closest to cell to *value* from above
(below) for increasing (decreasing) coordinates.

.. versionadded:: 1.11.2.0
.. versionadded:: 3.16.3

.. seealso:: `period`, `roll`

Expand Down
4 changes: 2 additions & 2 deletions cf/field.py
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ class _Axis_characterisation:
Used by `_binary_operation` to help with ascertaining if there is
a common axis in two fields.

.. versionaddedd:: 1.11.2.0
.. versionaddedd:: 3.16.3

"""

Expand Down Expand Up @@ -13710,7 +13710,7 @@ def derivative(
by default, or ``m.s-1`` if *ignore_coordinate_units*
is True.

.. versionadded:: 1.11.2.0
.. versionadded:: 3.16.3

{{inplace: `bool`, optional}}

Expand Down
32 changes: 16 additions & 16 deletions cf/functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -269,18 +269,18 @@ def configuration(
reductions or False to disable them). The default is to
not change the current behaviour.

.. versionadded:: 1.11.2.0
.. versionadded:: 3.16.3

active_storage_url: `str` or `None` or `Constant`, optional
The new value (either a new URL string or `None` to remove
the URL). The default is to not change the value.

.. versionadded:: 1.11.2.0
.. versionadded:: 3.16.3

active_storage_max_requests: `int` or `Constant`, optional
The new value. The default is to not change the value.

.. versionadded:: 1.11.2.0
.. versionadded:: 3.16.3

of_fraction: `float` or `Constant`, optional
Deprecated at version 3.14.0 and is no longer
Expand Down Expand Up @@ -1132,7 +1132,7 @@ def _parse(cls, arg):
class active_storage(ConstantAccess):
"""Whether or not to attempt active storage reductions.

.. versionadded:: 1.11.2.0
.. versionadded:: 3.16.3

.. seealso:: `active_storage_max_requests`, `active_storage_url`,
`configuration`
Expand Down Expand Up @@ -1171,7 +1171,7 @@ class active_storage(ConstantAccess):
def _parse(cls, arg):
"""Parse a new constant value.

.. versionaddedd:: 1.11.2.0
.. versionaddedd:: 3.16.3

:Parameters:

Expand Down Expand Up @@ -1201,7 +1201,7 @@ def _parse(cls, arg):
class active_storage_url(ConstantAccess):
"""The URL location of the active storage reducer.

.. versionadded:: 1.11.2.0
.. versionadded:: 3.16.3

.. seealso:: `active_storage`, `active_storage_max_requests`,
`configuration`
Expand Down Expand Up @@ -1240,7 +1240,7 @@ class active_storage_url(ConstantAccess):
def _parse(cls, arg):
"""Parse a new constant value.

.. versionaddedd:: 1.11.2.0
.. versionaddedd:: 3.16.3

:Parameters:

Expand Down Expand Up @@ -1283,7 +1283,7 @@ class active_storage_max_requests(ConstantAccess):
collapse operation are utilising active storage. If some are not
then :math:`N` will likely be underestimated.

.. versionadded:: 1.11.2.0
.. versionadded:: 3.16.3

.. seealso:: `active_storage`, `active_storage_url`,
`configuration`
Expand Down Expand Up @@ -1322,7 +1322,7 @@ class active_storage_max_requests(ConstantAccess):
def _parse(cls, arg):
"""Parse a new constant value.

.. versionaddedd:: 1.11.2.0
.. versionaddedd:: 3.16.3

:Parameters:

Expand Down Expand Up @@ -1488,7 +1488,7 @@ def total_memory():
def is_log_level_info(logger):
"""Return True if and only if log level is at least as verbose as INFO.

.. versionadded:: 1.11.2.0
.. versionadded:: 3.16.3

.. seealso:: `log_level`

Expand Down Expand Up @@ -3193,7 +3193,7 @@ def environment(display=True, paths=True):
udunits2 library: /home/user/lib/libudunits2.so.0
esmpy/ESMF: 8.6.1 /home/user/lib/python3.12/site-packages/esmpy/__init__.py
Python: 3.12.2 /home/user/bin/python
dask: 2024.6.0 /home/user/lib/python3.12/site-packages/dask/__init__.py
dask: 2025.2.0 /home/user/lib/python3.12/site-packages/dask/__init__.py
netCDF4: 1.6.5 /home/user/lib/python3.12/site-packages/netCDF4/__init__.py
h5netcdf: 1.3.0 /home/user/lib/python3.12/site-packages/h5netcdf/__init__.py
h5py: 3.11.0 /home/user/lib/python3.12/site-packages/h5py/__init__.py
Expand All @@ -3206,8 +3206,8 @@ def environment(display=True, paths=True):
cftime: 1.6.3 /home/user/lib/python3.12/site-packages/cftime/__init__.py
cfunits: 3.3.7 /home/user/lib/python3.12/site-packages/cfunits/__init__.py
cfplot: 3.3.0 /home/user/lib/python3.12/site-packages/cfplot/__init__.py
cfdm: 1.11.2.0 /home/user/cfdm/cfdm/__init__.py
cf: 1.11.2.0 /home/user/cf-python/cf/__init__.py
cfdm: 1.12.0.0 /home/user/cfdm/cfdm/__init__.py
cf: 3.17.0 /home/user/cf-python/cf/__init__.py

>>> cf.environment(paths=False)
Platform: Linux-5.15.0-122-generic-x86_64-with-glibc2.35
Expand All @@ -3216,7 +3216,7 @@ def environment(display=True, paths=True):
udunits2 library: /home/user/lib/libudunits2.so.0
esmpy/ESMF: 8.6.1
Python: 3.12.2
dask: 2024.6.0
dask: 2025.2.0
netCDF4: 1.6.5
h5netcdf: 1.3.0
h5py: 3.11.0
Expand All @@ -3229,8 +3229,8 @@ def environment(display=True, paths=True):
cftime: 1.6.3
cfunits: 3.3.7
cfplot: 3.3.0
cfdm: 1.11.2.0
cf: 1.11.2.0
cfdm: 1.12.0.0
cf: 3.17.0

"""
dependency_version_paths_mapping = {
Expand Down
2 changes: 1 addition & 1 deletion cf/mixin/fielddomain.py
Original file line number Diff line number Diff line change
Expand Up @@ -2311,7 +2311,7 @@ def is_discrete_axis(self, *identity, **filter_kwargs):

* The axis with geometry cells.

.. versionaddedd:: 1.11.2.0
.. versionaddedd:: 3.16.3

.. seealso:: `domain_axis`, `coordinates`

Expand Down
3 changes: 1 addition & 2 deletions docs/source/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,7 @@ Required

* `numpy <http://www.numpy.org>`_, versions 2.0.0 or newer.

* `dask <https://pypi.org/project/dask>`_, versions 2024.6.0 to
2024.7.1 inclusive.
* `dask <https://pypi.org/project/dask>`_, versions 2025.2.0 or newer.

* `netCDF4 <https://pypi.org/project/netcdf4/>`_, 1.7.2 or newer.

Expand Down
6 changes: 6 additions & 0 deletions docs/source/releases.rst
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,15 @@ Documentation for all versions of cf.
:local:
:backlinks: entry

**CF-1.12**
-----------

* `Version 3.17.0 <https://ncas-cms.github.io/cf-python-docs/3.17.0>`_ (2025-03-??)

**CF-1.11**
-----------

* `Version 3.16.3 <https://ncas-cms.github.io/cf-python-docs/3.16.3>`_ (2025-01-28)
* `Version 3.16.2 <https://ncas-cms.github.io/cf-python-docs/3.16.2>`_ (2024-04-26)
* `Version 3.16.1 <https://ncas-cms.github.io/cf-python-docs/3.16.1>`_ (2024-03-01)
* `Version 3.16.0 <https://ncas-cms.github.io/cf-python-docs/3.16.0>`_ (2023-12-06)
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ numpy>=2.0.0
cfdm>=1.12.0.0, <1.12.1.0
psutil>=0.6.0
cfunits>=3.3.7
dask>=2024.6.0,<=2024.7.1
dask>=2025.2.0
packaging>=20.0
scipy>=1.10.0