CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Protected Attributes
TopProjectorDeltaROverlap< Top, Bottom > Class Template Reference

This checks matching based on delta R. More...

#include <TopProjector.h>

Public Types

typedef edm::FwdPtr< Bottom > BottomFwdPtr
 
typedef edm::FwdPtr< Top > TopFwdPtr
 

Public Member Functions

bool operator() (TopFwdPtr const &top) const
 
void setBottom (BottomFwdPtr const &bottom)
 
 TopProjectorDeltaROverlap ()
 
 TopProjectorDeltaROverlap (edm::ParameterSet const &config)
 

Protected Attributes

float botEta_
 
float botPhi_
 
BottomFwdPtr const * bottom_
 
const Bottom * bottomCPtr_
 
double deltaR2_
 

Detailed Description

template<class Top, class Bottom>
class TopProjectorDeltaROverlap< Top, Bottom >

This checks matching based on delta R.

Definition at line 102 of file TopProjector.h.

Member Typedef Documentation

◆ BottomFwdPtr

template<class Top , class Bottom >
typedef edm::FwdPtr<Bottom> TopProjectorDeltaROverlap< Top, Bottom >::BottomFwdPtr

Definition at line 105 of file TopProjector.h.

◆ TopFwdPtr

template<class Top , class Bottom >
typedef edm::FwdPtr<Top> TopProjectorDeltaROverlap< Top, Bottom >::TopFwdPtr

Definition at line 104 of file TopProjector.h.

Constructor & Destructor Documentation

◆ TopProjectorDeltaROverlap() [1/2]

template<class Top , class Bottom >
TopProjectorDeltaROverlap< Top, Bottom >::TopProjectorDeltaROverlap ( )
inlineexplicit

Definition at line 107 of file TopProjector.h.

107 { bottom_ = 0; }

References TopProjectorDeltaROverlap< Top, Bottom >::bottom_.

◆ TopProjectorDeltaROverlap() [2/2]

template<class Top , class Bottom >
TopProjectorDeltaROverlap< Top, Bottom >::TopProjectorDeltaROverlap ( edm::ParameterSet const &  config)
inlineexplicit

Definition at line 108 of file TopProjector.h.

109  : deltaR2_(config.getParameter<double>("deltaR")),
110  bottom_(nullptr),
111  bottomCPtr_(nullptr),
112  botEta_(-999.f),
113  botPhi_(0.f) {
114  deltaR2_ *= deltaR2_;
115  }

References TopProjectorDeltaROverlap< Top, Bottom >::deltaR2_.

Member Function Documentation

◆ operator()()

template<class Top , class Bottom >
bool TopProjectorDeltaROverlap< Top, Bottom >::operator() ( TopFwdPtr const &  top) const
inline

Definition at line 124 of file TopProjector.h.

124  {
125  const Top& oTop = *top;
126  float topEta = oTop.eta();
127  float topPhi = oTop.phi();
128  bool matched = reco::deltaR2(topEta, topPhi, botEta_, botPhi_) < deltaR2_;
129  return matched;
130  }

References TopProjectorDeltaROverlap< Top, Bottom >::botEta_, TopProjectorDeltaROverlap< Top, Bottom >::botPhi_, reco::deltaR2(), TopProjectorDeltaROverlap< Top, Bottom >::deltaR2_, muonTagProbeFilters_cff::matched, and TtFullHadDaughter::Top.

◆ setBottom()

template<class Top , class Bottom >
void TopProjectorDeltaROverlap< Top, Bottom >::setBottom ( BottomFwdPtr const &  bottom)
inline

Member Data Documentation

◆ botEta_

template<class Top , class Bottom >
float TopProjectorDeltaROverlap< Top, Bottom >::botEta_
protected

◆ botPhi_

template<class Top , class Bottom >
float TopProjectorDeltaROverlap< Top, Bottom >::botPhi_
protected

◆ bottom_

template<class Top , class Bottom >
BottomFwdPtr const* TopProjectorDeltaROverlap< Top, Bottom >::bottom_
protected

◆ bottomCPtr_

template<class Top , class Bottom >
const Bottom* TopProjectorDeltaROverlap< Top, Bottom >::bottomCPtr_
protected

Definition at line 135 of file TopProjector.h.

Referenced by TopProjectorDeltaROverlap< Top, Bottom >::setBottom().

◆ deltaR2_

template<class Top , class Bottom >
double TopProjectorDeltaROverlap< Top, Bottom >::deltaR2_
protected
muonTagProbeFilters_cff.matched
matched
Definition: muonTagProbeFilters_cff.py:62
f
double f[11][100]
Definition: MuScleFitUtils.cc:78
TopProjectorDeltaROverlap::bottomCPtr_
const Bottom * bottomCPtr_
Definition: TopProjector.h:135
config
Definition: config.py:1
TopProjectorDeltaROverlap::botEta_
float botEta_
Definition: TopProjector.h:136
TtFullHadDaughter::Top
static const std::string Top
Definition: TtFullHadronicEvent.h:9
reco::deltaR2
constexpr auto deltaR2(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
Definition: deltaR.h:16
TopProjectorDeltaROverlap::deltaR2_
double deltaR2_
Definition: TopProjector.h:133
TopProjectorDeltaROverlap::bottom_
BottomFwdPtr const * bottom_
Definition: TopProjector.h:134
TopProjectorDeltaROverlap::botPhi_
float botPhi_
Definition: TopProjector.h:136