Skip to content

Fix candidate gating on PSPL fit quality - #2

Draft
NunotaKansuke wants to merge 6 commits into
rges-pit:mainfrom
NunotaKansuke:main
Draft

Fix candidate gating on PSPL fit quality#2
NunotaKansuke wants to merge 6 commits into
rges-pit:mainfrom
NunotaKansuke:main

Conversation

@NunotaKansuke

Copy link
Copy Markdown

Summary

  • Gate the final is_candidate flag on the PSPL fit-quality decision.
  • Add a regression test for a detected bump with an unacceptable PSPL fit.

Root cause

fit_pspl_candidate already returns is_candidate=False when the reduced PSPL chi-square exceeds good_pspl_chi2, but the pipeline ignored that value and derived the final flag only from the bump scan and vetoes. This allowed poor PSPL fits to be reported as candidates.

Validation

  • pytest -q — 16 passed
  • ruff check src tests — passed
  • The change was merged into NunotaKansuke/aethra main before opening this PR.

The bug was reproduced on a Roman simulation event where chi2_red_pspl=2.979 exceeded the default threshold of 2.5, while the pipeline previously returned is_candidate=True.

KatieVandorou and others added 6 commits June 22, 2026 12:31
Removed known quirks section from README.
Added a description for the automated event tracker.
Removed outdated command line instructions and testing section from README.
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