Skip to content

Add dask+cupy test coverage for focal.hotspots()#2757

Merged
brendancol merged 2 commits into
mainfrom
deep-sweep-test-coverage-focal-2026-05-29
Jun 1, 2026
Merged

Add dask+cupy test coverage for focal.hotspots()#2757
brendancol merged 2 commits into
mainfrom
deep-sweep-test-coverage-focal-2026-05-29

Conversation

@brendancol
Copy link
Copy Markdown
Contributor

Adds a dask+cupy test for focal.hotspots().

Since this PR was first opened, #2739 merged a test_hotspots_dask_cupy that compares the dask+cupy result against the cupy reference and checks the output stays a cupy-backed dask array. This adds test_hotspots_dask_cupy_matches_numpy, which compares the dask+cupy result against the numpy reference on the chunk interior (same approach as test_apply_dask_cupy and test_focal_stats_dask_cupy) — so the GPU dask path gets checked against the CPU result, not just against cupy. Passes on a CUDA host and routes through _hotspots_dask_cupy. Test-only, no source changes.

Closes #2732. Replaces #2738: that PR's head detached when its branch was deleted and recreated, and GitHub wouldn't re-point it, so this is the same branch under a fresh PR.

The _hotspots_dask_cupy dispatch path was registered but had no test,
unlike mean/apply/focal_stats which each have a dask+cupy test. Adds
test_hotspots_dask_cupy comparing the dask+cupy result against the numpy
reference on the chunk interior. Verified on a CUDA host: passes and
routes through _hotspots_dask_cupy.

Closes #2732
…age-focal-2026-05-29

# Conflicts:
#	xrspatial/tests/test_focal.py
@github-actions github-actions Bot added the performance PR touches performance-sensitive code label Jun 1, 2026
@brendancol brendancol merged commit 5e6b131 into main Jun 1, 2026
8 of 9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

performance PR touches performance-sensitive code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

hotspots() dask+cupy backend has no test coverage

1 participant