Analysis Software
Documentation for
sPHENIX
simulation software
Home page
Related Pages
Modules
Namespaces
Classes
Files
Examples
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
TpotMon.h
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file TpotMon.h
1
#ifndef TPOT_TPOTMON_H
2
#define TPOT_TPOTMON_H
3
4
#include "
MicromegasGeometry.h
"
5
6
#include <
micromegas/MicromegasDefs.h
>
7
#include <
micromegas/MicromegasMapping.h
>
8
#include <
micromegas/MicromegasCalibrationData.h
>
9
#include <onlmon/OnlMon.h>
10
11
#include <array>
12
#include <memory>
13
14
class
Event
;
15
class
TH1;
16
class
TH2;
17
class
TH2Poly;
18
19
class
TpotMon
:
public
OnlMon
20
{
21
public
:
22
TpotMon
(
const
std::string
&
name
);
23
~TpotMon
()
override
=
default
;
24
25
int
process_event
(
Event
*evt)
override
;
26
int
Init
()
override
;
27
int
BeginRun
(
const
int
runno)
override
;
28
int
Reset
()
override
;
29
31
void
set_calibration_file
(
const
std::string
&
value
)
32
{
m_calibration_filename
=
value
; }
33
35
void
set_max_sample
(
int
value
)
36
{
m_max_sample
=
value
; }
37
39
void
set_n_sigma
(
double
value
) {
m_n_sigma
=
value
; }
40
42
void
set_min_adc
(
double
value
) {
m_min_adc
=
value
; }
43
44
// define signal sample window
45
using
sample_window_t
= std::pair<int, int>;
46
void
set_sample_window_signal
(
const
sample_window_t
&
value
)
47
{
m_sample_window_signal
=
value
; }
48
49
private
:
50
52
void
setup_detector_bins
( TH2Poly* );
53
55
void
setup_resist_bins
( TH2Poly*,
MicromegasDefs::SegmentationType
);
56
58
int
m_evtcnt
= 0;
59
61
/*
62
* it is estimated by summing the number of recorded waveforms/max_waveform/trigger
63
* this will break when zero suppression is implemented
64
*/
65
double
m_fullevtcnt
= 0;
66
68
MicromegasMapping
m_mapping
;
69
71
MicromegasGeometry
m_geometry
;
72
74
std::string
m_calibration_filename
;
75
77
MicromegasCalibrationData
m_calibration_data
;
78
80
int
m_max_sample
= 100;
81
82
// sample window
83
sample_window_t
m_sample_window_signal
= {20, 40};
84
86
double
m_n_sigma
= 5;
87
89
double
m_min_adc
= 50;
90
92
TH1*
m_counters
=
nullptr
;
93
95
TH2Poly*
m_detector_multiplicity_z
=
nullptr
;
96
TH2Poly*
m_detector_multiplicity_phi
=
nullptr
;
97
99
TH2Poly*
m_detector_occupancy_z
=
nullptr
;
100
TH2Poly*
m_detector_occupancy_phi
=
nullptr
;
101
103
TH2Poly*
m_resist_multiplicity_z
=
nullptr
;
104
TH2Poly*
m_resist_multiplicity_phi
=
nullptr
;
105
107
TH2Poly*
m_resist_occupancy_z
=
nullptr
;
108
TH2Poly*
m_resist_occupancy_phi
=
nullptr
;
109
110
//@name per detector structure
112
class
detector_histograms_t
113
{
114
public
:
115
117
TH1*
m_counts_sample
=
nullptr
;
118
120
TH2*
m_adc_sample
=
nullptr
;
121
123
TH1*
m_hit_charge
=
nullptr
;
124
126
TH1*
m_hit_multiplicity
=
nullptr
;
127
129
TH1*
m_hit_vs_channel
=
nullptr
;
130
};
132
133
//@name map tile centers (from MicromegasGeometry) to fee_id
134
std::map<int, MicromegasGeometry::point_t>
m_tile_centers
;
135
136
//@name map detector histograms to fee id
137
std::map<int, detector_histograms_t>
m_detector_histograms
;
138
139
};
140
141
#endif
/* TPOT_TPOTMON_H */
OnlMon
blob
main
subsystems
tpot
TpotMon.h
Built by
Jin Huang
. updated:
Sat Feb 17 2024 22:18:29
using
1.8.2 with
sPHENIX GitHub integration