[Git][debian-gis-team/dask-image][master] 6 commits: New upstream version 2026.5.0+ds
Antonio Valentino (@antonio.valentino)
gitlab at salsa.debian.org
Wed May 27 21:20:59 BST 2026
Antonio Valentino pushed to branch master at Debian GIS Project / dask-image
Commits:
a45998f6 by Antonio Valentino at 2026-05-27T19:48:51+00:00
New upstream version 2026.5.0+ds
- - - - -
493665bf by Antonio Valentino at 2026-05-27T19:48:51+00:00
Update upstream source from tag 'upstream/2026.5.0+ds'
Update to upstream version '2026.5.0+ds'
with Debian dir 333b98bf4029753c164f502eb32844af788ea169
- - - - -
791d4ebf by Antonio Valentino at 2026-05-27T19:53:18+00:00
New upstream release
- - - - -
f18774d2 by Antonio Valentino at 2026-05-27T19:54:17+00:00
Refresh all patches
- - - - -
81f0cf12 by Antonio Valentino at 2026-05-27T19:57:22+00:00
Recommend python3-pandas
- - - - -
f8e8e9c6 by Antonio Valentino at 2026-05-27T19:58:12+00:00
Set distribution to unstable
- - - - -
15 changed files:
- .github/workflows/test_and_deploy.yml
- HISTORY.rst
- dask_image/ndmeasure/__init__.py
- dask_image/ndmeasure/_utils/_find_objects.py
- debian/changelog
- debian/control
- debian/patches/0001-No-pytest-flake8.patch
- − debian/patches/0002-Fix-installed-packages.patch
- − debian/patches/0003-numpy-v2.4-compat.patch
- debian/patches/series
- pyproject.toml
- tests/test_dask_image/test_ndfilters/test__generic.py
- tests/test_dask_image/test_ndmeasure/test_core.py
- tests/test_dask_image/test_ndmeasure/test_find_objects.py
- + tests/test_dask_image/test_ndmeasure/test_find_objects_no_dataframe.py
Changes:
=====================================
.github/workflows/test_and_deploy.yml
=====================================
@@ -20,10 +20,10 @@ jobs:
steps:
- name: Checkout source
- uses: actions/checkout at v5
+ uses: actions/checkout at v6
- name: Setup Conda Environment
- uses: conda-incubator/setup-miniconda at v3
+ uses: conda-incubator/setup-miniconda at v4
with:
python-version: ${{ matrix.python-version }}
environment-file: continuous_integration/environment-${{ matrix.python-version }}.yml
@@ -34,7 +34,7 @@ jobs:
shell: bash -l {0}
run: |
conda activate dask-image-testenv
- python -m pip install -e .
+ python -m pip install -e .[dataframe]
conda list
- name: Run tests
@@ -42,19 +42,40 @@ jobs:
run: pytest -v --cov=dask_image --cov-report lcov
- name: Coveralls Parallel
- uses: coverallsapp/github-action at v2.3.6
+ uses: coverallsapp/github-action at v2.3.7
with:
github-token: ${{ secrets.github_token }}
flag-name: run-${{ matrix.test_number }}
parallel: true
path-to-lcov: coverage.lcov
+ test-minimal:
+ # Verify dask-image works without the optional `dataframe` extras
+ # (i.e. without pandas and dask[dataframe]).
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout source
+ uses: actions/checkout at v6
+
+ - name: Set up Python
+ uses: actions/setup-python at v6
+ with:
+ python-version: "3.12"
+
+ - name: Install dask-image without dataframe extras
+ run: |
+ python -m pip install --upgrade pip
+ python -m pip install -e .[test]
+
+ - name: Run tests (find_objects tests are skipped automatically)
+ run: pytest -v
+
coveralls:
needs: test
runs-on: ubuntu-latest
steps:
- name: Coveralls Finished
- uses: coverallsapp/github-action at v2.3.6
+ uses: coverallsapp/github-action at v2.3.7
with:
github-token: ${{ secrets.github_token }}
parallel-finished: true
@@ -71,7 +92,7 @@ jobs:
runs-on: ubuntu-latest
if: contains(github.ref, 'tags')
steps:
- - uses: actions/checkout at v5
+ - uses: actions/checkout at v6
- name: Set up Python
uses: actions/setup-python at v6
with:
=====================================
HISTORY.rst
=====================================
@@ -2,6 +2,48 @@
History
=======
+v2026.05.0 (2026-05-26)
+-----------------------
+
+We're pleased to announce the release of dask-image v2026.05.0!
+
+Highlights
+
+Highlights of this release include making the dask dataframe dependency optional,
+improving packaging and compatibility with Numpy v2.4.
+
+Bug Fixes
+
+* Compatibility with Numpy v2.4 (#425)
+* Fix package discovery in pyproject.toml (#422)
+* Bump tifffile to ensure functionality used in imread tests (#424)
+
+API Changes
+
+* Make dataframe dependencies optional (#429)
+
+Other Pull Requests
+
+* Bump actions/checkout from 5 to 6 (#420)
+* Bump coverallsapp/github-action from 2.3.6 to 2.3.7 (#421)
+* Bump conda-incubator/setup-miniconda from 3 to 4 (#430)
+* Bump actions/checkout from 5 to 6 (#433)
+
+5 authors added to this release (alphabetical)
+
+* `Antonio Valentino <https://github.com/dask/dask-image/commits?author=avalentino>`_ - @avalentino
+* `dependabot[bot] <https://github.com/dask/dask-image/commits?author=dependabot[bot]>`_ - @dependabot[bot]
+* `Genevieve Buckley <https://github.com/dask/dask-image/commits?author=GenevieveBuckley>`_ - @GenevieveBuckley
+* `Marvin Albert <https://github.com/dask/dask-image/commits?author=m-albert>`_ - @m-albert
+* `Thomas Robitaille <https://github.com/dask/dask-image/commits?author=astrofrog>`_ - @astrofrog
+
+
+2 reviewers added to this release (alphabetical)
+
+* `Copilot <https://github.com/dask/dask-image/commits?author=Copilot>`_ - @Copilot
+* `Genevieve Buckley <https://github.com/dask/dask-image/commits?author=GenevieveBuckley>`_ - @GenevieveBuckley
+
+
v2025.11.0 (2025-11-12)
-----------------------
=====================================
dask_image/ndmeasure/__init__.py
=====================================
@@ -9,7 +9,6 @@ import dask.config as dask_config
import dask.array as da
import dask.bag as db
-import dask.dataframe as dd
import numpy as np
from . import _utils
@@ -228,9 +227,21 @@ def find_objects(label_image):
Notes
-----
- You must have the optional dependency ``dask[dataframe]`` installed
- to use the ``find_objects`` function.
+ You must have the optional dependencies ``dask[dataframe]`` and
+ ``pandas`` installed to use the ``find_objects`` function. They can
+ be installed together via the ``dataframe`` extras group:
+ ``pip install dask-image[dataframe]``.
"""
+ try:
+ import pandas # noqa: F401 # used by the private helpers below
+ import dask.dataframe as dd
+ except ImportError as e:
+ raise ImportError(
+ "dask_image.ndmeasure.find_objects requires the optional "
+ "dependencies `dask[dataframe]` and `pandas`. Install them "
+ "with `pip install dask-image[dataframe]`."
+ ) from e
+
if label_image.dtype.char not in np.typecodes['AllInteger']:
raise ValueError("find_objects only accepts integer dtype arrays")
=====================================
dask_image/ndmeasure/_utils/_find_objects.py
=====================================
@@ -1,7 +1,5 @@
import numpy as np
-import pandas as pd
from dask.delayed import Delayed
-import dask.dataframe as dd
import dask.config as dask_config
@@ -24,6 +22,8 @@ def _find_bounding_boxes(x, array_location):
This alternative function returns a pandas dataframe,
with one row per object found in the image chunk.
"""
+ import pandas as pd
+
unique_vals = np.unique(x)
unique_vals = unique_vals[unique_vals != 0]
result = {}
@@ -53,6 +53,8 @@ def _combine_slices(slices):
def _merge_bounding_boxes(x, ndim):
"Merge the bounding boxes describing objects over multiple image chunks."
+ import pandas as pd
+
x = x.dropna()
data = {}
# For each dimension in the array,
@@ -72,6 +74,9 @@ def _merge_bounding_boxes(x, ndim):
def _find_objects(ndim, df1, df2):
"""Main utility function for find_objects."""
+ import pandas as pd
+ import dask.dataframe as dd
+
meta = dd.utils.make_meta([(i, object) for i in range(ndim)])
if isinstance(df1, Delayed):
with dask_config.set({'dataframe.convert-string': False}):
=====================================
debian/changelog
=====================================
@@ -1,13 +1,16 @@
-dask-image (2025.11.0+ds-3) UNRELEASED; urgency=medium
+dask-image (2026.5.0+ds-1) unstable; urgency=medium
[ Antonio Valentino ]
+ New upstream release (Closes: #1131052).
* debian/patches:
- - New 0003-numpy-v2.4-compat.patch (Closes: #1131052).
+ - Drop 0002-Fix-installed-packages.patch, applied upstream.
+ * debian/control:
+ - Recommend python3-pandas.
[ Bas Couwenberg ]
* Bump Standards-Version to 4.7.4, no changes.
- -- Antonio Valentino <antonio.valentino at tiscali.it> Sat, 21 Mar 2026 18:48:05 +0000
+ -- Antonio Valentino <antonio.valentino at tiscali.it> Wed, 27 May 2026 19:57:50 +0000
dask-image (2025.11.0+ds-2) unstable; urgency=medium
=====================================
debian/control
=====================================
@@ -36,6 +36,7 @@ Package: python3-dask-image
Architecture: all
Depends: ${python3:Depends},
${misc:Depends}
+Recommends: python3-pandas
Description: ${source:Synopsis}
${source:Extended-Description}
=====================================
debian/patches/0001-No-pytest-flake8.patch
=====================================
@@ -8,13 +8,15 @@ Forwarded: not-needed
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pyproject.toml b/pyproject.toml
-index 56989b0..0528fb8 100644
+index e4a0b1e..12a432a 100644
--- a/pyproject.toml
+++ b/pyproject.toml
-@@ -70,5 +70,5 @@ exclude = [
+@@ -73,7 +73,7 @@ include = [
]
[tool.pytest.ini_options]
-addopts = "--flake8"
+# addopts = "--flake8"
markers = "cupy"
+
+ [tool.flake8]
=====================================
debian/patches/0002-Fix-installed-packages.patch deleted
=====================================
@@ -1,24 +0,0 @@
-From: Antonio Valentino <antonio.valentino at tiscali.it>
-Date: Sat, 28 Feb 2026 20:17:19 +0000
-Subject: Fix installed packages
-
-Forwarded: https://github.com/dask/dask-image/pull/422
----
- pyproject.toml | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/pyproject.toml b/pyproject.toml
-index 0528fb8..1779f24 100644
---- a/pyproject.toml
-+++ b/pyproject.toml
-@@ -65,8 +65,8 @@ license-files = [
- ]
-
- [tool.setuptools.packages.find]
--exclude = [
-- "tests*",
-+include = [
-+ "dask_image*",
- ]
-
- [tool.pytest.ini_options]
=====================================
debian/patches/0003-numpy-v2.4-compat.patch deleted
=====================================
@@ -1,22 +0,0 @@
-From: Antonio Valentino <antonio.valentino at tiscali.it>
-Date: Sat, 21 Mar 2026 18:47:30 +0000
-Subject: numpy-v2.4-compat
-
-Forwarded: https://github.com/dask/dask-image/pull/425
----
- tests/test_dask_image/test_ndmeasure/test_core.py | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/tests/test_dask_image/test_ndmeasure/test_core.py b/tests/test_dask_image/test_ndmeasure/test_core.py
-index 3bbdc6d..f614889 100644
---- a/tests/test_dask_image/test_ndmeasure/test_core.py
-+++ b/tests/test_dask_image/test_ndmeasure/test_core.py
-@@ -142,7 +142,7 @@ def test_measure_props(funcname, shape, chunks, has_lbls, ind):
- if (
- funcname == "median" and
- ind is not None and
-- not np.in1d(np.atleast_1d(ind), lbls).all()
-+ not np.isin(np.atleast_1d(ind), lbls).all()
- ):
- pytest.skip("SciPy's `median` mishandles missing labels.")
-
=====================================
debian/patches/series
=====================================
@@ -1,3 +1 @@
0001-No-pytest-flake8.patch
-0002-Fix-installed-packages.patch
-0003-numpy-v2.4-compat.patch
=====================================
pyproject.toml
=====================================
@@ -24,15 +24,18 @@ classifiers = [
"Programming Language :: Python :: 3.12",
]
dependencies = [
- "dask[array,dataframe] >=2024.4.1",
+ "dask[array] >=2024.4.1",
"numpy >=1.18",
"scipy >=1.7.0",
- "pandas >=2.0.0",
"pims >=0.4.1",
- "tifffile >=2018.10.18",
+ "tifffile >=2020.10.1",
]
[project.optional-dependencies]
+dataframe = [
+ "dask[dataframe] >=2024.4.1",
+ "pandas >=2.0.0",
+]
test = [
"build >=1.2.1",
"coverage >=7.2.1",
@@ -65,10 +68,13 @@ license-files = [
]
[tool.setuptools.packages.find]
-exclude = [
- "tests*",
+include = [
+ "dask_image*",
]
[tool.pytest.ini_options]
addopts = "--flake8"
markers = "cupy"
+
+[tool.flake8]
+exclude = ["dask_image/_version.py"]
=====================================
tests/test_dask_image/test_ndfilters/test__generic.py
=====================================
@@ -70,9 +70,9 @@ def test_generic_filter_shape_type(da_func):
@pytest.mark.parametrize(
"function, size, footprint",
[
- (lambda x: x, 1, None),
- (lambda x: x, (1, 1), None),
- (lambda x: x, None, np.ones((1, 1))),
+ (lambda x: x[0], 1, None),
+ (lambda x: x[0], (1, 1), None),
+ (lambda x: x[0], None, np.ones((1, 1))),
],
)
def test_generic_filter_identity(sp_func, da_func, function, size, footprint):
@@ -94,7 +94,7 @@ def test_generic_filter_identity(sp_func, da_func, function, size, footprint):
],
)
def test_generic_filter_comprehensions(da_func):
- da_wfunc = lambda arr: da_func(arr, lambda x: x, 1) # noqa: E731
+ da_wfunc = lambda arr: da_func(arr, lambda x: x[0], 1) # noqa: E731
np.random.seed(0)
=====================================
tests/test_dask_image/test_ndmeasure/test_core.py
=====================================
@@ -142,7 +142,7 @@ def test_measure_props(funcname, shape, chunks, has_lbls, ind):
if (
funcname == "median" and
ind is not None and
- not np.in1d(np.atleast_1d(ind), lbls).all()
+ not np.isin(np.atleast_1d(ind), lbls).all()
):
pytest.skip("SciPy's `median` mishandles missing labels.")
=====================================
tests/test_dask_image/test_ndmeasure/test_find_objects.py
=====================================
@@ -1,10 +1,12 @@
-import dask.array as da
-import dask.dataframe as dd
-import numpy as np
-import pandas as pd
import pytest
-import dask_image.ndmeasure
+pd = pytest.importorskip("pandas")
+dd = pytest.importorskip("dask.dataframe")
+
+import dask.array as da # noqa: E402
+import numpy as np # noqa: E402
+
+import dask_image.ndmeasure # noqa: E402
@pytest.fixture
=====================================
tests/test_dask_image/test_ndmeasure/test_find_objects_no_dataframe.py
=====================================
@@ -0,0 +1,37 @@
+"""
+Test that ``find_objects`` raises a helpful ``ImportError`` when the
+optional ``dask[dataframe]`` / ``pandas`` dependencies are not installed.
+
+This is skipped if both dependencies are installed.
+
+"""
+import dask.array as da
+import pytest
+
+import dask_image.ndmeasure
+
+
+try:
+ import pandas # noqa: F401
+ import dask.dataframe # noqa: F401
+ dataframe_available = True
+except ImportError:
+ dataframe_available = False
+
+
+ at pytest.mark.skipif(
+ dataframe_available,
+ reason="dataframe dependencies are installed; "
+ "ImportError path only triggers without them",
+)
+def test_find_objects_raises_import_error_without_pandas():
+ label_image = da.zeros((3, 3), dtype=int, chunks=(3, 3))
+ with pytest.raises(
+ ImportError,
+ match=(
+ r"dask_image\.ndmeasure\.find_objects requires the optional "
+ r"dependencies `dask\[dataframe\]` and `pandas`\. "
+ r"Install them with `pip install dask-image\[dataframe\]`\."
+ ),
+ ):
+ dask_image.ndmeasure.find_objects(label_image)
View it on GitLab: https://salsa.debian.org/debian-gis-team/dask-image/-/compare/d75e733009d042a6414b8a3695eb82e66fcfed77...f8e8e9c60ce5802f38443efb05b55c6856f8ad3f
--
View it on GitLab: https://salsa.debian.org/debian-gis-team/dask-image/-/compare/d75e733009d042a6414b8a3695eb82e66fcfed77...f8e8e9c60ce5802f38443efb05b55c6856f8ad3f
You're receiving this email because of your account on salsa.debian.org. Manage all notifications: https://salsa.debian.org/-/profile/notifications | Help: https://salsa.debian.org/help
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-grass-devel/attachments/20260527/737e8915/attachment-0001.htm>
More information about the Pkg-grass-devel
mailing list