Skip to content

Commit 4156c3d

Browse files
prottayCMTProttay Das
andauthored
[PWGLF] added RCT flags (#11149)
Co-authored-by: Prottay Das <prottay@alipap1.cern.ch>
1 parent 1585fed commit 4156c3d

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

PWGLF/Tasks/Strangeness/lambdapolsp.cxx

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ using namespace o2;
6363
using namespace o2::framework;
6464
using namespace o2::framework::expressions;
6565
using std::array;
66+
using namespace o2::aod::rctsel;
6667

6768
using dauTracks = soa::Join<aod::DauTrackExtras, aod::DauTrackTPCPIDs>;
6869
using v0Candidates = soa::Join<aod::V0CollRefs, aod::V0Cores, aod::V0Extras>;
@@ -151,12 +152,23 @@ struct lambdapolsp {
151152
ConfigurableAxis configthnAxisPol{"configthnAxisPol", {VARIABLE_WIDTH, -1.0, -0.6, -0.2, 0, 0.2, 0.4, 0.8}, "Pol"};
152153
ConfigurableAxis configbinAxis{"configbinAxis", {VARIABLE_WIDTH, -0.8, -0.4, -0.2, 0, 0.2, 0.4, 0.8}, "BA"};
153154
// ConfigurableAxis configphiAxis{"configphiAxis", {VARIABLE_WIDTH, 0.0, 0.2, 0.4, 0.8, 1.0, 2.0, 2.5, 3.0, 4.0, 5.0, 5.5, 6.28}, "PhiAxis"};
155+
struct : ConfigurableGroup {
156+
Configurable<bool> requireRCTFlagChecker{"requireRCTFlagChecker", true, "Check event quality in run condition table"};
157+
Configurable<std::string> cfgEvtRCTFlagCheckerLabel{"cfgEvtRCTFlagCheckerLabel", "CBT_hadronPID", "Evt sel: RCT flag checker label"};
158+
Configurable<bool> cfgEvtRCTFlagCheckerZDCCheck{"cfgEvtRCTFlagCheckerZDCCheck", true, "Evt sel: RCT flag checker ZDC check"};
159+
Configurable<bool> cfgEvtRCTFlagCheckerLimitAcceptAsBad{"cfgEvtRCTFlagCheckerLimitAcceptAsBad", false, "Evt sel: RCT flag checker treat Limited Acceptance As Bad"};
160+
} rctCut;
161+
162+
RCTFlagsChecker rctChecker;
154163

155164
SliceCache cache;
156165
HistogramRegistry histos{"histos", {}, OutputObjHandlingPolicy::AnalysisObject};
157166

158167
void init(o2::framework::InitContext&)
159168
{
169+
170+
rctChecker.init(rctCut.cfgEvtRCTFlagCheckerLabel, rctCut.cfgEvtRCTFlagCheckerZDCCheck, rctCut.cfgEvtRCTFlagCheckerLimitAcceptAsBad);
171+
160172
AxisSpec thnAxisres{resNbins, lbinres, hbinres, "Reso"};
161173
AxisSpec thnAxisInvMass{IMNbins, lbinIM, hbinIM, "#it{M} (GeV/#it{c}^{2})"};
162174
AxisSpec thnAxisCosThetaStar{SANbins, lbinSA, hbinSA, "SA"};
@@ -677,6 +689,9 @@ struct lambdapolsp {
677689
return;
678690
}
679691

692+
if (rctCut.requireRCTFlagChecker && !rctChecker(collision)) {
693+
return;
694+
}
680695
// currentRunNumber = collision.foundBC_as<BCsRun3>().runNumber();
681696
auto bc = collision.foundBC_as<BCsRun3>();
682697

0 commit comments

Comments
 (0)