Skip to content

Fix adaptive drift error - #261

Merged
lohedges merged 3 commits into
develfrom
fix_adaptive_drift_error
Oct 23, 2026
Merged

lohedges merged 3 commits into
develfrom
fix_adaptive_drift_error

Conversation

@lohedges

Copy link
Copy Markdown
Contributor

Fixes the calibration of the adaptive replica exchange convergence checks.

Offline replays of three 5 ns GSK3B ABFE bound legs showed that the checks flag converged window pairs far more often than intended:

  • The two-halves drift check estimated its error linearly, ignoring how strongly the exponential average depends on a few extreme samples. On block-shuffled data, which has no drift, it fired 25–33% of the time instead of ~5%, and up to 100% for pairs with wide energy distributions. It now uses a jackknife over contiguous batches, which gives 5–9%.
  • The forward/reverse check (|EXP(fwd) + EXP(rev)| > 1 kT) fires on perfectly converged data once the spread of the energy differences exceeds ~2 kT, because of the bias of the exponential average. It is now only applied when both spreads are at most 2 kT. Wider pairs are still covered by the variance ranking and the swap acceptance check.

In the replays, about 30% fewer pairs are flagged per ranking, so more windows can go cold. The test helper's hard pair is now consistent, so the ranking tests no longer get their hot windows from a flag.

@lohedges

Copy link
Copy Markdown
Contributor Author

CI failures are because of this issue. Should hopefully be sorted soon.

@lohedges
lohedges deployed to somd2-build October 23, 2026 06:06 — with GitHub Actions Active
@lohedges
lohedges deployed to somd2-build October 23, 2026 06:06 — with GitHub Actions Active
@lohedges
lohedges merged commit 09e0ef1 into devel Oct 23, 2026
10 of 16 checks passed
@lohedges
lohedges deleted the fix_adaptive_drift_error branch October 23, 2026 14:51

This branch was successfully deployed

1 active deployment
somd2-build — 06bf0269 Deployed Oct 23, 2026 by lohedges via build (3.12, linux) #133
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