Skip to content

[EMCAL-688] Improve ClusterFactory evalDispersion function and fix bug in buildCluster - #15788

Draft
mhemmer-cern wants to merge 1 commit into
AliceO2Group:devfrom
mhemmer-cern:EMCAL-688
Draft

mhemmer-cern wants to merge 1 commit into
AliceO2Group:devfrom
mhemmer-cern:EMCAL-688

Conversation

@mhemmer-cern

@mhemmer-cern mhemmer-cern commented Sep 11, 2026

Copy link
Copy Markdown
Contributor
  • buildCluster uses the local index of cells in eta and phi for calcualting M02, M20 and dispersion. The member mSharedCluster would need to be set to true, to apply a correction for the local index when switching from one SM to antoher for cluster spanning two SM. This commit fixes this issue by setting mSharedCluster in buildCluster.
  • Remove TMath calls with std function calls
  • Fix wrong comments for thetaToEta and etaToTheta in the .cxx
  • Add mCellGeomBuffer as new member which stores the geometry information of all cells of the current cluster. This way this information is only obtained ONCE instead of THREE times.
  • Removed unused unary operator& which can be dangerous.
  • Switched from (unsigned) short to (u)int16_t.

@mhemmer-cern

Copy link
Copy Markdown
Contributor Author

macOS-arm build seems to fail due to something unrelated to this PR

@mhemmer-cern mhemmer-cern changed the title [EMCAL-688] Update ClusterFactory [EMCAL-688] Update ClusterFactory evalDispersion function Sep 12, 2026
@mhemmer-cern mhemmer-cern changed the title [EMCAL-688] Update ClusterFactory evalDispersion function [EMCAL-688] Improve ClusterFactory evalDispersion function Sep 12, 2026
@mhemmer-cern
mhemmer-cern marked this pull request as draft September 13, 2026 20:38
@mhemmer-cern

Copy link
Copy Markdown
Contributor Author

Running over larger number of local files showed some weird outliers in the dispersion distribution. I will take another look again. Might be connected to clusters going over SM boundaries.

- Remove TMath calls with std function calls
- Fix wrong comments for `thetaToEta` and `etaToTheta` in the .cxx
- `buildCluster` uses the local index of cells in eta and phi for calcualting M02, M20 and dispersion. The member `mSharedCluster` would need to be set to true, to apply a correction for the local index when switching from one SM to antoher for cluster spanning two SM. This commit fixes this issue by setting `mSharedCluster` in `buildCluster`.
- Add `mCellGeomBuffer` as new member which stores the geometry information of all cells of the current cluster. This way this information is only obtained ONCE instead of THREE times.
- Removed unused unary operator& which can be dangerous.
@mhemmer-cern

Copy link
Copy Markdown
Contributor Author

Running over larger number of local files showed some weird outliers in the dispersion distribution. I will take another look again. Might be connected to clusters going over SM boundaries.

Indeed it was broken. Should be fixed now with this PR.

@mhemmer-cern mhemmer-cern changed the title [EMCAL-688] Improve ClusterFactory evalDispersion function [EMCAL-688] Improve ClusterFactory evalDispersion function and fix bug in buildCluster Sep 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant