All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
ClusterParams.h
Go to the documentation of this file.
1 #ifndef UTIL_CLUSTERPARAMS_H
2 #define UTIL_CLUSTERPARAMS_H
3 
6 
7 namespace cluster{
8 
9  /**
10  \class cluster_params
11  (Detailed) information holder for 2D cluster, computed by ClusterParamsAlg
12  */
14  {
15  public:
17  //Initialize all values.
18  Clear();
19  }
20 
21  Polygon2D PolyObject; ///< Polygon Object...see Polygon2D.hh
22 
23  util::PxPoint start_point; ///< start point
24  util::PxPoint end_point; ///< end point
25 
26  double sum_charge; ///< Sum charge of hits in ADC
27  double mean_charge; ///< Mean (average) charge of hits in ADC
28  double rms_charge; ///< RMS (standard deviation of sample) of charge of hits in ADC
29  double sum_ADC; ///< Sum charge of ADC counts of hits, in ADC
30  double mean_ADC; ///< Mean (average) of ADC counts of hits, in ADC
31  double rms_ADC; ///< RMS (standard deviation of sample) of ADC counts of hits in ADC
32  double mean_x; ///< Mean of hits along x, peaks only
33  double mean_y; ///< Mean of hits along y, peaks only
34  double rms_x; ///< rms of hits along x (wires)
35  double rms_y; ///< rms of hits along y, (time)
36  double charge_wgt_x; ///< Mean of hits along x, charge weighted
37  double charge_wgt_y; ///< Mean of hits along y, charge weighted
38  double cluster_angle_2d; ///< Linear best fit to high-charge hits in the cluster
39  double angle_2d; ///< Angle of axis in wire/hit view
40  double opening_angle; ///< Width of angular distubtion wrt vertx
41  double opening_angle_charge_wgt; ///< Same for charge_wgt
42  double closing_angle; ///< Width of angular distubtion wrt endpoint
43  double closing_angle_charge_wgt; ///< Same for charge_wgt
44  double start_charge; ///< Charge at the start of the cluster
45  double end_charge; ///< Charge at the (other) end of the cluster
46  double eigenvalue_principal; ///< the principal eigenvalue from PCA
47  double eigenvalue_secondary; ///< the secondary eigenvalue from PCA
48  double verticalness; ///< ???
49 
50  double length;
51  double width;
52 
56  double N_Wires;
58  double N_Hits;
59  double N_Hits_HC;
60 
61  double modmeancharge;
62  double RMS_charge;
63 
64  /**
65  +1 means shower is "forward - start wire < end wire"
66  -1 is backwards, 0 is undecided
67  */
68  int direction;
69 
70  double showerness; ///< got heart
71  double trackness; ///< got soul
72  double offaxis_hits; ///< got brain
73 
74  void Clear(){
76  end_point.Clear();
77  sum_charge = -999.999 ;
78  mean_charge = -999.999 ;
79  rms_charge = -999.999 ;
80  sum_ADC = -999.999 ;
81  mean_ADC = -999.999 ;
82  rms_ADC = -999.999 ;
83  mean_x = -999.999 ;
84  mean_y = -999.999 ;
85  rms_x = -999.999 ;
86  rms_y = -999.999 ;
87  charge_wgt_x = -999.999 ;
88  charge_wgt_y = -999.999 ;
89  cluster_angle_2d = -999.999 ;
90  angle_2d = -999.999 ;
91  eigenvalue_principal = -999.999 ;
92  eigenvalue_secondary = -999.999 ;
93  multi_hit_wires = -999.999 ;
94  N_Wires = -999.999 ;
95  verticalness = -999.999 ;
96  opening_angle = -999.999 ;
97  opening_angle_charge_wgt = -999.999 ;
98  closing_angle = -999.999 ;
99  closing_angle_charge_wgt = -999.999 ;
100  start_charge = -999.999 ;
101  end_charge = -999.999 ;
102  offaxis_hits = -999.999 ;
103  modmeancharge = -999.999 ;
104  RMS_charge = -999.999 ;
105  modified_hit_density = -999.999 ;
106  N_Hits = -999.999 ;
107  N_Hits_HC = -999.999 ;
108  length = -999.999 ;
109  width = -999.999 ;
110  hit_density_1D = -999.999 ;
111  hit_density_2D = -999.999 ;
112  direction = 0 ;
113  showerness = -999.999 ;
114  trackness = -999.999 ;
115  }
116 
117  template <typename Stream>
118  void Report(Stream& os) const {
119 
120  os << "ClusterParams report: \n"
121  << " start_point .............. : (" << start_point.w <<","<<start_point.t<<")\n"
122  << " end_point ................ : (" << end_point.w <<","<<end_point.t<<")\n"
123  << " sum_charge ............... : "<< sum_charge << "\n"
124  << " mean_charge ............. : " << mean_charge << "\n"
125  << " mean_x ................... : " << mean_x << "\n"
126  << " mean_y ................... : " << mean_y << "\n"
127  << " rms_x .................... : " << rms_x << "\n"
128  << " rms_y .................... : " << rms_y << "\n"
129  << " charge_wgt_x ............. : " << charge_wgt_x << "\n"
130  << " charge_wgt_y ............. : " << charge_wgt_y << "\n"
131  << " cluster_angle_2d ......... : " << cluster_angle_2d << "\n"
132  << " angle_2d ................. : " << angle_2d << "\n"
133  << " eigenvalue_principal ..... : " << eigenvalue_principal << "\n"
134  << " eigenvalue_secondary ..... : " << eigenvalue_secondary << "\n"
135  << " multi_hit_wires .......... : " << multi_hit_wires << "\n"
136  << " N_Wires .................. : " << N_Wires << "\n"
137  << " N_Hits ................... : " << N_Hits << "\n"
138  << " N_Hits_HC ................ : " << N_Hits_HC << "\n"
139  << " verticalness ............. : " << verticalness << "\n"
140  << " opening_angle ............ : " << opening_angle << "\n"
141  << " opening_angle_charge_wgt . : " << opening_angle_charge_wgt << "\n"
142  << " closing_angle ............ : " << closing_angle << "\n"
143  << " closing_angle_charge_wgt . : " << closing_angle_charge_wgt << "\n"
144  << " start_charge ............. : " << start_charge << "\n"
145  << " end_charge ............... : " << end_charge << "\n"
146  << " offaxis_hits ............. : " << offaxis_hits << "\n"
147  << " modified_hit_density ..... : " << modified_hit_density << "\n"
148  << " modified mean charge ...... : " << modmeancharge << "\n"
149  << " charge_RMS ................ : " << RMS_charge << "\n"
150  << " length ................... : " << length << "\n"
151  << " width .................... : " << width << "\n"
152  << " hit_density_1D ........... : " << hit_density_1D << "\n"
153  << " hit_density_2D ........... : " << hit_density_2D << "\n"
154  << " showerness ............... : " << showerness << "\n"
155  << " trackness ................ : " << trackness << "\n"
156  << " direction ................ : " << direction << "\n";
157  }
158 
159  }; // class cluster_params
160 } // namespace cluster
161 
162 #endif
double rms_ADC
RMS (standard deviation of sample) of ADC counts of hits in ADC.
Definition: ClusterParams.h:31
2D polygon object
double closing_angle_charge_wgt
Same for charge_wgt.
Definition: ClusterParams.h:43
double charge_wgt_y
Mean of hits along y, charge weighted.
Definition: ClusterParams.h:37
process_name cluster
Definition: cheaterreco.fcl:51
double mean_x
Mean of hits along x, peaks only.
Definition: ClusterParams.h:32
double start_charge
Charge at the start of the cluster.
Definition: ClusterParams.h:44
double rms_charge
RMS (standard deviation of sample) of charge of hits in ADC.
Definition: ClusterParams.h:28
Polygon2D PolyObject
Polygon Object...see Polygon2D.hh.
Definition: ClusterParams.h:21
double trackness
got soul
Definition: ClusterParams.h:71
double eigenvalue_principal
the principal eigenvalue from PCA
Definition: ClusterParams.h:46
double mean_ADC
Mean (average) of ADC counts of hits, in ADC.
Definition: ClusterParams.h:30
double mean_y
Mean of hits along y, peaks only.
Definition: ClusterParams.h:33
void Report(Stream &os) const
double eigenvalue_secondary
the secondary eigenvalue from PCA
Definition: ClusterParams.h:47
double sum_charge
Sum charge of hits in ADC.
Definition: ClusterParams.h:26
void Clear()
Definition: PxUtils.h:25
double t
Definition: PxUtils.h:11
util::PxPoint start_point
start point
Definition: ClusterParams.h:23
double angle_2d
Angle of axis in wire/hit view.
Definition: ClusterParams.h:39
double offaxis_hits
got brain
Definition: ClusterParams.h:72
double w
Definition: PxUtils.h:10
double showerness
got heart
Definition: ClusterParams.h:70
double sum_ADC
Sum charge of ADC counts of hits, in ADC.
Definition: ClusterParams.h:29
util::PxPoint end_point
end point
Definition: ClusterParams.h:24
double mean_charge
Mean (average) charge of hits in ADC.
Definition: ClusterParams.h:27
double charge_wgt_x
Mean of hits along x, charge weighted.
Definition: ClusterParams.h:36
double opening_angle_charge_wgt
Same for charge_wgt.
Definition: ClusterParams.h:41
double opening_angle
Width of angular distubtion wrt vertx.
Definition: ClusterParams.h:40
double cluster_angle_2d
Linear best fit to high-charge hits in the cluster.
Definition: ClusterParams.h:38
double rms_x
rms of hits along x (wires)
Definition: ClusterParams.h:34
double rms_y
rms of hits along y, (time)
Definition: ClusterParams.h:35
double closing_angle
Width of angular distubtion wrt endpoint.
Definition: ClusterParams.h:42
bnb BNB Stream
double end_charge
Charge at the (other) end of the cluster.
Definition: ClusterParams.h:45