Skip to content

Commit 7f88118

Browse files
authored
PWGJE: added QA histos for BC and col matching to the EMCAL task(AliceO2Group#1610)
1 parent 83fecf6 commit 7f88118

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

PWGJE/TableProducer/emcalCorrectionTask.cxx

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ struct EmcalCorrectionTask {
7676
OutputObj<TH2I> hCellRowCol{"hCellRowCol"};
7777
OutputObj<TH1F> hClusterE{"hClusterE"};
7878
OutputObj<TH2F> hClusterEtaPhi{"hClusterEtaPhi"};
79+
OutputObj<TH1F> hCollisionMatching{"hCollisionMatching"};
7980

8081
void init(InitContext const&)
8182
{
@@ -137,6 +138,7 @@ struct EmcalCorrectionTask {
137138
hCellRowCol.setObject(new TH2I("hCellRowCol", "hCellRowCol;Column;Row", 97, 0, 97, 600, 0, 600));
138139
hClusterE.setObject(new TH1F("hClusterE", "hClusterE", 200, 0.0, 100));
139140
hClusterEtaPhi.setObject(new TH2F("hClusterEtaPhi", "hClusterEtaPhi", 160, -0.8, 0.8, 72, 0, 2 * 3.14159));
141+
hCollisionMatching.setObject(new TH1F("hCollisionMatching", "hCollisionMatching", 3, -0.5, 2.5)); // 0, no vertex,1 vertex found , 2 multiple vertices found
140142
}
141143

142144
// void process(aod::Collision const& collision, soa::Filtered<aod::Tracks> const& fullTracks, aod::Calos const& cells)
@@ -220,6 +222,8 @@ struct EmcalCorrectionTask {
220222
float vx = 0, vy = 0, vz = 0;
221223
bool hasCollision = false;
222224
if (collisions.size() > 1) {
225+
if (i == 0)
226+
hCollisionMatching->Fill(2);
223227
LOG(error) << "More than one collision in the bc. This is not supported.";
224228
} else {
225229
// dummy loop to get the first collision
@@ -228,6 +232,8 @@ struct EmcalCorrectionTask {
228232
vy = col.posY();
229233
vz = col.posZ();
230234
hasCollision = true;
235+
if (i == 0)
236+
hCollisionMatching->Fill(1);
231237

232238
// store positions of all tracks of collision
233239
auto groupedTracks = tracks.sliceBy(perCollision, col.globalIndex());
@@ -298,7 +304,9 @@ struct EmcalCorrectionTask {
298304
} // end of collision loop
299305
}
300306
if (!hasCollision) {
301-
LOG(warning) << "No vertex found for event. Assuming (0,0,0).";
307+
if (i == 0)
308+
hCollisionMatching->Fill(0);
309+
// LOG(warning) << "No vertex found for event. Assuming (0,0,0).";
302310
}
303311

304312
// Store the clusters in the table where a mathcing collision could

0 commit comments

Comments
 (0)