v0.17.3 - Coincidence Detection Fix (2026-03-05)¶
What Changed?¶
This release fixes the coincidence detection logic in check_coincidence.py.
The find_coincidences() function was refactored to pre-rename all columns with _a/_b suffixes before calling pd.merge_asof, making the merge
simpler and more robust.
No library API changes were made.
What's New¶
Main Feature: Refactored find_coincidences() in check_coincidence.py¶
What it does:
The previous implementation added a hidden helper column (__<on>_b) to preserve the right detector's timestamp before the merge.
After the merge, the on column held the left detector's value without a suffix, and build_output_record() had to special-case it.
The new implementation renames all columns with _a/_b suffixes before calling pd.merge_asof using a temporary merge_key column as the join key.
This eliminates the suffix conflict and makes build_output_record() uniform.
How to use it:
No change to the CLI interface. The output format is identical.
uv run check_coincidence.py ./detA ./detB --window 1s --hit-types 7
What's Different from the Last Version?¶
🔧 Changed¶
check_coincidence.pyfind_coincidences(): Pre-rename all columns with_a/_bsuffixes beforepd.merge_asof; usemerge_keyas join columncheck_coincidence.pyfind_coincidences(): Restore integer dtypes for_bcolumns promoted to float by NaN rows beforedropna()check_coincidence.pybuild_output_record(): Removedonparameter; all columns are now accessed uniformly via_a/_bsuffixes
🐛 Fixed¶
check_coincidence.py: Docstring--windowdefault corrected from"1ms"to"1s"
Installation¶
Quick Start¶
# Get the release
git checkout 0.17.3
# Setup
uv sync
# Run CLI
uv run kazunoko --help
Is It Safe to Upgrade?¶
Backward Compatible: Yes
- No changes to the library API (
kazunokopackage) - No changes to CLI options or defaults
check_coincidence.pyoutput format is identical to the previous version
Tests Passed¶
- ✅ Builds without errors
- ✅
uvx ruff check src/passes - ✅ Pre-commit hooks pass
Release Details¶
- Date: 2026-03-05
- Version: v0.17.3
- Files Changed: 1
- Commits:
3bd0033,6f9d594
Next Steps¶
- Add test coverage for
check_coincidence.pymerge logic