Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Properly transform between camera and telescope frame in muon fitter #2464

Merged
merged 1 commit into from Dec 1, 2023

Conversation

maxnoe
Copy link
Member

@maxnoe maxnoe commented Nov 17, 2023

The muon code did some strange things to transform pixel coordinates from camera to telescope frame, probably from code before camera geometries could be transformed as a whole.

Copy link

codecov bot commented Nov 20, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (c05b493) 92.47% compared to head (31e1c1e) 92.46%.
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2464      +/-   ##
==========================================
- Coverage   92.47%   92.46%   -0.01%     
==========================================
  Files         234      234              
  Lines       19816    19811       -5     
==========================================
- Hits        18325    18319       -6     
- Misses       1491     1492       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@RuneDominik RuneDominik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Given that this fixes #2467 and with that the effective vs. equivalent focal-length discrepancy with, according to the issue, up to 25% differences in the muon efficiencies, I'd argue that this needs a changelog entry.

ctapipe/image/muon/tests/test_intensity_fit.py Outdated Show resolved Hide resolved
@maxnoe
Copy link
Member Author

maxnoe commented Nov 21, 2023

@RuneDominik Yes, good point! I oversaw this change before.

@maxnoe maxnoe requested a review from Tobychev November 23, 2023 15:28
@@ -309,7 +308,8 @@ def image_prediction_no_units(

def build_negative_log_likelihood(
image,
telescope_description,
optics,
geometry_tel_frame,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So here you change the function signature, but I can't see any test being modified to match this new signature. Did I simply miss it or is there intentionally no test of build_negative_log_likelihood?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The test is through the __call__ method of the class, there is no direct test of this method.

@kosack kosack merged commit 938da69 into main Dec 1, 2023
13 of 14 checks passed
@kosack kosack deleted the fix_muon_test branch December 1, 2023 08:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Discrepancy in coordinate transformation in the MuonProcessor
4 participants