Skip to content

Commit 46a0e26

Browse files
committed
[PWGDQ] added selection of collisions based on z position
The collisions are selected based on configurable lower and upper limits for the z position.
1 parent 26055f1 commit 46a0e26

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

PWGDQ/Tasks/qaMatching.cxx

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -270,6 +270,10 @@ struct QaMatching {
270270

271271
Configurable<bool> cfgIsMc{"cfgIsMc", true, "Wheter the processed data is from MC simulations"};
272272

273+
//// Variables for selecting the collisions
274+
Configurable<float> cfgVtxZLow{"cfgVtxZLow", -10.0f, "Lower limit for the vertex z position"};
275+
Configurable<float> cfgVtxZUp{"cfgVtxZUp", 10.0f, "Upper limit for the vertex z position"};
276+
273277
//// Variables for selecting muon tracks
274278
Configurable<float> cfgPMchLow{"cfgPMchLow", 0.0f, ""};
275279
Configurable<float> cfgPtMchLow{"cfgPtMchLow", 0.7f, ""};
@@ -2038,6 +2042,11 @@ struct QaMatching {
20382042
int64_t collisionIndex = collision.globalIndex();
20392043
auto bc = bcs.rawIteratorAt(collision.bcId());
20402044

2045+
// remove vertices outside the allowed z range
2046+
if ((collision.posZ() < cfgVtxZLow.value) || (collision.posZ() > cfgVtxZUp.value)) {
2047+
continue;
2048+
}
2049+
20412050
// fill collision information for MFT standalone tracks
20422051
for (const auto& mftTrack : mftTracks) {
20432052
if (!mftTrack.has_collision())

0 commit comments

Comments
 (0)