All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Protected Attributes | Private Member Functions | Private Attributes | Friends | List of all members
flashmatch::BaseFlashMatch Class Referenceabstract

#include <BaseFlashMatch.h>

Inheritance diagram for flashmatch::BaseFlashMatch:
flashmatch::BaseAlgorithm flashmatch::LoggerFeature flashmatch::CommonAmps flashmatch::QLLMatch flashmatch::QWeightPoint

Public Member Functions

 BaseFlashMatch (const std::string name="noname")
 Default constructor. More...
 
virtual ~BaseFlashMatch ()
 Default destructor. More...
 
virtual FlashMatch_t Match (const QCluster_t &, const Flash_t &)=0
 
Flash_t GetEstimate (const QCluster_t &) const
 Method to call flash hypothesis. More...
 
void FillEstimate (const QCluster_t &, Flash_t &) const
 Method to simply fill provided reference of flashmatch::Flash_t. More...
 
virtual void SetTPCCryo (int tpc, int cryo)=0
 Sets the TPC and Cryo numbers. More...
 
- Public Member Functions inherited from flashmatch::BaseAlgorithm
 BaseAlgorithm (const Algorithm_t type, const std::string name)
 Default constructor. More...
 
 ~BaseAlgorithm ()
 Default destructor. More...
 
void Configure (const Config_t &pset)
 Function to accept configuration. More...
 
Algorithm_t AlgorithmType () const
 Algorithm type. More...
 
const std::string & AlgorithmName () const
 Algorithm name. More...
 
- Public Member Functions inherited from flashmatch::LoggerFeature
 LoggerFeature (const std::string logger_name="LoggerFeature")
 Default constructor. More...
 
 LoggerFeature (const LoggerFeature &original)
 Default copy constructor. More...
 
virtual ~LoggerFeature ()
 Default destructor. More...
 
const flashmatch::loggerlogger () const
 Logger getter. More...
 
void set_verbosity (::flashmatch::msg::Level_t level)
 Verbosity level. More...
 
const std::string & name () const
 Name getter, defined in a logger instance attribute. More...
 

Protected Attributes

int _tpc = 0
 The TPC number to use. More...
 
int _cryo = 0
 The Cryostat number to use. More...
 

Private Member Functions

void SetFlashHypothesis (flashmatch::BaseFlashHypothesis *)
 

Private Attributes

flashmatch::BaseFlashHypothesis_flash_hypothesis
 

Friends

class FlashMatchManager
 

Additional Inherited Members

- Protected Member Functions inherited from flashmatch::BaseAlgorithm
virtual void _Configure_ (const Config_t &pset)=0
 

Detailed Description

Algorithm base class for matching flashmatch::QCluster_t (TPC object) and
flashmatch::Flash_t (flash). It creates flashmatch::FlashMatch_t which contains
matching infomration.

Definition at line 29 of file BaseFlashMatch.h.

Constructor & Destructor Documentation

flashmatch::BaseFlashMatch::BaseFlashMatch ( const std::string  name = "noname")
inline

Default constructor.

Definition at line 35 of file BaseFlashMatch.h.

36  {}
Algorithm type to match flash hypothesis and reconstructed flash.
BaseAlgorithm(const Algorithm_t type, const std::string name)
Default constructor.
const std::string & name() const
Name getter, defined in a logger instance attribute.
Definition: LoggerFeature.h:51
virtual flashmatch::BaseFlashMatch::~BaseFlashMatch ( )
inlinevirtual

Default destructor.

Definition at line 39 of file BaseFlashMatch.h.

39 {}

Member Function Documentation

void flashmatch::BaseFlashMatch::FillEstimate ( const QCluster_t tpc,
Flash_t opdet 
) const

Method to simply fill provided reference of flashmatch::Flash_t.

Definition at line 13 of file BaseFlashMatch.cxx.

14  {
15  _flash_hypothesis->FillEstimate(tpc,opdet);
16  }
virtual void FillEstimate(const QCluster_t &, Flash_t &) const =0
Method to simply fill provided reference of flashmatch::Flash_t.
flashmatch::BaseFlashHypothesis * _flash_hypothesis
Flash_t flashmatch::BaseFlashMatch::GetEstimate ( const QCluster_t tpc) const

Method to call flash hypothesis.

Definition at line 8 of file BaseFlashMatch.cxx.

9  {
10  return _flash_hypothesis->GetEstimate(tpc);
11  }
flashmatch::BaseFlashHypothesis * _flash_hypothesis
Flash_t GetEstimate(const QCluster_t &) const
Method to create flashmatch::Flash_t object and return.
virtual FlashMatch_t flashmatch::BaseFlashMatch::Match ( const QCluster_t ,
const Flash_t  
)
pure virtual

CORE FUNCTION: takes in flashmatch::QCluster_t (TPC object) and flashmatch::Flash_t (flash)
and inspect if two are consistent (i.t. matched) or not. Returns flashmatch::FlashMatch_t
which represents the compatibility of two inputs. In particular the algorithm needs to
set the "score" and "QPoint_t" of the return object. The former represents the goodness
of a match with a value larger than 0. Negative value is interpreted as no match.
The latter represents the matched TPC 3D point. The "tpc_id and "flash_id" of the return
object is set by flashmatch::FlashMatchManager, the caller of the algorithm, as it manages
the overall collection of user input flash and TPC objects.

Note it is flashmatch::FlashMatchManager configuration option to allow an assignment of the
same flash to multiple TPC object or not. If not allowed, a match with a higher "score"
in the return object is chosen.

Implemented in flashmatch::QLLMatch, flashmatch::QWeightPoint, and flashmatch::CommonAmps.

void flashmatch::BaseFlashMatch::SetFlashHypothesis ( flashmatch::BaseFlashHypothesis alg)
private

Definition at line 18 of file BaseFlashMatch.cxx.

19  {
20  _flash_hypothesis = alg;
21  }
flashmatch::BaseFlashHypothesis * _flash_hypothesis
virtual void flashmatch::BaseFlashMatch::SetTPCCryo ( int  tpc,
int  cryo 
)
pure virtual

Sets the TPC and Cryo numbers.

Implemented in flashmatch::QLLMatch, and flashmatch::QWeightPoint.

Friends And Related Function Documentation

friend class FlashMatchManager
friend

Definition at line 30 of file BaseFlashMatch.h.

Member Data Documentation

int flashmatch::BaseFlashMatch::_cryo = 0
protected

The Cryostat number to use.

Definition at line 75 of file BaseFlashMatch.h.

flashmatch::BaseFlashHypothesis* flashmatch::BaseFlashMatch::_flash_hypothesis
private

Definition at line 70 of file BaseFlashMatch.h.

int flashmatch::BaseFlashMatch::_tpc = 0
protected

The TPC number to use.

Definition at line 74 of file BaseFlashMatch.h.


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