Skip to content

Fix off-by-one in 1-indexed loops in docking/membrane/misc (split 4/4 of #707) - #733

Merged
lyskov merged 1 commit into
RosettaCommons:mainfrom
lyskov-ai:fix/off-by-one-docking-membrane-misc
Jul 23, 2026
Merged

Fix off-by-one in 1-indexed loops in docking/membrane/misc (split 4/4 of #707)#733
lyskov merged 1 commit into
RosettaCommons:mainfrom
lyskov-ai:fix/off-by-one-docking-membrane-misc

Conversation

@lyskov-ai

Copy link
Copy Markdown
Contributor

Summary

One of four PRs splitting #707 (originally a single 35-file off-by-one batch) into coherent, per-subsystem pieces, so each can be reviewed and its regression-test impact assessed independently. #707 is being closed in favor of these four. The split is deliberate — the individual diffs are below the usual bundling threshold — because the changes are behavior-affecting and the maintainer asked to isolate regression-test impact per subsystem.

This PR: docking / membrane / antibody / match / loops / misc movers (11 files).

Off-by-one in 1-indexed loops (<<=)

The last element was silently skipped:

  • docking/DockingEnsemblePrepackProtocol.cc ×2 — chain identity validation
  • docking/metrics.cc ×2 — cutpoint scan in calc_Fnonnat
  • membrane/MPLipidAccessibility.cc ×2 — slice iteration
  • antibody/residue_selector/CDRResidueSelector.cc
  • match/output/UpstreamDownstreamCollisionFilter.cc
  • loops/util.cc ×3 — non-protein-chunk and per-loop accounting
  • cartesian/md.cc ×2 — per-atom state save / derivative check
  • cutoutdomain/CutOutDomain.ccfind_nearest_res
  • enzdes/EnzRepackMinimize.cc — movable-residue collection for backrub
  • moves/PyMOLMover.ccrelevant_residues mask init (last entry left default false despite the intent of "all relevant")

Comment-only

  • membrane/util.cc — documents why a nearby loop intentionally stays < chains.size() (the trailing MEM virtual chain must be excluded). No behavior change.

Regression tests

This PR carries most of #707's results-affecting changes: enzdes and inverse_rotamer_remodel (enzdes/EnzRepackMinimize.cc), ligand_dock_cholesterol (docking/), mp_f19_relax and mpil_load_implicit_lipids (membrane/MPLipidAccessibility.cc). These output changes are intentional but results-affecting and warrant scientific sign-off before merge.

…tch / loops / misc)

Split from RosettaCommons#707. Off-by-one in 1-indexed loops (< -> <=), last element was
silently skipped:
- docking/DockingEnsemblePrepackProtocol.cc x2  (chain identity validation)
- docking/metrics.cc x2  (cutpoint scan in Fnonnat)
- membrane/MPLipidAccessibility.cc x2  (slice iteration)
- antibody/residue_selector/CDRResidueSelector.cc
- match/output/UpstreamDownstreamCollisionFilter.cc
- loops/util.cc x3  (non-protein-chunk and per-loop accounting)
- cartesian/md.cc x2  (per-atom state save / derivative check)
- cutoutdomain/CutOutDomain.cc  (find_nearest_res)
- enzdes/EnzRepackMinimize.cc  (movable-residue collection for backrub)
- moves/PyMOLMover.cc  (relevant_residues mask init -- last entry left default
  false despite the intent of 'all relevant')

membrane/util.cc: comment-only. This documents WHY a nearby loop
intentionally stays '< chains.size()' (the trailing MEM virtual chain must be
excluded); no behavior change.

Note: this batch changes the output of several regression tests -- enzdes,
inverse_rotamer_remodel, ligand_dock_cholesterol, mp_f19_relax,
mpil_load_implicit_lipids. The changes are intentional but results-affecting
and warrant scientific sign-off before merge.
@lyskov
lyskov merged commit bc091c6 into RosettaCommons:main Jul 23, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants