Class managing the creation of a new recob::Hit
object.
More...
#include <HitCreator.h>
Public Types | |
using | RegionOfInterest_t = recob::Wire::RegionsOfInterest_t::datarange_t |
Type of one region of interest. More... | |
Public Member Functions | |
HitCreator (raw::RawDigit const &digits, geo::WireID const &wireID, raw::TDCtick_t start_tick, raw::TDCtick_t end_tick, float rms, float peak_time, float sigma_peak_time, float peak_amplitude, float sigma_peak_amplitude, float hit_integral, float hit_sigma_integral, float summedADC, short int multiplicity, short int local_index, float goodness_of_fit, int dof) | |
Constructor: extracts some information from raw digit. More... | |
HitCreator (recob::Wire const &wire, geo::WireID const &wireID, raw::TDCtick_t start_tick, raw::TDCtick_t end_tick, float rms, float peak_time, float sigma_peak_time, float peak_amplitude, float sigma_peak_amplitude, float hit_integral, float hit_sigma_integral, float summedADC, short int multiplicity, short int local_index, float goodness_of_fit, int dof) | |
Constructor: extracts some information from wire. More... | |
HitCreator (recob::Wire const &wire, geo::WireID const &wireID, raw::TDCtick_t start_tick, raw::TDCtick_t end_tick, float rms, float peak_time, float sigma_peak_time, float peak_amplitude, float sigma_peak_amplitude, float hit_integral, float hit_sigma_integral, short int multiplicity, short int local_index, float goodness_of_fit, int dof) | |
Constructor: computes sum of ADC from wire. More... | |
HitCreator (recob::Wire const &wire, geo::WireID const &wireID, float rms, float peak_time, float sigma_peak_time, float peak_amplitude, float sigma_peak_amplitude, float hit_integral, float hit_sigma_integral, float summedADC, short int multiplicity, short int local_index, float goodness_of_fit, int dof, RegionOfInterest_t const &signal) | |
Constructor: uses region of interest specified by index. More... | |
HitCreator (recob::Wire const &wire, geo::WireID const &wireID, float rms, float peak_time, float sigma_peak_time, float peak_amplitude, float sigma_peak_amplitude, float hit_integral, float hit_sigma_integral, float summedADC, short int multiplicity, short int local_index, float goodness_of_fit, int dof, size_t iSignalRoI) | |
Constructor: uses region of interest specified by index. More... | |
HitCreator (recob::Hit const &from) | |
Constructor: copies from an existing hit. More... | |
HitCreator (recob::Hit const &from, geo::WireID const &wireID) | |
Constructor: copies from an existing hit, changing wire ID. More... | |
recob::Hit && | move () |
Prepares the constructed hit to be moved away. More... | |
recob::Hit const & | copy () const |
Returns the constructed wire. More... | |
Protected Attributes | |
recob::Hit | hit |
Local instance of the hit being constructed. More... | |
Class managing the creation of a new recob::Hit
object.
In order to be as simple as possible (Plain Old Data), data products like recob::Hit
need to be stripped of most of their functions, including the ability to communicate whether a value we try to store is invalid (that would require a art::Exception` – art – or at least a message on the screen – MessageFacility) and the ability to read things from event, services (e.g. geometry) etc.
A Creator is a class that creates a temporary data product, and at the end it yields it to the caller for storage. This last step should be by move construction, although a copy method is also provided.
An example of creating a recob::Hit
object (assuming all the relevant variables have been assigned proper values):
This is a one-step creation object: the hit is constructed at the same time the HitCreator is, and no facility is offered to modify the constructed hit, or to create another one.
The constructors currently provided are:
recob::Wire
, [CVS]recob::Wire
, [CVS], summedADC
is automatically computed from wirerecob::Wire
, [CVS], start and stop time from a region of interestrecob::Wire
, [CVS], start and stop time from index of region of interest Definition at line 83 of file HitCreator.h.
using recob::HitCreator::RegionOfInterest_t = recob::Wire::RegionsOfInterest_t::datarange_t |
Type of one region of interest.
Definition at line 86 of file HitCreator.h.
recob::HitCreator::HitCreator | ( | raw::RawDigit const & | digits, |
geo::WireID const & | wireID, | ||
raw::TDCtick_t | start_tick, | ||
raw::TDCtick_t | end_tick, | ||
float | rms, | ||
float | peak_time, | ||
float | sigma_peak_time, | ||
float | peak_amplitude, | ||
float | sigma_peak_amplitude, | ||
float | hit_integral, | ||
float | hit_sigma_integral, | ||
float | summedADC, | ||
short int | multiplicity, | ||
short int | local_index, | ||
float | goodness_of_fit, | ||
int | dof | ||
) |
Constructor: extracts some information from raw digit.
digits | a pointer to a raw::RawDigit (for channel, view, signal type) |
wireID | ID of the wire the hit is on |
start_tick | first tick in the region the hit was extracted from |
end_tick | first tick after the region the hit was extracted from |
rms | RMS of the signal hit, in TDC time units |
peak_time | time at peak of the signal, in TDC time units |
sigma_peak_time | uncertainty on time at peak, in TDC time units |
peak_amplitude | amplitude of the signal at peak, in ADC units |
sigma_peak_amplitude | uncertainty on amplitude at peak |
hit_integral | total charge integrated under the hit signal |
hit_sigma_integral | uncertainty on the total hit charge |
summedADC | total ADC count in the region assigned to the hit |
multiplicity | number of hits in the region it was extracted from |
local_index | index of this hit in the region it was extracted from |
goodness_of_fit | quality parameter for the hit |
dof | degrees of freedom in the definition of the hit shape |
The information used from the raw digit is the channel ID; view and signal type are obtained from geometry.
Definition at line 50 of file HitCreator.cxx.
recob::HitCreator::HitCreator | ( | recob::Wire const & | wire, |
geo::WireID const & | wireID, | ||
raw::TDCtick_t | start_tick, | ||
raw::TDCtick_t | end_tick, | ||
float | rms, | ||
float | peak_time, | ||
float | sigma_peak_time, | ||
float | peak_amplitude, | ||
float | sigma_peak_amplitude, | ||
float | hit_integral, | ||
float | hit_sigma_integral, | ||
float | summedADC, | ||
short int | multiplicity, | ||
short int | local_index, | ||
float | goodness_of_fit, | ||
int | dof | ||
) |
Constructor: extracts some information from wire.
wire | a pointer to a recob::Wire (for channel, view, signal type) |
wireID | ID of the wire the hit is on |
start_tick | first tick in the region the hit was extracted from |
end_tick | first tick after the region the hit was extracted from |
rms | RMS of the signal hit, in TDC time units |
peak_time | time at peak of the signal, in TDC time units |
sigma_peak_time | uncertainty on time at peak, in TDC time units |
peak_amplitude | amplitude of the signal at peak, in ADC units |
sigma_peak_amplitude | uncertainty on amplitude at peak |
hit_integral | total charge integrated under the hit signal |
hit_sigma_integral | uncertainty on the total hit charge |
summedADC | total ADC count in the region assigned to the hit |
multiplicity | number of hits in the region it was extracted from |
local_index | index of this hit in the region it was extracted from |
goodness_of_fit | quality parameter for the hit |
dof | degrees of freedom in the definition of the hit shape |
The information used from the wire are the channel ID and view; the signal type is obtained from geometry.
Definition at line 92 of file HitCreator.cxx.
recob::HitCreator::HitCreator | ( | recob::Wire const & | wire, |
geo::WireID const & | wireID, | ||
raw::TDCtick_t | start_tick, | ||
raw::TDCtick_t | end_tick, | ||
float | rms, | ||
float | peak_time, | ||
float | sigma_peak_time, | ||
float | peak_amplitude, | ||
float | sigma_peak_amplitude, | ||
float | hit_integral, | ||
float | hit_sigma_integral, | ||
short int | multiplicity, | ||
short int | local_index, | ||
float | goodness_of_fit, | ||
int | dof | ||
) |
Constructor: computes sum of ADC from wire.
wire | a pointer to a recob::Wire (for channel, view, signal type) |
wireID | ID of the wire the hit is on |
start_tick | first tick in the region the hit was extracted from |
end_tick | first tick after the region the hit was extracted from |
rms | RMS of the signal hit, in TDC time units |
peak_time | time at peak of the signal, in TDC time units |
sigma_peak_time | uncertainty on time at peak, in TDC time units |
peak_amplitude | amplitude of the signal at peak, in ADC units |
sigma_peak_amplitude | uncertainty on amplitude at peak |
hit_integral | total charge integrated under the hit signal |
hit_sigma_integral | uncertainty on the total hit charge |
multiplicity | number of hits in the region it was extracted from |
local_index | index of this hit in the region it was extracted from |
goodness_of_fit | quality parameter for the hit |
dof | degrees of freedom in the definition of the hit shape |
The information used from the wire are the channel ID, view; the signal type is obtained from geometry.
The sum of ADC counts is automatically computed over the whole range of the wire signal between start_tick
and end_tick
(the latter excluded).
Definition at line 134 of file HitCreator.cxx.
recob::HitCreator::HitCreator | ( | recob::Wire const & | wire, |
geo::WireID const & | wireID, | ||
float | rms, | ||
float | peak_time, | ||
float | sigma_peak_time, | ||
float | peak_amplitude, | ||
float | sigma_peak_amplitude, | ||
float | hit_integral, | ||
float | hit_sigma_integral, | ||
float | summedADC, | ||
short int | multiplicity, | ||
short int | local_index, | ||
float | goodness_of_fit, | ||
int | dof, | ||
RegionOfInterest_t const & | signal | ||
) |
Constructor: uses region of interest specified by index.
wire | a pointer to a recob::Wire (for channel, view, signal type) |
wireID | ID of the wire the hit is on |
rms | RMS of the signal hit, in TDC time units |
peak_time | time at peak of the signal, in TDC time units |
sigma_peak_time | uncertainty on time at peak, in TDC time units |
peak_amplitude | amplitude of the signal at peak, in ADC units |
sigma_peak_amplitude | uncertainty on amplitude at peak |
hit_integral | total charge integrated under the hit signal |
hit_sigma_integral | uncertainty on the total hit charge |
summedADC | total ADC count in the region assigned to the hit |
multiplicity | number of hits in the region it was extracted from |
local_index | index of this hit in the region it was extracted from |
goodness_of_fit | quality parameter for the hit |
dof | degrees of freedom in the definition of the hit shape |
signal | the signal region the hit was extracted from |
The information used from the wire are the channel ID, view and the region of interest; the signal type is obtained from geometry.
Signal start and end ticks are extracted from the region of interest.
Definition at line 167 of file HitCreator.cxx.
recob::HitCreator::HitCreator | ( | recob::Wire const & | wire, |
geo::WireID const & | wireID, | ||
float | rms, | ||
float | peak_time, | ||
float | sigma_peak_time, | ||
float | peak_amplitude, | ||
float | sigma_peak_amplitude, | ||
float | hit_integral, | ||
float | hit_sigma_integral, | ||
float | summedADC, | ||
short int | multiplicity, | ||
short int | local_index, | ||
float | goodness_of_fit, | ||
int | dof, | ||
size_t | iSignalRoI | ||
) |
Constructor: uses region of interest specified by index.
wire | a pointer to a recob::Wire (for channel, view, signal type) |
wireID | ID of the wire the hit is on |
rms | RMS of the signal hit, in TDC time units |
peak_time | time at peak of the signal, in TDC time units |
sigma_peak_time | uncertainty on time at peak, in TDC time units |
peak_amplitude | amplitude of the signal at peak, in ADC units |
sigma_peak_amplitude | uncertainty on amplitude at peak |
hit_integral | total charge integrated under the hit signal |
hit_sigma_integral | uncertainty on the total hit charge |
summedADC | total ADC count in the region assigned to the hit |
multiplicity | number of hits in the region it was extracted from |
local_index | index of this hit in the region it was extracted from |
goodness_of_fit | quality parameter for the hit |
dof | degrees of freedom in the definition of the hit shape |
iSignalRoI | index in the wire of the signal region the hit was extracted from |
The information used from the wire are the channel ID, view and the region of interest; the signal type is obtained from geometry.
Signal start and end ticks are extracted from the region of interest.
Definition at line 194 of file HitCreator.cxx.
recob::HitCreator::HitCreator | ( | recob::Hit const & | from | ) |
Constructor: copies from an existing hit.
from | the original hit |
Definition at line 219 of file HitCreator.cxx.
recob::HitCreator::HitCreator | ( | recob::Hit const & | from, |
geo::WireID const & | wireID | ||
) |
Constructor: copies from an existing hit, changing wire ID.
from | the original hit |
wireID | ID of the new wire the hit is on |
Definition at line 222 of file HitCreator.cxx.
|
inline |
Returns the constructed wire.
Despite the name, no copy happens in this function. Copy takes place in the caller code as proper; for example:
Definition at line 361 of file HitCreator.h.
|
inline |
Prepares the constructed hit to be moved away.
Despite the name, no move happens in this function. Move takes place in the caller code as proper; for example:
Definition at line 343 of file HitCreator.h.
|
protected |
Local instance of the hit being constructed.
Definition at line 365 of file HitCreator.h.