ATLAS Offline Software
Public Member Functions | Private Attributes | List of all members
RoiFilter Class Reference

#include <RoiFilter.h>

Collaboration diagram for RoiFilter:

Public Member Functions

 RoiFilter (double eta=0, bool comp=false, size_t m=1)
 
 RoiFilter (TIDARoiDescriptor)
 
double eta () const
 
bool composite () const
 
size_t size () const
 
bool filter (const TIDARoiDescriptor *roi)
 
bool filter (const TIDARoiDescriptor &roi)
 

Private Attributes

double m_eta
 
bool m_comp
 
size_t m_mult
 

Detailed Description

Definition at line 21 of file RoiFilter.h.

Constructor & Destructor Documentation

◆ RoiFilter() [1/2]

RoiFilter::RoiFilter ( double  eta = 0,
bool  comp = false,
size_t  m = 1 
)
inline

Definition at line 25 of file RoiFilter.h.

25 : m_eta(eta), m_comp(comp), m_mult(m) { }

◆ RoiFilter() [2/2]

RoiFilter::RoiFilter ( TIDARoiDescriptor  )
inline

Definition at line 26 of file RoiFilter.h.

26 : m_eta(0.0),m_comp(false),m_mult(0) { }

Member Function Documentation

◆ composite()

bool RoiFilter::composite ( ) const
inline

Definition at line 29 of file RoiFilter.h.

29 { return m_comp; }

◆ eta()

double RoiFilter::eta ( ) const
inline

Definition at line 28 of file RoiFilter.h.

28 { return m_eta; }

◆ filter() [1/2]

bool RoiFilter::filter ( const TIDARoiDescriptor roi)
inline

Definition at line 51 of file RoiFilter.h.

51 { return filter( &roi ); }

◆ filter() [2/2]

bool RoiFilter::filter ( const TIDARoiDescriptor roi)
inline

Definition at line 32 of file RoiFilter.h.

32  {
33 
34  if ( !composite() ) {
35  if ( !roi->composite() && std::fabs(roi->eta())<=eta() ) return true;
36  else return false;
37  }
38 
39  if ( roi->size()<size() ) return false;
40 
41  size_t mult = 0;
42  for ( size_t i=0 ; i<roi->size() ; i++ ) {
43  if ( std::fabs(roi->at(i)->eta())<=eta() ) mult++;
44  }
45 
46  if ( mult<size() ) return false;
47 
48  return true;
49  }

◆ size()

size_t RoiFilter::size ( ) const
inline

Definition at line 30 of file RoiFilter.h.

30 { return m_mult; }

Member Data Documentation

◆ m_comp

bool RoiFilter::m_comp
private

Definition at line 56 of file RoiFilter.h.

◆ m_eta

double RoiFilter::m_eta
private

Definition at line 55 of file RoiFilter.h.

◆ m_mult

size_t RoiFilter::m_mult
private

Definition at line 57 of file RoiFilter.h.


The documentation for this class was generated from the following file:
plotting.yearwise_luminosity_vs_mu.comp
comp
Definition: yearwise_luminosity_vs_mu.py:23
python.SystemOfUnits.m
int m
Definition: SystemOfUnits.py:91
RoiFilter::m_comp
bool m_comp
Definition: RoiFilter.h:56
TIDARoiDescriptor::size
size_t size() const
Definition: TIDARoiDescriptor.h:176
TIDARoiDescriptor::composite
bool composite() const
composite RoI methods
Definition: TIDARoiDescriptor.h:174
lumiFormat.i
int i
Definition: lumiFormat.py:85
RoiFilter::size
size_t size() const
Definition: RoiFilter.h:30
RoiFilter::m_mult
size_t m_mult
Definition: RoiFilter.h:57
TIDARoiDescriptor::eta
double eta() const
Definition: TIDARoiDescriptor.h:134
RoiFilter::filter
bool filter(const TIDARoiDescriptor *roi)
Definition: RoiFilter.h:32
TIDARoiDescriptor::at
const TIDARoiDescriptor * at(int i) const
gets phi half-width
Definition: TIDARoiDescriptor.h:179
RoiFilter::m_eta
double m_eta
Definition: RoiFilter.h:55
RoiFilter::eta
double eta() const
Definition: RoiFilter.h:28
RoiFilter::composite
bool composite() const
Definition: RoiFilter.h:29