ATTPCROOT  0.3.0-alpha
A ROOT-based framework for analyzing data from active target detectors
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
AtFilterSubtraction Class Reference

#include <AtFilterSubtraction.h>

Inheritance diagram for AtFilterSubtraction:
Inheritance graph
[legend]
Collaboration diagram for AtFilterSubtraction:
Collaboration graph
[legend]

Public Member Functions

 AtFilterSubtraction (AtMapPtr map, Int_t numCoBos=10, Int_t numAget=4)
 
void SetThreshold (Double_t thresh)
 
void SetIsGood (Bool_t val)
 Set if we should mark the event bad if we cannot find every AGET to do subtraction. More...
 
Double_t GetThreshold () const
 
virtual void Init () override
 Called at the init stage of the AtFilterTask. More...
 
virtual void InitEvent (AtRawEvent *event) override
 Called once for each event at the start of the Exec phase. More...
 
virtual void Filter (AtPad *pad, AtPadReference *padReference) override
 Called to filter each pad. More...
 
virtual bool IsGoodEvent () override
 Called at the end of an event. Returns if filtering was successful. More...
 
- Public Member Functions inherited from AtFilter
virtual ~AtFilter ()=default
 
virtual AtRawEventConstructOutputEvent (TClonesArray *outputEventArray, AtRawEvent *inputEvent)
 Construct output event from input event array. More...
 

Protected Member Functions

void Clear ()
 
void AddChToBaseline (const AtPadReference &ref, const AtPad &pad)
 
void AverageBaseline ()
 
void processPad (const AtPadReference &ref, const AtPad &pad)
 
virtual bool isValidPad (const AtPad &pad)
 
virtual int getAsad (const AtPadReference &ref)
 

Protected Attributes

const Int_t fNumberCoBo
 
Int_t fEventNumber {-1}
 
Double_t fThreshold = 0
 
AtMapPtr fMapping
 
Int_t fNumberMissedAsads {}
 
Bool_t fSetIsGood {false}
 
vecDoubleCoBo fBaseline
 
vecIntCoBo fRawBaseline
 
vecAgetCount fAgetCount
 

Detailed Description

Filter that will subtract the average of every ch0 aget in a AsAd from all channels in an AsAd. Adam Anthony 7/16/21

Definition at line 29 of file AtFilterSubtraction.h.

Constructor & Destructor Documentation

◆ AtFilterSubtraction()

AtFilterSubtraction::AtFilterSubtraction ( AtMapPtr  map,
Int_t  numCoBos = 10,
Int_t  numAget = 4 
)

Definition at line 12 of file AtFilterSubtraction.cxx.

Member Function Documentation

◆ AddChToBaseline()

void AtFilterSubtraction::AddChToBaseline ( const AtPadReference ref,
const AtPad pad 
)
protected

Definition at line 75 of file AtFilterSubtraction.cxx.

◆ AverageBaseline()

void AtFilterSubtraction::AverageBaseline ( )
protected

Definition at line 85 of file AtFilterSubtraction.cxx.

◆ Clear()

void AtFilterSubtraction::Clear ( )
protected

Definition at line 26 of file AtFilterSubtraction.cxx.

◆ Filter()

void AtFilterSubtraction::Filter ( AtPad pad,
AtPadReference padReference 
)
overridevirtual

Called to filter each pad.

Optional padRef currently only used by SCA filter (10/20/22).

Parameters
[in]padPad to filter.
[in[padRefernece optional parameter only needed when when filtering FPN channels.

Implements AtFilter.

Definition at line 100 of file AtFilterSubtraction.cxx.

◆ getAsad()

int AtFilterSubtraction::getAsad ( const AtPadReference ref)
protectedvirtual

Reimplemented in AtFilterFPN.

Definition at line 65 of file AtFilterSubtraction.cxx.

◆ GetThreshold()

Double_t AtFilterSubtraction::GetThreshold ( ) const
inline

Definition at line 59 of file AtFilterSubtraction.h.

◆ Init()

void AtFilterSubtraction::Init ( )
overridevirtual

Called at the init stage of the AtFilterTask.

Implements AtFilter.

Definition at line 117 of file AtFilterSubtraction.cxx.

◆ InitEvent()

void AtFilterSubtraction::InitEvent ( AtRawEvent inputEvent)
overridevirtual

Called once for each event at the start of the Exec phase.

Implements AtFilter.

Reimplemented in AtFilterFPN.

Definition at line 41 of file AtFilterSubtraction.cxx.

◆ IsGoodEvent()

bool AtFilterSubtraction::IsGoodEvent ( )
overridevirtual

Called at the end of an event. Returns if filtering was successful.

Implements AtFilter.

Definition at line 119 of file AtFilterSubtraction.cxx.

◆ isValidPad()

bool AtFilterSubtraction::isValidPad ( const AtPad pad)
protectedvirtual

Should this pad be added to the average to subtract

Reimplemented in AtFilterFPN.

Definition at line 53 of file AtFilterSubtraction.cxx.

◆ processPad()

void AtFilterSubtraction::processPad ( const AtPadReference ref,
const AtPad pad 
)
protected

Definition at line 69 of file AtFilterSubtraction.cxx.

◆ SetIsGood()

void AtFilterSubtraction::SetIsGood ( Bool_t  val)
inline

Set if we should mark the event bad if we cannot find every AGET to do subtraction.

Definition at line 58 of file AtFilterSubtraction.h.

◆ SetThreshold()

void AtFilterSubtraction::SetThreshold ( Double_t  thresh)
inline

Definition at line 56 of file AtFilterSubtraction.h.

Member Data Documentation

◆ fAgetCount

vecAgetCount AtFilterSubtraction::fAgetCount
protected

Definition at line 43 of file AtFilterSubtraction.h.

◆ fBaseline

vecDoubleCoBo AtFilterSubtraction::fBaseline
protected

Definition at line 39 of file AtFilterSubtraction.h.

◆ fEventNumber

Int_t AtFilterSubtraction::fEventNumber {-1}
protected

Definition at line 32 of file AtFilterSubtraction.h.

◆ fMapping

AtMapPtr AtFilterSubtraction::fMapping
protected

Definition at line 34 of file AtFilterSubtraction.h.

◆ fNumberCoBo

const Int_t AtFilterSubtraction::fNumberCoBo
protected

Definition at line 31 of file AtFilterSubtraction.h.

◆ fNumberMissedAsads

Int_t AtFilterSubtraction::fNumberMissedAsads {}
protected

Definition at line 35 of file AtFilterSubtraction.h.

◆ fRawBaseline

vecIntCoBo AtFilterSubtraction::fRawBaseline
protected

Definition at line 41 of file AtFilterSubtraction.h.

◆ fSetIsGood

Bool_t AtFilterSubtraction::fSetIsGood {false}
protected

Definition at line 36 of file AtFilterSubtraction.h.

◆ fThreshold

Double_t AtFilterSubtraction::fThreshold = 0
protected

Definition at line 33 of file AtFilterSubtraction.h.


The documentation for this class was generated from the following files: