Create new environment
- Dominant language
- Python
- Stars
- 7
- Forks
- 10
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 5
Description
## Summary
Post 3.0 release we should create a new environment from the `environment.yml`.
Ideally, we should be unpinning and using up to date versions of everything. The exception is numpy 2: we should stick to numpy <= 1.26.4. Enabling the [ruff rule](https://numpy.org/doc/stable/numpy_2_0_migration_guide.html#ruff-plugin) for identifying code that needs to be updated for numpy 2 should be the first step towards the numpy 2 upgrade.
## Notes from previous experiments
There are functions in [ants.utils._dask](https://github.com/MetOffice/ANTS/blob/main/lib/ants/utils/_dask.py) that just wrap private iris functions (in `iris._lazy_data`). The behaviour of `iris._lazy_data.as_lazy_data` has changed slightly, it now requires a meta argument when passing data which is not a numpy or dask array. We use this function when loading raster data with GDAL ([ants.fileformats.raster](https://github.com/MetOffice/ANTS/blob/06fdecaeb3850d06cb3f2e50c6d12cae2040843a/lib/ants/fileformats/raster.py#L349)), passing a `_GdalDataProxy` object rather than a numpy array. The change in iris behaviour has caused our raster unit tests to fail (frustratingly, the test for `ants.utils._dask.as_lazy_data` didn't fail).
My suggestion is that we remove the wrapper and just use the iris function directly.
In fact I think we should remove `ants.utils._dask` entirely, I don't think the other functions in there are actually used.
Using a newer version of iris means we no longer need to filter the datum warning on load.
Contributor guide
Assessment
This issue has not been assessed yet.