Repository navigation
WP 13.4: the preview reads the lit part of an obstructed frame, and a defocused frame is not called obstructed (#1287) - #1351
Conversation
…rame, and a defocused or faintly graded frame is not called obstructed (#1287) _publish_preview searched the whole frame for the published star count, the HFR, the marks, the defocus screen and the Bahtinov centre. On a frame partly behind a foreground those now read the lit side's stars as the block-by-block detector finds them (Obstruction.lit_stars). A frame of one population keeps its whole-frame list exactly, held by a golden taken on the tree before the change. The obstruction is searched once a frame: cloud_score takes the one its caller found. find_obstruction gains two conditions. The drop from the sky to the dark region must reach one pixel sigma (OBSTRUCTION_MIN_DROP_SIGMA), and the lit side must still hold three stars when detected block by block. Nine real fixtures that read OBSTRUCTED no longer do: eight defocused focus-sweep crops and one in-focus NGC 604 sub with a 0.2 sigma gradient. Every other real fixture keeps its class, and real fields behind a composited foreground still read obstructed. Known limit, stated in the constant's comment and pinned by two tests: a foreground is not found where the sky sits within a pixel sigma of the dark floor, which is the case for narrowband subs. Such a frame reads as cloud or unknown, as it did before #1145. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01K7CHb44VFtZLGUDLF4us2p
…nce in process; the recorded golden is removed (#1287) The golden payload recorded on a Windows machine failed on the Linux runner for donutfield_L60: the aggregates agreed (hfr 4.01, 43 stars) but one blended donut blob was split into three detections with different centroids, so three star_list entries and some tilt zones differed. A recording compared to four decimals across platforms pins the machine, not the code. The test now asserts the claim directly, in one process: a frame with no obstruction hands every analysis the whole-frame star list (spies on the four analyses as hub.py calls them), and every figure it publishes equals what the same functions return for that list. The payload's key set is a literal. Counts that sat at a threshold on this machine were given margins: three class-table entries accept STARS or UNKNOWN (never OBSTRUCTED), planted-star counts take a window that still excludes the whole-frame count, and two composites moved to edges with a wide lit count. Tests only; no product code changes. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01K7CHb44VFtZLGUDLF4us2p
|
The second commit on this branch (head a0497ad) changes the tests only. The first CI run failed on this pull request's own test The recorded file is removed. The test now proves the claim in one process: a frame with no obstruction hands each of the four analyses the whole-frame star list (spies at the calls Counts that sat on a threshold on the recording machine were given margins, for the same reason: three class-table entries accept STARS or UNKNOWN and never OBSTRUCTED; planted-star counts take a window of 76 to 82 that still excludes the whole-frame count of 67; two composites moved to edges where the lit count is 7 or more against the threshold of 3. |
Plan 3, wave 13, WP 13.4. Closes #1287.
What changed
Hub._publish_previewsearched the whole frame for the published star count, the HFR, the star marks, the defocus screen and the Bahtinov centre. Whenfind_obstructionfinds a foreground, those now read the lit side's stars as the block-by-block detector finds them. A frame of one population publishes exactly what it did, held by a golden taken before the change.find_obstructiongains two conditions: the drop from the sky to the dark region must reach one pixel sigma, and the lit side must still hold three stars when detected block by block.cloud_scoretakes the one its caller found, and reads its lit stars instead of detecting again.Evidence
Every real fixture was rendered and looked at before any figure was read.
_publish_previewon a 26 MP frame, median of 5 on a busy machine: 5.6 s unobstructed and 4.9 s obstructed, at or under main within the noise.cloud_scoreremoved, the defocus screen given whole-frame stars. Each fails a test.Known limit
A foreground is not found where the sky sits within a pixel sigma of the dark floor. From the real fixtures, the most an opaque foreground could drop the frame is 5.3 sigma and up on 60 s broadband subs, 1.8 to 3.3 on 4 s focus frames, and 0.2 to 1.8 on the 300 s Ha sub (the pedestal at that gain is not recorded). So a tree on a narrowband sub is probably missed and reads as cloud or unknown, as it did before #1145. The limit is in the constant's comment and pinned by two tests named as limits. No real obstructed frame is in the repository; recording some is #1349.
Follow-ups filed
🤖 Generated with Claude Code
https://claude.ai/code/session_01K7CHb44VFtZLGUDLF4us2p