MarlinTPC  1.2.0
TimePixHighTOTAnalyserProcessor.h
1 #ifndef TimePixHighTOTAnalyserProcessor_h
2 #define TimePixHighTOTAnalyserProcessor_h 1
3 
4 // C++
5 #include <string>
6 
7 // LCIO
8 #include "lcio.h"
9 
10 // Marlin
11 #include "marlin/Processor.h"
12 #include "TimePixPixelMode.h"
13 #include "TimePixMapHandlerProcessor.h"
14 #include "lccd/ConditionsMap.hh"
15 
16 //AIDA
17 #include <AIDA/AIDA.h>
18 
19 namespace marlintpc
20 {
21 
22 // typedef lccd::ConditionsMap<tpcconddata::TimePixPixelMode::PixelKey, tpcconddata::TimePixPixelMode > TimePixModeMap ;
23 
24 /* the following comment is tranfered to doxygen documentation
25  * which begins with a second asterix, or in case of on line comment an extra third slash
26  */
48 class TimePixHighTOTAnalyserProcessor : public marlin::Processor
49 {
50 
51  public:
52 
53  /* This method will be called by the marlin package
54  * It returns a processor of the currend type (here TimePixHighTOTAnalyserProcessor)
55  */
56  virtual Processor* newProcessor()
57  {
59  }
60 
61  /* the default constructor
62  * here the processor parameters are registered to the marlin package
63  * other initialisation should be placed in the init method
64  */
66 
67  /* Called at the beginning of the job before anything is read.
68  * Use to initialize the processor, e.g. book histograms
69  */
70  virtual void init() ;
71 
72  /* Called for every run.
73  * in this processor it is not used
74  */
75  virtual void processRunHeader(lcio::LCRunHeader* run) ;
76 
77  /* Called for every event - the working horse.
78  * Here the real conversion take place
79  */
80  virtual void processEvent(lcio::LCEvent * evt) ;
81 
82  /* This method is only called if the check flag is set (default) in the main processor
83  * (where the input files are given)
84  * It should be used to create check plots which are not needed in a complete analysis
85  * (where normaly the check flag is deactivated)
86  */
87  virtual void check(lcio::LCEvent * evt) ;
88 
89 
90  /* Called after data processing for clean up.
91  * e.g. saving control histogramms, delete created objects
92  * (which are not stored in a collection/event), etc.
93  */
94  virtual void end() ;
95 
99  virtual void updateTimePixModeMap(lcio::LCEvent * evt);
100 
104  tpcconddata::TimePixMap* getUpdatedTimePixMap();
105 
106  protected:
107 
108  /* normally the doxygen documentation is palced before the method/variable
109  * but for one line comments in case of variables it may be more convenied for you
110  * to place it after the variable. In this case you use an arrow to tell doxygen
111  * to which variable the commet belongs to.
112  */
113 
114  std::string _RawDataColName ;
115  std::string _modeMapColName ;
116  std::string _modeMapCorrName;
117 
118  int _nColumn ;
119  int _nRow ;
120  int _chipID;
121  double _totThreshold;
122 
127 
133 
139 // TimePixModeMap* _modeMap;
140  tpcconddata::TimePixMap* _timePixMap;
141  tpcconddata::TimePixMap* _currentTimePixMap;
142  tpcconddata::TimePixMap* _correctedTimePixMap;
143 
144 
145  TimePixMapHandlerProcessor* _mapHandlerProcessor;
146 
147  AIDA::IHistogram1D * highTOT;
148  AIDA::IHistogram1D * TOTTOTCorrelation;
149  AIDA::IHistogram1D * TimeTOTCorrelation;
150  AIDA::IHistogram1D ** TOTValues;
151 
152 } ;
153 
154 }
155 
156 #endif
157 
158 
159 
tpcconddata::TimePixMap * getUpdatedTimePixMap()
In case that in processEvent a correction to the existing modeMap had been created, this function returns the modified TimePixMap.
Definition: TimePixHighTOTAnalyserProcessor.cc:702
virtual void updateTimePixModeMap(lcio::LCEvent *evt)
In case that in processEvent a correction to the existing modeMap had been created, this function modifies the TimePixMap to include these corrections.
Definition: TimePixHighTOTAnalyserProcessor.cc:654
std::string _modeMapCorrName
Definition: TimePixHighTOTAnalyserProcessor.h:116
int _outputIsTransient
give the status which is set to the transient flag of the output collection it is an int instead of a...
Definition: TimePixHighTOTAnalyserProcessor.h:126
Analysis Processor of MarlinTPC for TimePix Events with extraordinary high TOT values.
Definition: TimePixHighTOTAnalyserProcessor.h:48
std::string _modeMapColName
Definition: TimePixHighTOTAnalyserProcessor.h:115
double _totThreshold
-threshold on relation of TOT value to neighboring TOT values
Definition: TimePixHighTOTAnalyserProcessor.h:121
reads in conditionsdata objects TimePixModeMap and TimePixStatusMap and unifies them to the TimePixMa...
Definition: TimePixMapHandlerProcessor.h:63
tpcconddata::TimePixMap * _timePixMap
the actual mode map is a lccd::ConditionsMap the key is a PixelKey, specifically a struct which conta...
Definition: TimePixHighTOTAnalyserProcessor.h:140
int _chipID
Definition: TimePixHighTOTAnalyserProcessor.h:120
std::string _RawDataColName
Definition: TimePixHighTOTAnalyserProcessor.h:114
bool isFirstCollection
is true till the first output collection is wirten to an event used to to store parameters only in th...
Definition: TimePixHighTOTAnalyserProcessor.h:132
int _nColumn
-Number of columns of the chip
Definition: TimePixHighTOTAnalyserProcessor.h:118
int _nRow
-Number of rows of the chip
Definition: TimePixHighTOTAnalyserProcessor.h:119