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

#include <NPtFilter.h>

Inheritance diagram for flashana::NPtFilter:

Public Member Functions

 NPtFilter (const std::string name="NPtFilter")
 Default constructor. More...
 
 ~NPtFilter ()
 Default destructor. More...
 
IDArray_t Filter (const QClusterArray_t &)
 Implementation of virtualfunction. More...
 
void SetMinNumPoints (size_t n)
 set minimum number of point in TPC track More...
 

Protected Member Functions

void _Configure_ (const Config_t &pset)
 

Private Attributes

size_t _min_num_pt
 mininum number of QPoint_t to pass the filter More...
 

Detailed Description

Implementation of flashana::BaseTPCFilter abstract algorithm class.
It applies a very simple filtering: excludes TPC objects (flashana::QCluster_t)
that contains less than specified number of points.

Definition at line 27 of file arxiv/NPtFilter.h.

Constructor & Destructor Documentation

flashana::NPtFilter::NPtFilter ( const std::string  name = "NPtFilter")

Default constructor.

Definition at line 10 of file arxiv/NPtFilter.cxx.

11  : BaseTPCFilter(name)
12  { _min_num_pt = 2; }
then echo fcl name
size_t _min_num_pt
mininum number of QPoint_t to pass the filter
flashana::NPtFilter::~NPtFilter ( )
inline

Default destructor.

Definition at line 35 of file arxiv/NPtFilter.h.

35 {}

Member Function Documentation

void flashana::NPtFilter::_Configure_ ( const Config_t &  pset)
protected

Definition at line 14 of file arxiv/NPtFilter.cxx.

15  {
16  _min_num_pt = pset.get<double>("MinNumPoint");
17  }
size_t _min_num_pt
mininum number of QPoint_t to pass the filter
IDArray_t flashana::NPtFilter::Filter ( const QClusterArray_t &  tpc_obj_v)

Implementation of virtualfunction.

Definition at line 19 of file arxiv/NPtFilter.cxx.

19  {
20 
21  IDArray_t res;
22 
23  // Loop over QCluster_t array
24  for(ID_t id=0; id<tpc_obj_v.size(); ++id) {
25 
26  auto const& tpc_obj = tpc_obj_v[id]; // retrieve
27 
28  // if more # of QPoint_t than threshold, accept
29  if(tpc_obj.size() >= _min_num_pt) res.push_back(id);
30 
31  }
32 
33  return res;
34  }
std::vector< flashmatch::ID_t > IDArray_t
Index collection.
size_t ID_t
Index used to identify Flash_t/QPointCollection_t uniquely in an event.
size_t _min_num_pt
mininum number of QPoint_t to pass the filter
void flashana::NPtFilter::SetMinNumPoints ( size_t  n)
inline

set minimum number of point in TPC track

Definition at line 41 of file arxiv/NPtFilter.h.

41 { _min_num_pt = n; }
size_t _min_num_pt
mininum number of QPoint_t to pass the filter

Member Data Documentation

size_t flashana::NPtFilter::_min_num_pt
private

mininum number of QPoint_t to pass the filter

Definition at line 49 of file arxiv/NPtFilter.h.


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