Pixie16 Analysis Software Suite
Analysis code for processing of .ldf files
|
correlate decays with previous implants More...
#include <Correlator.hpp>
Public Types | |
enum | EConditions { INVALID_LOCATION = 4, VALID_IMPLANT = 12, VALID_DECAY = 16, BACK_TO_BACK_IMPLANT = 32, DECAY_TOO_LATE = 48, IMPLANT_TOO_SOON = 52, UNKNOWN_CONDITION = 100 } |
correlator condition based on the given events | |
Public Member Functions | |
Correlator () | |
virtual | ~Correlator () |
void | DeclarePlots (void) |
void | Init (RawEvent &rawev) |
void | Correlate (EventInfo &event, unsigned int fch, unsigned int bch) |
void | CorrelateAll (EventInfo &event) |
Correlates all positions. More... | |
void | CorrelateAllX (EventInfo &event, unsigned int bch) |
void | CorrelateAllY (EventInfo &event, unsigned int fch) |
void | PrintDecayList (unsigned int fch, unsigned int bch) const |
double | GetDecayTime (void) const |
double | GetDecayTime (int fch, int bch) const |
double | GetImplantTime (void) const |
double | GetImplantTime (int fch, int bch) const |
void | Flag (int fch, int bch) |
bool | IsFlagged (int fch, int bch) |
EConditions | GetCondition (void) const |
Private Member Functions | |
virtual void | plot (int dammId, double val1, double val2=-1, double val3=-1, const char *name="h") |
plots data into a histogram with provided DAMM ID More... | |
virtual void | DeclareHistogram1D (int dammId, int xSize, const char *title) |
Declares a 1D histogram calls the C++ wrapper for DAMM. More... | |
virtual void | DeclareHistogram2D (int dammId, int xSize, int ySize, const char *title) |
Declares a 2D histogram calls the C++ wrapper for DAMM. More... | |
Private Attributes | |
Plots | histo |
Instance of the Plots class. | |
EventInfo * | lastImplant |
last implant processed by correlator | |
EventInfo * | lastDecay |
last decay procssed by correlator | |
EConditions | condition |
condition for last processed event | |
CorrelationList | decaylist [arraySize][arraySize] |
list of event data for a particular pixel since implant | |
Static Private Attributes | |
static const size_t | arraySize = 40 |
static const double | minImpTime |
static const double | corrTime |
static const double | fastTime |
correlate decays with previous implants
The class controls the correlations of decays with previous implants. There are arrays of size MAX_STRIP x MAX_STRIP that store implants and decays. When an event has been identified as either an implant or decay, its information is placed in the appropriate array based on its pixel location. If a decay was identified, it is correlated with a previous implant. The correlator checks to make sure that the time between implants is sufficiently long and that the correlation time has not been exceeded before correlating an implant with a decay.
Correlator::Correlator | ( | ) |
Default Constructor
|
virtual |
Default Destructor
void Correlator::Correlate | ( | EventInfo & | event, |
unsigned int | fch, | ||
unsigned int | bch | ||
) |
Correlate two locations in the event
[in] | event | : the event to use to correlate |
[in] | fch | : the first channel to correlate |
[in] | bch | : the second channel to correlate |
void Correlator::CorrelateAll | ( | EventInfo & | event | ) |
Correlates all positions.
This correlates an event with all positions in the setup. This is useful for cases where the event is interesting but can not be assigned to a particular implant location as in the case of external gamma-ray detectors
[in] | event | : the even to correlate with |
void Correlator::CorrelateAllX | ( | EventInfo & | event, |
unsigned int | bch | ||
) |
Correlates all X positions in the event
[in] | event | : the event to correlate with |
[in] | bch | : the locations to correlate with |
void Correlator::CorrelateAllY | ( | EventInfo & | event, |
unsigned int | fch | ||
) |
Correlates all Y positions in the event
[in] | event | : the even to correlate with |
[in] | fch | : the locations to correlate with |
|
inlineprivatevirtual |
Declares a 1D histogram calls the C++ wrapper for DAMM.
[in] | dammId | : The histogram number to define |
[in] | xSize | : The range of the x-axis |
[in] | title | : The title for the histogram |
|
inlineprivatevirtual |
Declares a 2D histogram calls the C++ wrapper for DAMM.
[in] | dammId | : The histogram number to define |
[in] | xSize | : The range of the x-axis |
[in] | ySize | : The range of the y-axis |
[in] | title | : The title of the histogram |
void Correlator::DeclarePlots | ( | void | ) |
Declare plots for the correlator
void Correlator::Flag | ( | int | fch, |
int | bch | ||
) |
Set the flag for the two locations
[in] | fch | : first channel that we'll set |
[in] | bch | : the second channel to set |
|
inline |
double Correlator::GetDecayTime | ( | void | ) | const |
double Correlator::GetDecayTime | ( | int | fch, |
int | bch | ||
) | const |
[in] | fch | : the first channel to look for |
[in] | bch | : the second channel to look for |
double Correlator::GetImplantTime | ( | void | ) | const |
double Correlator::GetImplantTime | ( | int | fch, |
int | bch | ||
) | const |
[in] | fch | : the first channel to look for |
[in] | bch | : the second channel to look for |
|
inline |
Initialize the correlator - Does nothing
[in] | rawev | : the raw even for initialization |
bool Correlator::IsFlagged | ( | int | fch, |
int | bch | ||
) |
Check if the two channels that we have are flagged
[in] | fch | : the first channel to check |
[in] | bch | : the second channel to check |
|
inlineprivatevirtual |
plots data into a histogram with provided DAMM ID
[in] | dammId | : the dammID to plot into |
[in] | val1 | : the x value |
[in] | val2 | : the y value |
[in] | val3 | : the z value |
[in] | name | : the name of the histogram |
void Correlator::PrintDecayList | ( | unsigned int | fch, |
unsigned int | bch | ||
) | const |
Print the decay list
[in] | fch | : the first location to print |
[in] | bch | : the second location to print |
|
staticprivate |
Size of the 2D array to hold the decay lists
|
staticprivate |
The maximum amount of time allowed between a decay and its previous implant for a correlation between the two to occur in clock ticks
|
staticprivate |
Times shorter than this are output as a fast decay
|
staticprivate |
The minimum amount of time that must pass before an implant will be considered for correlation in clock ticks