Skip to content

fix(fit): start gamma/lambda from the prior run - #398

Open
mhovd wants to merge 1 commit into
claude/pmetrics-pmcore-pharmsol-fixes-qdno6d-prior-resultfrom
claude/pmetrics-pmcore-pharmsol-fixes-qdno6d-prior-gamma
Open

mhovd wants to merge 1 commit into
claude/pmetrics-pmcore-pharmsol-fixes-qdno6d-prior-resultfrom
claude/pmetrics-pmcore-pharmsol-fixes-qdno6d-prior-gamma

Conversation

@mhovd

@mhovd mhovd commented Oct 11, 2026

Copy link
Copy Markdown
Collaborator

This PR is stacked on the PM_result prior fix (the prior-result branch). Retarget it to main after that one merges.

Bug. With prior = <run number> or a PM_result, γ/λ restarted at the model's initial value. A continued run then started at a much worse −2LL (231 vs −50 at the end of the prior run), and cycles = 0 posteriors used the wrong error model.

Fix. Error models that are not fixed start from the prior run's final γ/λ. The value comes from outputs/cycles.csv for a run number, or from $cycle$data$gamlam for a PM_result. Fixed error models are unchanged.

Tests. Mocked fits cover the run-number and PM_result cases.

🤖 Generated with Claude Code

https://claude.ai/code/session_01GTyUgJEd5uCEmv9qYrv8dC


Generated by Claude Code

With prior = <run number> or a PM_result, estimated gamma/lambda restarted
at the model's initial value, so continued runs and cycles = 0 posteriors
used the wrong error model. Fixed error models are left unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GTyUgJEd5uCEmv9qYrv8dC

This branch has not been deployed

No deployments
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.

2 participants