Let a 32-pixel face count, and move the blur floor with it

64 source pixels was too strict: it threw away 70% of everything the detector
finds, and plenty of what it took were faces a person could name.

Lowering it is not a one-line change, because the two floors are coupled. A face
under 112 pixels is *upsampled* to reach the embedder and upsampling invents no
edges, so a small face scores low on sharpness however crisp the original was.
Re-measured over the reference library with `face_index --quality`:

    min crop   min sharp   size cut   blur cut       kept
          32       0.000        44%         0%        56%
          32       0.002        44%         3%        53%
          32       0.005        44%         8%        48%
          32       0.010        44%        16%        40%
          32       0.020        44%        27%        30%
          64       0.020        70%         7%        23%

Holding the blur floor at 0.020 while dropping the size floor to 32 would have
rejected a further 27% — for being small rather than for being blurred — and
kept only 30%, barely more than the 23% the strict pair kept. Most of the point
of lowering the size floor would have gone straight back out through the other
gate.

0.005 removes 8% of what the size floor leaves, which is the same job 0.020 was
doing at 64 (7%): the large-but-soft face this gate exists for. Together they
now keep 48% of what the detector finds, against 23% before.

The box pre-filter follows down to 24, staying below what the real floor accepts
so it cannot reject a face that would have cleared 32.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-08-28 08:30:09 +02:00
co-authored by Claude Opus 5
parent c7cdf7e5f0
commit 1d4c3348af
2 changed files with 32 additions and 11 deletions
+6 -5
View File
@@ -464,13 +464,14 @@ fn report_quality(
println!("{}", "-".repeat(52));
for (min_px, min_sharp) in [
(0.0_f32, 0.0_f32),
(64.0, 0.0),
(0.0, 0.010),
(64.0, 0.005),
(32.0, 0.0),
(32.0, 0.002),
(32.0, 0.005),
(32.0, 0.010),
(32.0, 0.020),
(48.0, 0.005),
(64.0, 0.010),
(64.0, 0.020),
(80.0, 0.010),
(96.0, 0.010),
] {
let by_size = found.iter().filter(|f| f.0 < min_px).count();
let by_blur = found