CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
L2AbsScaleCalculator Class Reference

#include <L2AbsScaleCalculator.h>

Inheritance diagram for L2AbsScaleCalculator:
AbsFFTSpecificScaleCalculator

Public Member Functions

 L2AbsScaleCalculator (const edm::ParameterSet &ps)
 
virtual void mapFFTJet (const reco::Jet &, const reco::FFTJet< float > &fftJet, const math::XYZTLorentzVector &current, double *buf, const unsigned dim) const
 
virtual ~L2AbsScaleCalculator ()
 
- Public Member Functions inherited from AbsFFTSpecificScaleCalculator
virtual ~AbsFFTSpecificScaleCalculator ()
 

Private Attributes

double m_radiusFactor
 
bool m_takePtLog
 
double m_zeroPtLog
 

Detailed Description

Definition at line 11 of file L2AbsScaleCalculator.h.

Constructor & Destructor Documentation

L2AbsScaleCalculator::L2AbsScaleCalculator ( const edm::ParameterSet ps)
inlineexplicit

Definition at line 14 of file L2AbsScaleCalculator.h.

15  : m_radiusFactor(ps.getParameter<double>("radiusFactor")),
16  m_zeroPtLog(ps.getParameter<double>("zeroPtLog")),
17  m_takePtLog(ps.getParameter<bool>("takePtLog")) {}
T getParameter(std::string const &) const
virtual L2AbsScaleCalculator::~L2AbsScaleCalculator ( )
inlinevirtual

Definition at line 19 of file L2AbsScaleCalculator.h.

19 {}

Member Function Documentation

virtual void L2AbsScaleCalculator::mapFFTJet ( const reco::Jet ,
const reco::FFTJet< float > &  fftJet,
const math::XYZTLorentzVector current,
double *  buf,
const unsigned  dim 
) const
inlinevirtual

Implements AbsFFTSpecificScaleCalculator.

Definition at line 21 of file L2AbsScaleCalculator.h.

References edm::hlt::Exception, reco::FFTJet< Real >::f_recoScale(), create_public_lumi_plots::log, m_radiusFactor, m_takePtLog, m_zeroPtLog, RecoTauCleanerPlugins::pt, and CosmicsPD_Skims::radius.

25  {
26  if (dim != 2)
27  throw cms::Exception("FFTJetBadConfig")
28  << "In L2AbsScaleCalculator::mapFFTJet: "
29  << "invalid table dimensionality: "
30  << dim << std::endl;
31  assert(buf);
32  const double radius = fftJet.f_recoScale();
33  const double pt = current.pt();
34  buf[0] = radius*m_radiusFactor;
35  if (m_takePtLog)
36  {
37  if (pt > 0.0)
38  buf[1] = log(pt);
39  else
40  buf[1] = m_zeroPtLog;
41  }
42  else
43  buf[1] = pt;
44  }
Real f_recoScale() const
Definition: FFTJet.h:73

Member Data Documentation

double L2AbsScaleCalculator::m_radiusFactor
private

Definition at line 47 of file L2AbsScaleCalculator.h.

Referenced by mapFFTJet().

bool L2AbsScaleCalculator::m_takePtLog
private

Definition at line 49 of file L2AbsScaleCalculator.h.

Referenced by mapFFTJet().

double L2AbsScaleCalculator::m_zeroPtLog
private

Definition at line 48 of file L2AbsScaleCalculator.h.

Referenced by mapFFTJet().