Skip to content

Commit c09283a

Browse files
committed
TrackQA: Add converter for _000 to _001
1 parent 82f622f commit c09283a

File tree

2 files changed

+65
-0
lines changed

2 files changed

+65
-0
lines changed

Common/TableProducer/Converters/CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,3 +83,8 @@ o2physics_add_dpl_workflow(multmcextras-converter
8383
SOURCES multMCExtrasConverter.cxx
8484
PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore
8585
COMPONENT_NAME Analysis)
86+
87+
o2physics_add_dpl_workflow(trackqa-converter
88+
SOURCES trackQAConverter.cxx
89+
PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore
90+
COMPONENT_NAME Analysis)
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2+
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3+
// All rights not expressly granted are reserved.
4+
//
5+
// This software is distributed under the terms of the GNU General Public
6+
// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7+
//
8+
// In applying this license CERN does not waive the privileges and immunities
9+
// granted to it by virtue of its status as an Intergovernmental Organization
10+
// or submit itself to any jurisdiction.
11+
#include <limits>
12+
13+
#include "Framework/runDataProcessing.h"
14+
#include "Framework/AnalysisTask.h"
15+
#include "Framework/AnalysisDataModel.h"
16+
17+
using namespace o2;
18+
using namespace o2::framework;
19+
20+
struct trackQAConverter {
21+
Produces<aod::TracksQA_001> tracksQA_001;
22+
23+
void process(aod::TracksQA_000 const& tracksQA_000)
24+
{
25+
for (const auto& trackQA : tracksQA_000) {
26+
tracksQA_001(
27+
trackQA.trackId(),
28+
trackQA.tpcTime0(),
29+
trackQA.tpcdcaR(),
30+
trackQA.tpcdcaZ(),
31+
trackQA.tpcClusterByteMask(),
32+
trackQA.tpcdEdxMax0R(),
33+
trackQA.tpcdEdxMax1R(),
34+
trackQA.tpcdEdxMax2R(),
35+
trackQA.tpcdEdxMax3R(),
36+
trackQA.tpcdEdxTot0R(),
37+
trackQA.tpcdEdxTot1R(),
38+
trackQA.tpcdEdxTot2R(),
39+
trackQA.tpcdEdxTot3R(),
40+
// dummy values, not available in _000
41+
std::numeric_limits<int8_t>::min(), // deltaRefContParamY
42+
std::numeric_limits<int8_t>::min(), // deltaRefContParamZ
43+
std::numeric_limits<int8_t>::min(), // deltaRefContParamSnp
44+
std::numeric_limits<int8_t>::min(), // deltaRefContParamTgl
45+
std::numeric_limits<int8_t>::min(), // deltaRefContParamQ2Pt
46+
std::numeric_limits<int8_t>::min(), // deltaRefGloParamY
47+
std::numeric_limits<int8_t>::min(), // deltaRefGloParamZ
48+
std::numeric_limits<int8_t>::min(), // deltaRefGloParamSnp
49+
std::numeric_limits<int8_t>::min(), // deltaRefGloParamTgl
50+
std::numeric_limits<int8_t>::min()); // deltaRefGloParamQ2Pt
51+
}
52+
}
53+
};
54+
55+
WorkflowSpec defineDataProcessing(ConfigContext const& cfgc)
56+
{
57+
return WorkflowSpec{
58+
adaptAnalysisTask<trackQAConverter>(cfgc),
59+
};
60+
}

0 commit comments

Comments
 (0)