firecrown icon indicating copy to clipboard operation
firecrown copied to clipboard

First version of BinRule class system for bin combinations.

Open vitenti opened this issue 3 months ago • 1 comments

Description

This PR introduces a framework for bin pair selection in two-point correlation functions through a hierarchy of BinRule classes. The design allows users to define, combine, and reuse rules for filtering InferredGalaxyZDist bins and their measurements before constructing TwoPointXY objects. This addresses the need to systematically and safely generate physically meaningful combinations, beyond simple “all compatible pairs”. There are example in tests/metadata/test_metadata_two_point_sacc.py

Type of change

Please delete the bullet items below that do not apply to this pull request.

  • New feature (non-breaking change which adds functionality)

Checklist:

The following checklist will make sure that you are following the code style and guidelines of the project as described in the contributing page.

  • [ ] I have run bash pre-commit-check and fixed any issues
  • [ ] I have added tests that prove my fix is effective or that my feature works
  • [ ] I have made corresponding changes to the documentation
  • [ ] I have 100% test coverage for my changes (please check this after the CI system has verified the coverage)

vitenti avatar Sep 26 '25 22:09 vitenti

Codecov Report

:white_check_mark: All modified and coverable lines are covered by tests. :white_check_mark: Project coverage is 100.0%. Comparing base (f96025d) to head (6a205a1).

Additional details and impacted files
@@           Coverage Diff            @@
##           master     #552    +/-   ##
========================================
  Coverage   100.0%   100.0%            
========================================
  Files          67       67            
  Lines        6270     6397   +127     
  Branches      756      767    +11     
========================================
+ Hits         6270     6397   +127     
Files with missing lines Coverage Δ
firecrown/metadata_functions/__init__.py 100.0% <ø> (ø)
firecrown/metadata_functions/_combination_utils.py 100.0% <100.0%> (ø)
firecrown/metadata_functions/_matching.py 100.0% <100.0%> (ø)
firecrown/metadata_types.py 100.0% <100.0%> (ø)
:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

codecov[bot] avatar Sep 28 '25 13:09 codecov[bot]