 |
Belle II Software
release-05-02-19
|
17 #include "trg/trg/Debug.h"
18 #include "trg/ecl/modules/trgeclRawdataAnalysis/TRGECLRawdataAnalysisModule.h"
37 TRGECLRawdataAnalysisModule::version()
const
39 return string(
"TRGECLAnalysisModule 1.00");
44 TRGECLRawdataAnalysisModule::TRGECLRawdataAnalysisModule()
46 _debugLevel(0), _Clustering(1)
49 string desc =
"TRGECLRawdataAnalysisModule(" +
version() +
")";
59 std::cout <<
"TRGECLRawdataAnalysisModule ... created" << std::endl;
69 std::cout <<
"TRGECLRawdataAnalysisModule ... destructed " << std::endl;
83 std::cout <<
"TRGECLRawdataAnalysisModule::initialize ... options" << std::endl;
108 std::cout <<
"TRGECLRawdataAnalysisModule ... beginRun called " << std::endl;
121 std::cout <<
"TRGECLMoudle ... event called" << std::endl;
124 std::vector<int> TCId;
125 std::vector<double> TCTiming;
126 std::vector<double> TCEnergy;
138 for (
int ii = 0; ii < trgeclUnpackerStoreArray.
getEntries(); ii++) {
141 int iTCID = (TCHit->
getTCId() - 1);
143 int HitEnergy = TCHit -> getTCEnergy();
144 HitRevoFAM = TCHit -> getRevoFAM();
145 HitFineTime = TCHit -> getTCTime();
147 if (iTCID == -1) {
continue;}
149 TCId.push_back(iTCID + 1);
150 TCTiming.push_back(HitTiming);
151 TCEnergy.push_back(HitEnergy);
157 if (TCId.size() > 0) {
161 obj_cluster.
setICN(TCId, TCEnergy, TCTiming);
166 int Timing = ((HitFineTime >> 3) & 0xF) + ((HitRevoFAM & 0x7F) << 4);
173 TimingArray[
m_hitNum]->setTiming(Timing);
194 std::cout <<
"TRGECLRawdataAnalysisModule ... endRun called " << std::endl;
204 std::cout <<
"TRGECLRawdataAnalysisModule ... terminate called " << std::endl;
T * appendNew()
Construct a new T object at the end of the array.
StoreArray< TRGECLTiming > m_TRGECLTiming
output for TRGECLTiming
void setDescription(const std::string &description)
Sets the description of the module.
static int level(void)
returns the debug level.
int m_nEvent
Event number.
#define REG_MODULE(moduleName)
Register the given module (without 'Module' suffix) with the framework.
int getTCId() const
The method to get cell id.
int m_hitTCNum
TC Hit number.
StoreArray< TRGECLCluster > m_TRGECLCluster
output for TRGECLCluster
int _Clustering
Clustering option.
std::string version(void) const
returns version of TRGECLModule.
virtual void initialize() override
Initilizes TRGECLModule.
virtual void terminate() override
Called when processing ended.
Abstract base class for different kinds of events.
void setClusteringMethod(int method)
Set.
void setEventId(int eventId)
Set EventId.
int getTCTime() const
The method to get hit average time.
StoreArray< TRGECLUnpackerStore > m_TRGECLUnpackerStore
output for TRGECLUnpackerStore
int _debugLevel
Debug level.
virtual void endRun() override
Called when run ended.
void save(int)
Save Cluster information in TRGECLCluster Table.
void addParam(const std::string &name, T ¶mVariable, const std::string &description, const T &defaultValue)
Adds a new parameter to the module.
virtual ~TRGECLRawdataAnalysisModule()
Destructor
int m_hitNum
The current number of created hits in an event.
void setICN(std::vector< int >)
Destructor.
static std::string tab(void)
returns tab spaces.
Accessor to arrays stored in the data store.
virtual void beginRun() override
Called when new run started.
A Class of ECL Trigger clustering
int getEntries() const
Get the number of objects in the array.
virtual void event() override
Called event by event.