File tree Expand file tree Collapse file tree 2 files changed +13
-2
lines changed
Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change 1717#ifndef AliceO2_TPC_CLUSTERS_H
1818#define AliceO2_TPC_CLUSTERS_H
1919
20- // root includes
20+ // root includes
2121#include " TCanvas.h"
2222
23- // o2 includes
23+ // o2 includes
2424#include " TPCBase/CalDet.h"
2525#include " TPCBase/Sector.h"
2626#include " DataFormatsTPC/Defs.h"
@@ -75,6 +75,8 @@ class Clusters
7575 CalPad& getSigmaPad () { return mSigmaPad ; }
7676 CalPad& getTimeBin () { return mTimeBin ; }
7777
78+ CalPad getOccupancy (int nHBFPerTF = 32 );
79+
7880 void endTF () { ++mProcessedTFs ; }
7981
8082 size_t getProcessedTFs () { return mProcessedTFs ; }
Original file line number Diff line number Diff line change 2222#include " TPCBase/ROC.h"
2323#include " TPCBase/CRU.h"
2424#include " TPCBase/Mapper.h"
25+ #include " TPCBase/ParameterElectronics.h"
2526#include " DataFormatsTPC/ClusterNative.h"
2627#include " DataFormatsTPC/KrCluster.h"
28+ #include " CommonConstants/LHCConstants.h"
2729
2830ClassImp (o2::tpc::qc::Clusters);
2931
@@ -152,6 +154,13 @@ void Clusters::reset()
152154 mProcessedTFs = 0 ;
153155}
154156
157+ // ______________________________________________________________________________
158+ o2::tpc::CalPad Clusters::getOccupancy (int nHBFPerTF)
159+ {
160+ o2::tpc::CalPad occupancy = mNClusters ;
161+ occupancy /= float (mProcessedTFs * (o2::constants::lhc::LHCMaxBunches * nHBFPerTF) / float (o2::tpc::ParameterElectronics::TIMEBININBC));
162+ return occupancy;
163+ }
155164// ______________________________________________________________________________
156165void Clusters::merge (Clusters& clusters)
157166{
You can’t perform that action at this time.
0 commit comments