Description of the issue
Problem
L2B correctly assigns events to these circular spin-phase ranges:
Range Correct center
━━━━━━━━━━ ━━━━━━━━━━━━━━━━
315–45° 0°
────────── ────────────────
45–135° 90°
────────── ────────────────
135–225° 180°
────────── ────────────────
225–315° 270°
However, the output spin_phase coordinate contains:
[45, 135, 225, 315]
These values are boundaries of the physical bins, not their centers. Each histogram count is therefore associated with a misleading DEPEND_1 coordinate.
Recommended changes
-
Retain the existing circular binning algorithm.
-
Publish the spin-phase coordinate as:
[0, 90, 180, 270]
-
Update metadata to explicitly describe the bin ranges and centers.
-
Add tests that verify both event assignment and output coordinates.
Steps to reproduce the issue
No response
Expected vs Actual behavior
No response
Code Snippet (If applicable)
Additional notes, affected areas, and suggested fixes
No response
Description of the issue
Problem
L2B correctly assigns events to these circular spin-phase ranges:
Range Correct center
━━━━━━━━━━ ━━━━━━━━━━━━━━━━
315–45° 0°
────────── ────────────────
45–135° 90°
────────── ────────────────
135–225° 180°
────────── ────────────────
225–315° 270°
However, the output spin_phase coordinate contains:
[45, 135, 225, 315]
These values are boundaries of the physical bins, not their centers. Each histogram count is therefore associated with a misleading DEPEND_1 coordinate.
Recommended changes
Retain the existing circular binning algorithm.
Publish the spin-phase coordinate as:
[0, 90, 180, 270]
Update metadata to explicitly describe the bin ranges and centers.
Add tests that verify both event assignment and output coordinates.
Steps to reproduce the issue
No response
Expected vs Actual behavior
No response
Code Snippet (If applicable)
CodeAdditional notes, affected areas, and suggested fixes
No response