Skip to content

fix(cleanup): pixel-dust threshold in pixels#89

Merged
dustenhubbard merged 1 commit into
mainfrom
fix/pixel-dust-pixels
Jul 23, 2026
Merged

fix(cleanup): pixel-dust threshold in pixels#89
dustenhubbard merged 1 commit into
mainfrom
fix/pixel-dust-pixels

Conversation

@dustenhubbard

Copy link
Copy Markdown
Owner

Maintainer decision: the pixel-dust threshold reads in pixels (px^2), matching the mental model.

  • Per-section conversion: threshold_um2 = threshold_px * section.mag^2, so one pixel threshold means 'smaller than N pixels on ITS image' across mixed-mag sections.
  • Default 10 px^2 (a <=3x3 speck). Notably the old 0.01 um^2 default was ~1550 px^2 at typical EM mag, far too large for dust.
  • Review list shows both Area (px^2) (primary, matches the threshold) and Area (um^2) (physical equivalent per row, since mags differ by section).
  • New test: same physical speck on two sections with 2x mag difference is flagged only on the finer-mag section.

Suite: 1250 passed, 5 pre-existing xfails.

The data clean-up "Remove pixel-dust traces" tool now takes its size
threshold in pixels (px^2) instead of physical area (um^2), matching the
"pixel dust" mental model of "smaller than N pixels on its own image".

findPixelDustTraces derives the physical cutoff per section from that
section's magnification (threshold_px * section.mag**2), so one pixel
threshold adapts to sections of different scale. Each candidate carries
both its pixel area and physical area.

The review dialog shows an "Area (px^2)" column (same units as the
threshold) alongside "Area (um^2)" for the physical equivalent. The
dialog input defaults to 10 px^2 (a stray speck of a few pixels).

Tests updated to px^2 threshold semantics, including a mixed-magnification
case proving the cutoff adapts per section. WHATS_NEW updated.
@dustenhubbard
dustenhubbard enabled auto-merge (squash) July 23, 2026 20:25
@dustenhubbard
dustenhubbard merged commit 93c0620 into main Jul 23, 2026
1 check passed
@dustenhubbard
dustenhubbard deleted the fix/pixel-dust-pixels branch July 23, 2026 20: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.

1 participant