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 106 of file TopProjector.h.

Member Typedef Documentation

◆ BottomFwdPtr

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

Definition at line 109 of file TopProjector.h.

◆ TopFwdPtr

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

Definition at line 108 of file TopProjector.h.

Constructor & Destructor Documentation

◆ TopProjectorDeltaROverlap() [1/2]

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

Definition at line 111 of file TopProjector.h.

111 { 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 112 of file TopProjector.h.

113  : deltaR2_(config.getParameter<double>("deltaR")),
114  bottom_(nullptr),
115  bottomCPtr_(nullptr),
116  botEta_(-999.f),
117  botPhi_(0.f) {
118  deltaR2_ *= deltaR2_;
119  }

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 128 of file TopProjector.h.

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

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 139 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:139
config
Definition: config.py:1
TopProjectorDeltaROverlap::botEta_
float botEta_
Definition: TopProjector.h:140
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:137
TopProjectorDeltaROverlap::bottom_
BottomFwdPtr const * bottom_
Definition: TopProjector.h:138
TopProjectorDeltaROverlap::botPhi_
float botPhi_
Definition: TopProjector.h:140