-
Notifications
You must be signed in to change notification settings - Fork 623
[PWGCF] Martijn laarhoven patch 3 #14416
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
Changes from all commits
58b1428
35066df
3a07128
95170ad
30dd963
0e130d2
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -111,6 +111,8 @@ | |||||
| O2_DEFINE_CONFIGURABLE(cfgRejectFT0AOutside, bool, false, "Rejection of outer ring channels of the FT0A detector") | ||||||
| O2_DEFINE_CONFIGURABLE(cfgRejectFT0CInside, bool, false, "Rejection of inner ring channels of the FT0C detector") | ||||||
| O2_DEFINE_CONFIGURABLE(cfgRejectFT0COutside, bool, false, "Rejection of outer ring channels of the FT0C detector") | ||||||
| O2_DEFINE_CONFIGURABLE(cfgRemapFT0ADeadChannels, bool, false, "If true, remap FT0A channels 60-63 to amplitudes from 92-95 respectively") | ||||||
| O2_DEFINE_CONFIGURABLE(cfgRemapFT0CDeadChannels, bool, false, "If true, remap FT0C channels 177->145, 176->144, 178->146, 179->147, 139->115") | ||||||
|
||||||
| O2_DEFINE_CONFIGURABLE(cfgRemapFT0CDeadChannels, bool, false, "If true, remap FT0C channels 177->145, 176->144, 178->146, 179->147, 139->115") | |
| O2_DEFINE_CONFIGURABLE(cfgRemapFT0CDeadChannels, bool, false, "If true, remap FT0C channels 115->139, 144->176, 145->177, 146->178, 147->179") |
Copilot
AI
Jan 7, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The variable 'ampl' is modified at line 668 by applying gain correction before filling the dead channel histogram. This causes the subsequent fills for the original channel at lines 679-681 to use the already-corrected amplitude instead of the raw amplitude. As a result, line 679 fills FT0Amp with a gain-corrected value when it should receive the raw amplitude, and line 680 applies gain correction again, leading to double correction in the FT0AmpCorrect histogram. Consider using a separate variable for the corrected amplitude when filling the dead channel histograms to avoid modifying the 'ampl' variable that's used later.
Copilot
AI
Jan 7, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The variable 'ampl' is modified at line 673 by applying gain correction before filling the dead channel histogram. This causes the subsequent fills for the original channel at lines 679-681 to use the already-corrected amplitude instead of the raw amplitude. As a result, line 679 fills FT0Amp with a gain-corrected value when it should receive the raw amplitude, and line 680 applies gain correction again, leading to double correction in the FT0AmpCorrect histogram. Consider using a separate variable for the corrected amplitude when filling the dead channel histograms to avoid modifying the 'ampl' variable that's used later.
Copilot
AI
Jan 7, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The gain correction is applied inside the remapping block at line 689 before filling the FT0AmpCorrect histogram for the dead channel, but the same amplitude will be divided by cstFT0RelGain[iCh] again at line 696 for the original channel. This creates an inconsistency in how amplitudes are corrected. The gain correction at line 689 should be removed to maintain consistency with the rest of the function's logic where gain correction is applied once after all channel processing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The configuration description states "remap FT0A channels 60-63 to amplitudes from 92-95 respectively", but the implementation does the opposite. The code at lines 686-687 maps channels 92-95 to channels 60-63 (by subtracting 32). The description should be corrected to match the implementation: "remap FT0A channels 92-95 to amplitudes from 60-63 respectively" or the implementation should be adjusted to match the description.