docs: record that edge-zeroing is deliberately scoped to the positive-only solver - #473
Merged
Merged
Conversation
…-only solver
use_edge_zeroed_pixels is consulted only when use_positive_only_solver is True.
The positive-negative branch solves the full system regardless of its value, so
the two are not independent switches -- but config/general.yaml lists them as
two adjacent booleans with no hint of the dependency, and the nesting is only
visible by reading the control flow in AbstractInversion.reconstruction.
That has already been mistaken for a bug ("a setting silently ignored") by
someone reading the branch without the context, twice deferred as work needing
sign-off, and written up in three places as a defect before the author
confirmed the scoping is deliberate. Documented in the three places a reader
can arrive at it:
- config/general.yaml -- the line itself now says the scoping exists and is
intended, since this is the file that reads as two independent switches.
- Settings.use_edge_zeroed_pixels -- gains a docstring stating the dependency
and why it is called out.
- AbstractInversion.reconstruction -- a comment at the nesting site itself,
saying explicitly not to "fix" it by hoisting the check out of the branch.
Documentation only; no behaviour change. test_autoarray/inversion: 346 passed.
Not covered here: every workspace ships its own copy of config/general.yaml
with the uncommented version of this line (confirmed in autolens_workspace),
and the workspace config is the one users actually read. Propagating the
comment there is a separate change across the workspace repos, recorded in
PyAutoMind.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0133X4XhMV91SFjzV2mK4Ejh
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Documentation only — no behaviour change, +16 lines across three files.
Why
use_edge_zeroed_pixelsis consulted only whenuse_positive_only_solverisTrue. The positive-negative branch solves the full system regardless of its value.But
config/general.yamllists the two as adjacent booleans with no hint of the dependency:They read as independent switches. The nesting is only visible by reading the control flow in
AbstractInversion.reconstruction.That gap has real cost: it was mistaken for a bug — "a setting silently ignored" — twice deferred as work needing sign-off before touching the reconstruction path, and written up in three PyAutoMind documents as an open defect, before the author confirmed the scoping is deliberate. This PR closes the gap rather than leaving the next reader to repeat it.
Where
The three places a reader can arrive at this:
config/general.yamlSettings.use_edge_zeroed_pixelsAbstractInversion.reconstructionThe third is the one that matters most — it sits exactly where the wrong inference gets made.
Not covered here
Every workspace ships its own copy of
config/general.yamlwith the uncommented version of this line — confirmed inautolens_workspace/config/general.yaml:19— and the workspace config is the one users actually read. Propagating the comment is a separate change across the workspace repos, recorded in PyAutoMind rather than done silently here.Tests
test_autoarray/inversion/— 346 passed. No code changed.🤖 Generated with Claude Code
https://claude.ai/code/session_0133X4XhMV91SFjzV2mK4Ejh
Generated by Claude Code