Project
Loading...
Searching...
No Matches
TrackClusters.h
Go to the documentation of this file.
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
16
17#ifndef AliceO2_TPC_QC_TRACKCLUSTERS_H
18#define AliceO2_TPC_QC_TRACKCLUSTERS_H
19
20// root includes
21#include "TH1F.h"
22
23// o2 includes
24#include "DataFormatsTPC/Defs.h"
26
27namespace o2::tpc
28{
29class TrackTPC;
30struct ClusterNativeAccess;
31
32namespace qc
33{
34
37{
38 public:
40 TrackClusters() = default;
41
44 bool processTrackAndClusters(const std::vector<o2::tpc::TrackTPC>* tracks, const o2::tpc::ClusterNativeAccess* clusterIndex, std::vector<o2::tpc::TPCClRefElem>* clusRefs);
45
48
50 void resetHistograms();
51
53 void dumpToFile(std::string filename);
54
55 // To set the elementary track cuts
56 void setTrackClustersCuts(int minNCls = 60, float mindEdxTot = 10.0, float absEta = 1.)
57 {
58 mCutMinNCls = minNCls;
59 mCutMindEdxTot = mindEdxTot;
60 mCutAbsEta = absEta;
61 }
62
63 std::unordered_map<std::string, std::vector<std::unique_ptr<TH1>>>& getMapOfHisto() { return mMapHist; }
64 const std::unordered_map<std::string, std::vector<std::unique_ptr<TH1>>>& getMapOfHisto() const { return mMapHist; }
65
66 private:
67 int mCutMinNCls = 60; // minimum N clusters
68 float mCutMindEdxTot = 10.f; // dEdxTot min value
69 float mCutAbsEta = 1.f; // AbsTgl max cut
70 std::unordered_map<std::string, std::vector<std::unique_ptr<TH1>>> mMapHist;
71 ClassDefNV(TrackClusters, 1)
72};
73} // namespace qc
74} // namespace o2::tpc
75
76#endif
Shared cluster and crossed rows TPC quality control task.
void dumpToFile(std::string filename)
Dump results to a file.
void initializeHistograms()
Initialize all histograms.
TrackClusters()=default
Constructor.
void resetHistograms()
Reset all histograms.
void setTrackClustersCuts(int minNCls=60, float mindEdxTot=10.0, float absEta=1.)
const std::unordered_map< std::string, std::vector< std::unique_ptr< TH1 > > > & getMapOfHisto() const
bool processTrackAndClusters(const std::vector< o2::tpc::TrackTPC > *tracks, const o2::tpc::ClusterNativeAccess *clusterIndex, std::vector< o2::tpc::TPCClRefElem > *clusRefs)
std::unordered_map< std::string, std::vector< std::unique_ptr< TH1 > > > & getMapOfHisto()
Global TPC definitions and constants.
Definition SimTraits.h:167
std::string filename()