Repository navigation
test: pin CTI log-likelihood values for dataset_1d and imaging_ci - #25
Merged
Merged
Conversation
Add scripts/{dataset_1d,imaging_ci}/likelihood/pins.py. Each simulates a
noise-free dataset and pins analysis.log_likelihood_function at the truth
model and at an offset model (density x1.2, release timescale x0.8), at
rtol=1e-8: 1 and 2 trap species (1D); parallel, serial and parallel+serial
(2D). Both scripts are added to smoke_tests.txt, and the re-pin rule is
documented in AGENTS.md.
Closes #24 (cti-upkeep phase 0b).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Summary
autocti_workspace_test had no pinned log-likelihood values, so a CTI library PR, or the arcticpy upgrade planned in
cti-upkeepphase 2, could change likelihood values without any test catching it. This adds NumPy-path pins in the same style as thejax_likelihood/pins in the lens and galaxy test workspaces. Closes #24 (cti-upkeepphase 0b).Each script simulates a noise-free dataset (
read_noise=None, no Poisson noise, the simulator's constant noise map) and pinsanalysis.log_likelihood_functionatrtol=1e-8for two models:Provenance:
# pinned 2026-11-04: autocti main@2a91ff5d, arcticpy 2.6.Scripts Changed
scripts/dataset_1d/likelihood/pins.py: new. Covers 1 and 2 trap species at two injection levels; about 2.4 s.scripts/imaging_ci/likelihood/pins.py: new. Covers parallel-only, serial-only and parallel+serial clocking; about 2.4 s.smoke_tests.txt: adds both scripts.AGENTS.md: documents the re-pin rule. A pin moves only with a dated comment naming the PR and the cause; the arcticpy version is part of each pin's provenance; tolerances are never loosened.model_fit.pyandlegacy/are unchanged. There are no library changes.Test Plan
python .github/scripts/run_smoke.py: all 5 scripts pass locally (Python 3.13, arcticpy 2.6).AssertionError.AssertionError.Smoke Testsgreen in CI.Generated by the PyAutoLabs agent workflow.
🤖 Generated with Claude Code