CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
egHLT::EgJetB2BCut< T > Struct Template Reference

#include <EgHLTDQMCut.h>

Inheritance diagram for egHLT::EgJetB2BCut< T >:
egHLT::EgHLTDQMCut< T >

Public Member Functions

EgHLTDQMCut< T > * clone () const
 
 EgJetB2BCut (float minDPhi=-M_PI, float maxDPhi=M_PI, float ptRelDiff=999)
 
bool pass (const T &obj, const OffEvt &evt) const
 
- Public Member Functions inherited from egHLT::EgHLTDQMCut< T >
 EgHLTDQMCut ()=default
 
virtual ~EgHLTDQMCut ()=default
 

Private Attributes

float maxDPhi_
 
float minDPhi_
 
float ptRelDiff_
 

Additional Inherited Members

- Protected Member Functions inherited from egHLT::EgHLTDQMCut< T >
 EgHLTDQMCut (const EgHLTDQMCut &rhs)=default
 

Detailed Description

template<class T>
struct egHLT::EgJetB2BCut< T >

Definition at line 362 of file EgHLTDQMCut.h.

Constructor & Destructor Documentation

◆ EgJetB2BCut()

template<class T >
egHLT::EgJetB2BCut< T >::EgJetB2BCut ( float  minDPhi = -M_PI,
float  maxDPhi = M_PI,
float  ptRelDiff = 999 
)
inline

Definition at line 369 of file EgHLTDQMCut.h.

370  : minDPhi_(minDPhi), maxDPhi_(maxDPhi), ptRelDiff_(ptRelDiff) {}

Referenced by egHLT::EgJetB2BCut< T >::clone().

Member Function Documentation

◆ clone()

template<class T >
EgHLTDQMCut<T>* egHLT::EgJetB2BCut< T >::clone ( void  ) const
inlinevirtual

Implements egHLT::EgHLTDQMCut< T >.

Definition at line 372 of file EgHLTDQMCut.h.

372 { return new EgJetB2BCut(*this); }

References egHLT::EgJetB2BCut< T >::EgJetB2BCut().

◆ pass()

template<class T >
bool egHLT::EgJetB2BCut< T >::pass ( const T obj,
const OffEvt evt 
) const
virtual

Implements egHLT::EgHLTDQMCut< T >.

Definition at line 376 of file EgHLTDQMCut.h.

376  {
377  bool b2bJet = false;
378  const std::vector<reco::CaloJet>& jets = evt.jets();
379  for (const auto& jet : jets) {
380  if (reco::deltaR2(obj.eta(), obj.phi(), jet.eta(), jet.phi()) >
381  0.1 * 0.1) { //not in a cone of 0.1 of probe object
382  float dPhi = reco::deltaPhi(obj.phi(), jet.phi());
383  if (dPhi > minDPhi_ && dPhi < maxDPhi_ && fabs(1 - jet.pt() / obj.pt()) < ptRelDiff_)
384  b2bJet = true;
385  }
386  }
387  return b2bJet;
388  }

References reco::deltaPhi(), reco::deltaR2(), HLT_FULL_cff::dPhi, metsig::jet, singleTopDQM_cfi::jets, egHLT::OffEvt::jets(), and getGTfromDQMFile::obj.

Member Data Documentation

◆ maxDPhi_

template<class T >
float egHLT::EgJetB2BCut< T >::maxDPhi_
private

Definition at line 365 of file EgHLTDQMCut.h.

◆ minDPhi_

template<class T >
float egHLT::EgJetB2BCut< T >::minDPhi_
private

Definition at line 364 of file EgHLTDQMCut.h.

◆ ptRelDiff_

template<class T >
float egHLT::EgJetB2BCut< T >::ptRelDiff_
private

Definition at line 366 of file EgHLTDQMCut.h.

reco::deltaPhi
constexpr double deltaPhi(double phi1, double phi2)
Definition: deltaPhi.h:26
egHLT::EgJetB2BCut::EgJetB2BCut
EgJetB2BCut(float minDPhi=-M_PI, float maxDPhi=M_PI, float ptRelDiff=999)
Definition: EgHLTDQMCut.h:369
HLT_FULL_cff.maxDPhi
maxDPhi
Definition: HLT_FULL_cff.py:9146
singleTopDQM_cfi.jets
jets
Definition: singleTopDQM_cfi.py:42
HLT_FULL_cff.dPhi
dPhi
Definition: HLT_FULL_cff.py:13703
egHLT::EgJetB2BCut::ptRelDiff_
float ptRelDiff_
Definition: EgHLTDQMCut.h:366
getGTfromDQMFile.obj
obj
Definition: getGTfromDQMFile.py:32
reco::deltaR2
constexpr auto deltaR2(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
Definition: deltaR.h:16
egHLT::EgJetB2BCut::minDPhi_
float minDPhi_
Definition: EgHLTDQMCut.h:364
metsig::jet
Definition: SignAlgoResolutions.h:47
egHLT::EgJetB2BCut::maxDPhi_
float maxDPhi_
Definition: EgHLTDQMCut.h:365