GET library
|
#include <GETChannel.hh>
Public Member Functions | |
Constructors, affectation, destructor | |
GETChannel (u_int n=0, double dt=0.01L) | |
virtual | ~GETChannel () |
GET configuration | |
virtual int | ResetConfig () |
const GETCfgChannel * | GetConfig () const |
GETCfgChannel * | GetConfig () |
bool | IsFPNChannel () const |
bool | IsSignalChannel () const |
Initialization functions | |
virtual void | Reset () |
virtual void | Init (u_int n, double dt) |
virtual void | SetTimeStep (double dt) |
virtual void | ClearEvent () |
virtual void | ValidDataSet () |
virtual void | ValidSimulSet () |
bool | IsModeData () const |
bool | IsModeSimul () const |
GET system core objects functions | |
int | GetSignalId () const |
virtual string | GetObjectId () const |
virtual u_int | GetChannelCount () const |
virtual u_int | GetChildrenNumber () const |
virtual const GETObject * | GetChild (u_int i) const |
virtual GETObject * | GetChild (u_int i) |
u_short | GetLastCell () const |
u_int | GetSaturationCount () const |
virtual u_int | GetReadoutMultiplicity (bool fpn=true) const |
virtual double | GetSignalSum (u_short info=GET::signalOut) |
Channel samples (Test, Output, Reconstructed) function | |
bool | GetReadoutFlag () const |
u_int | GetReadoutCount () const |
GETSample & | TstSample () |
GETSample & | OutSample () |
GETSample & | RecSample () |
virtual int | ProcessData (bool in_noise=true) |
virtual int | ProcessOutFromTst (bool in_noise=true, bool out_noise=true) |
virtual int | ProcessRecFromOut (bool out_corr=true) |
virtual int | ProcessOutputCorrection () |
virtual int | ApplyOutputNoise (GETSample &out_sample) |
virtual int | ApplyOutputCorrection (GETSample &cor_sample) |
ROOT related functions | |
ClassDef (GETChannel, 0) | |
Public Member Functions inherited from GETObject | |
GETObject () | |
virtual | ~GETObject () |
int | GetId () const |
virtual string | GetFullId () const |
virtual u_int | GetSignalChannelCount () const |
virtual u_int | GetTotalChannelCount () const |
virtual GETChannel * | GetSignalChannel (u_int n) |
virtual GETChannel * | GetTotalChannel (u_int n) |
virtual GETChannel * | GetChannel (u_int n) |
const GETObject * | GetParent () const |
GETObject * | GetParent () |
u_int | GetSampleDim () |
double | GetTimeStep () |
virtual void | InitLocalData (u_int n, double dt) |
virtual void | SetResponse (GETResponse *ptr, bool recur=true, bool fpn=false) |
virtual void | SetResponse (GETResponse &obj, bool recur=true, bool fpn=false) |
virtual void | SetFilter (GETFilter *ptr, bool recur=true, bool fpn=false) |
virtual void | SetFilter (GETFilter &obj, bool recur=true, bool fpn=false) |
virtual void | SetNoiseIn (GETSignalModifier *ptr, bool recur=true, bool fpn=false) |
virtual void | SetNoiseIn (GETSignalModifier &obj, bool recur=true, bool fpn=false) |
virtual void | SetNoiseOut (GETSignalModifier *ptr, bool recur=true, bool fpn=false) |
virtual void | SetNoiseOut (GETSignalModifier &obj, bool recur=true, bool fpn=false) |
virtual void | SetOutputCorrection (GETProcess *ptr, bool recur=true, bool fpn=false) |
virtual void | SetOutputCorrection (GETProcess &obj, bool recur=true, bool fpn=false) |
virtual void | RemoveOutputCorrection () |
virtual void | SetOutputCorrectionList (bool warn=true) |
virtual void | AddOutputCorrection (GETProcess *ptr, bool recur=true, bool fpn=false) |
virtual void | AddOutputCorrection (GETProcess &obj, bool recur=true, bool fpn=false) |
GETResponse * | GetResponse (bool force=true) |
GETFilter * | GetFilter (bool force=true) |
GETSignalModifier * | GetNoiseIn (bool force=true) |
GETSignalModifier * | GetNoiseOut (bool force=true) |
GETProcess * | GetOutputCorrection (bool force=true) |
ClassDef (GETObject, 0) | |
Protected Attributes | |
GETCfgChannel * | config |
Configuration data. | |
u_short | data_mode |
Whether data comes from an experimental file or from simulation. | |
bool | is_read |
Flag indicating whether the channel was read (from exp. raw data) | |
u_int | read_count |
Number of data read for the channel (from exp. raw data) | |
u_int | satur_count |
Number of data over saturation threshold. | |
int | sig_id |
Signal channel identifier (0-63 for signal, 64-67 for FPN) | |
GETSample | signal_out |
Output signal from AGET. | |
GETSample | signal_rec |
Reconstructed signal (filtering and deconvolution) | |
GETSample | signal_tst |
Test (input) signal (for simulation) | |
Protected Attributes inherited from GETObject | |
GETProcessLink | filter |
Signal processing filter. | |
int | id |
Object identifier number (set by the parent, in filiation) | |
GETProcessLink | noise_in |
Simulation input noise generator. | |
GETProcessLink | noise_out |
Simulation output noise generator. | |
GETProcessLink | output_corr |
Output signal correction before reconstruction of input. | |
GETObject * | parent |
Parent AGet chip. | |
GETProcessLink | response |
Signal response function. | |
Private Member Functions | |
GObject (GETChannel) | |
Friends | |
class | GETAGet |
class | GETCfgChannel |
class | GETSystem |
This class defines the mechanism for a single channel processing. It can be used in 2 ways:
The GETChannel defines 3 signal samples objects:
GETChannel::GETChannel | ( | u_int | n = 0 , |
double | dt = 0.01L |
||
) |
Base constructor.
n | sampling size of the channels |
dt | sampling period (us) |
References config, data_mode, Init(), GET::modeData, and sig_id.
|
virtual |
Destructor.
References config.
|
virtual |
Function that applies the output correction for the channel and store the result in the argument sample. The function returns a non-0 value if an error occured (if the required signals are not defined).
cor_sample | sample where result is stored |
References GETObject::GetFullId(), GETObject::GetOutputCorrection(), GETProcessLink::IsDefined(), GETObject::output_corr, GETProcess::ProcessSample(), and signal_out.
Referenced by ProcessOutputCorrection(), and ProcessRecFromOut().
|
virtual |
Function that applies the output noise for the channel and store the result in the argument sample. The function returns a non-0 value if an error occured (if the required signals are not defined).
out_sample | sample where result is stored |
References GETObject::GetFullId(), GETObject::GetNoiseOut(), GETProcessLink::IsDefined(), GETObject::noise_out, GETSignalModifier::ProcessSample(), and signal_out.
GETChannel::ClassDef | ( | GETChannel | , |
0 | |||
) |
for use within ROOT.
|
virtual |
Clears all input/outout signals from each channel of each AGET chip.
References data_mode, is_read, GET::modeUndefined, read_count, satur_count, signal_out, signal_rec, and signal_tst.
|
inlinevirtual |
Return the total number of channels under the object.
Reimplemented from GETObject.
|
inlinevirtual |
|
inlinevirtual |
|
inlinevirtual |
|
inline |
|
inline |
u_short GETChannel::GetLastCell | ( | ) | const |
Return the last cell read from parent AGet if defined (otherwise, the function returns 0.
References GETObject::parent.
Referenced by GETPhaseCorrection::ProcessSample().
|
inlinevirtual |
Return the object string identifier.
Implements GETObject.
|
inline |
Return the number of data that have been read for the channel.
References read_count.
Referenced by GETActarEventReader::AnalysisEvent(), and GETSystemAnalyser::ProcessDataNumberCheck().
|
inline |
Get the readout flag indicating if the channel some data was read.
References read_count.
Referenced by GETActarEventReader::AnalysisEvent(), and GETSystemAnalyser::CumulChannelsSummaryHisto().
|
virtual |
Return the number of read channels: for the channel, it can be 0 or 1.
fpn | indicates if the FPN channels should be counted |
Reimplemented from GETObject.
References IsSignalChannel(), and read_count.
|
inline |
Return the number of data over saturation threshold (by readout function of the GET system.
References satur_count.
Referenced by GETActarEventReader::HistoClickedSlot(), GETActarEventReader::HistoEventSlot(), and GETSystem::IsChannelSaturated().
|
inline |
Return the signal channel index (-1 if undefined).
References sig_id.
|
virtual |
Return the sum of the signal channels (FPN are not included.
info | samples used for signal summing: GET::signalOut (default) GET::signalTst or GET::signalRec |
Reimplemented from GETObject.
References OutSample(), RecSample(), GET::signalRec, GET::signalTst, and TstSample().
Referenced by GETAGet::GetSignalSum().
|
private |
Macro from GCpp library that defines the following functions:
|
virtual |
Initialisation of all individual channels.
n | sampling size of the channels |
dt | sampling time step |
References GETObject::InitLocalData(), read_count, sig_id, signal_out, signal_rec, and signal_tst.
Referenced by GETChannel(), and GETAGet::Init().
bool GETChannel::IsFPNChannel | ( | ) | const |
Function returning true for a FPN channel, false for a signal channel.
References GETAGet::GetFPNIndex(), and GETObject::GetId().
Referenced by GETSystemAnalyser::CalcChannelOutput(), GETSystemAnalyser::ComputeAmplitudeData(), GETObject::GetSignalChannel(), IsSignalChannel(), and GETActarEventReader::PresetAnalysis().
|
inline |
Return true if the channel is in data mode: output sample is defined.
References data_mode, and GET::modeData.
|
inline |
Return true if the channel is in data mode: test input sample is defined.
References data_mode, and GET::modeSimul.
|
inline |
Function returning true for a signal channel, false for a FPN channel.
References IsFPNChannel().
Referenced by GETActarTpcAnalyser::ConfigCommand(), GETSystemAnalyser::CumulChannelsSummaryHisto(), GETSystemAnalyser::FillChannelsSummaryHisto(), GETSystemAnalyser::FillFullEventHisto(), GETSystem::GetMaximumChannel(), GetReadoutMultiplicity(), GETSystem::SetCalibProcess(), GETLookupTable::SetDefaultTable(), and GETLookupTable::SetHVpad64Table().
|
inline |
Return the (reference to the) output sample (GET output data, from experiment or after simulation input processing).
References signal_out.
Referenced by GETActarEventReader::AnalysisEvent(), GETActarTpcAnalyser::ApplyOffTrackCorrection(), GETSystemAnalyser::CalcChannelMaxima(), GETSystemAnalyser::CalcChannelOutput(), GETActarTpcAnalyser::ComputeSumInt(), GETSystemAnalyser::CreateAllChannelsHisto(), GETSystemAnalyser::CreateFullEventHisto(), GETActarTpcAnalyser::CreateInTrackMeanHisto(), GETActarTpcAnalyser::CreateOffTrackMeanHisto(), GETSystemAnalyser::CumulChannelsSummaryHisto(), GETActarEventReader::DefinePadSpectrum(), GETActarTpcAnalyser::Export3D_POV(), GETActarTpcAnalyser::ExportPads_POV(), GETRCoBo::ExtractCoBoFrame(), GETSystemAnalyser::FillAllChannelsHisto(), GETActarTpcAnalyser::FillAutoHistograms(), GETSystemAnalyser::FillChannelsSummaryHisto(), GETSystemAnalyser::FillFullEventHisto(), GETActarTpcAnalyser::FillHistogram3D(), GETActarTpcAnalyser::FillHistogramXTmax(), GETActarTpcAnalyser::FillHistogramYTmax(), GETActarTpcAnalyser::FillPadHistogram(), GETSystem::GetMaximumChannel(), GETActarTpc::GetSignalBoundaries(), GetSignalSum(), GETSystem::OutputCorrectFPN(), GETSystem::ProcessCoBoFrameData(), GETSystemAnalyser::ProcessDataContinuityCheck(), GETSystemAnalyser::ProcessFluctuationsAnalysis(), GETSystemAnalyser::ProcessNoiseAnalysis(), GETActarTpcAnalyser::ProcessOffTrackAnalysis(), GETSignalModifier::ProcessSample(), GETResponse::ProcessSample(), GETProcessSerie::ProcessSample(), GETFilter::ProcessSample(), GETRCoBo::ReadEvent(), GETHitMaskXY::UpdateMask(), GETHitMask::UpdateMask(), and GETSystem::ZeroSuppression().
|
virtual |
Compute samples for the channel: for a simulated input (test channel input sample), the output is computed from response function (see ProcessOutFromTst function), and for simulated or experimental data, the reconstructed signal sample is computed (see ProcessRecFromOut function). The function returns a non-0 value if an error occured (if the required signals are not defined).
in_noise | indicate whether the input sample is modified by the input noise process (in such case, the function should not be called several times for the same channel - for the same event - since the noise would be added several times) |
Reimplemented from GETObject.
References data_mode, GETObject::GetFullId(), GET::modeSimul, GET::modeUndefined, ProcessOutFromTst(), and ProcessRecFromOut().
|
virtual |
Function that computes the output signal sample from the test (simulation) input. If the channel defines an input and/or an output noise generator, the corresponding noise is included in the processing.
In case of an input noise, after the function call, the input sample is modified or not due to this noise, according to the in_noise argument.
The function returns a non-0 value if an error occured (if the required signals are not defined).
in_noise | indicate whether the input sample is modified by the input noise process (in such case, the function should not be called several times for the same channel - for the same event - since the noise would be added several times) |
out_noise | indicate whether the output noise should be applied (this is defined to allow to separately apply the output noise in processes decomposition) |
Reimplemented from GETObject.
References GETObject::GetFullId(), GETObject::GetNoiseIn(), GETObject::GetNoiseOut(), GETObject::GetResponse(), GETProcessLink::IsDefined(), GETObject::noise_in, GETObject::noise_out, GETSignalModifier::ProcessSample(), GETResponse::ProcessSample(), GETObject::response, signal_out, signal_tst, and GET::signalTst.
Referenced by ProcessData().
|
virtual |
Function that applies the ouput correction to the channel data. If the channel is defined as experimental data, the correction is applied only if the channel was read.
Reimplemented from GETObject.
References ApplyOutputCorrection(), data_mode, GETObject::GetFullId(), is_read, GETProcessLink::IsDefined(), GET::modeSimul, GETObject::output_corr, and signal_out.
|
virtual |
Function that computes the reconstructed signal sample from the output (AGet response). If the channel defines processing filter, the output is filtered before the deconvolution of the channel output with AGet response function. The function returns a non-0 value if an error occured (if the required signals are not defined).
out_corr | whether the output correction should apply (if it has not been applied yet) |
Reimplemented from GETObject.
References ApplyOutputCorrection(), GETObject::filter, GETObject::GetFilter(), GETObject::GetFullId(), GETObject::GetResponse(), GETProcessLink::IsDefined(), GETObject::output_corr, GETResponse::ProcessSample(), GETFilter::ProcessSample(), signal_out, and signal_rec.
Referenced by ProcessData().
|
inline |
Return the (reference to the) reconstructed sample (after optional filtering and deconvolution from response function).
References signal_rec.
Referenced by GETActarEventReader::AnalysisEvent(), GETSystemAnalyser::CalcChannelMaxima(), GETSystemAnalyser::CalcChannelOutput(), GETActarTpcAnalyser::ComputeSumInt(), GETSystemAnalyser::CumulChannelsSummaryHisto(), GETActarEventReader::DefinePadSpectrum(), GETActarTpcAnalyser::Export3D_POV(), GETActarTpcAnalyser::ExportPads_POV(), GETSystemAnalyser::FillAllChannelsHisto(), GETActarTpcAnalyser::FillAutoHistograms(), GETSystemAnalyser::FillChannelsSummaryHisto(), GETSystemAnalyser::FillFullEventHisto(), GETActarTpcAnalyser::FillHistogram3D(), GETActarTpcAnalyser::FillHistogramXTmax(), GETActarTpcAnalyser::FillHistogramYTmax(), GETActarTpcAnalyser::FillPadHistogram(), GETSystem::GetMaximumChannel(), GetSignalSum(), GETHitMaskXY::UpdateMask(), and GETHitMask::UpdateMask().
|
virtual |
Function resetting the channel. It currently does nothing.
References read_count, and sig_id.
|
virtual |
Removes the configuration architecture.
References config.
|
virtual |
Set the time step for the samples of the channel. The minimum value is 0.01 us.
dt | new time step (in us) |
Reimplemented from GETObject.
References signal_out, signal_rec, and signal_tst.
|
inline |
Return the (reference to the) test sample (GET input, from simulation).
References signal_tst.
Referenced by GETActarEventReader::AnalysisEvent(), GETSystemAnalyser::CalcChannelMaxima(), GETSystemAnalyser::CalcChannelOutput(), GETActarTpcAnalyser::ComputeSumInt(), GETSystemAnalyser::CumulChannelsSummaryHisto(), GETActarEventReader::DefinePadSpectrum(), GETActarTpcAnalyser::Export3D_POV(), GETActarTpcAnalyser::ExportPads_POV(), GETSystemAnalyser::FillAllChannelsHisto(), GETActarTpcAnalyser::FillAutoHistograms(), GETSystemAnalyser::FillChannelsSummaryHisto(), GETSystemAnalyser::FillFullEventHisto(), GETActarTpcAnalyser::FillHistogram3D(), GETActarTpcAnalyser::FillHistogramXTmax(), GETActarTpcAnalyser::FillHistogramYTmax(), GETActarTpcAnalyser::FillPadHistogram(), GETSystem::GetMaximumChannel(), GetSignalSum(), GETSignalModifier::ProcessSample(), GETResponse::ProcessSample(), GETProcessSerie::ProcessSample(), GETHitMaskXY::UpdateMask(), and GETHitMask::UpdateMask().
|
virtual |
Function setting output sample (from experimental file) as valid and setting channel data mode to GET::modeData.
Reimplemented from GETObject.
References data_mode, GET::modeData, signal_out, signal_rec, and signal_tst.
|
virtual |
Function setting test (input) sample (from simulation) as valid and setting channel data mode to GET::modeSimul.
Reimplemented from GETObject.
References data_mode, GET::modeSimul, signal_out, signal_rec, and signal_tst.