Skip to content

sparseframe: add optional smoothing to sparse_localmax - #622

Merged
jonwright merged 2 commits into
FABLE-3DXRD:masterfrom
jonwright:issue159
Sep 9, 2026
Merged

sparseframe: add optional smoothing to sparse_localmax#622
jonwright merged 2 commits into
FABLE-3DXRD:masterfrom
jonwright:issue159

Conversation

@jonwright

Copy link
Copy Markdown
Member

Fixes #159. SparseScan.lmlabel already smooths via cImageD11.sparse_smooth before localmax labelling, but the frame-level equivalent sparse_localmax() had no way to do the same. Adds a smooth=False kwarg (default keeps existing behaviour/output unchanged) that reuses the existing sparse_smooth helper, same as SparseScan.lmlabel already does.

Fixes FABLE-3DXRD#159. SparseScan.lmlabel already smooths via cImageD11.sparse_smooth
before localmax labelling, but the frame-level equivalent sparse_localmax()
had no way to do the same. Adds a smooth=False kwarg (default keeps
existing behaviour/output unchanged) that reuses the existing sparse_smooth
helper, same as SparseScan.lmlabel already does.
@jonwright

Copy link
Copy Markdown
Member Author

I think there is zero test coverage for this. Lets add a test please

Addresses review feedback on FABLE-3DXRD#622 (no test coverage for the new
smooth= parameter). Checks that sparse_localmax(frame, smooth=...)
reproduces the per-frame labelling that SparseScan.lmlabel(smooth=...)
already computes internally, for both smooth=True and smooth=False,
using the silicon sparse test data in test/pixelmapper/.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@jonwright
jonwright merged commit 4102e1d into FABLE-3DXRD:master Sep 9, 2026
8 checks passed
@jonwright
jonwright deleted the issue159 branch September 9, 2026 12:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

SparseFrame vs SparseScan and lmlabel

1 participant