CMS 3D CMS Logo

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

#include <IsoDeposit.h>

Classes

class  const_iterator
 
class  CountAlgo
 
class  MaxAlgo
 
class  Sum2Algo
 
class  SumAlgo
 
struct  Veto
 

Public Types

typedef isodeposit::AbsVeto AbsVeto
 
typedef isodeposit::AbsVetos AbsVetos
 
typedef isodeposit::Direction Direction
 
typedef std::vector< VetoVetos
 

Public Member Functions

void addCandEnergy (double et)
 Set energy or pT attached to cand trajectory. More...
 
void addDeposit (double dr, double deposit)
 Add deposit (ie. transverse energy or pT) More...
 
void addDeposit (const Direction &depDir, double deposit)
 
template<typename Algo >
double algoWithin (double coneSize, const AbsVetos &vetos=AbsVetos(), bool skipDepositVeto=false) const
 Get some info about the deposit (e.g. sum, max, sum2, count) More...
 
template<typename Algo >
double algoWithin (const Direction &, double coneSize, const AbsVetos &vetos=AbsVetos(), bool skipDepositVeto=false) const
 Get some info about the deposit (e.g. sum, max, sum2, count) w.r.t. other direction. More...
 
const_iterator begin () const
 
double candEnergy () const
 Get energy or pT attached to cand trajectory. More...
 
double countWithin (double coneSize, const AbsVetos &vetos=AbsVetos(), bool skipDepositVeto=false) const
 
std::pair< double, int > depositAndCountWithin (double coneSize, const Vetos &vetos=Vetos(), double threshold=-1e+36, bool skipDepositVeto=false) const
 Get deposit. More...
 
std::pair< double, int > depositAndCountWithin (Direction dir, double coneSize, const Vetos &vetos=Vetos(), double threshold=-1e+36, bool skipDepositVeto=false) const
 Get deposit wrt other direction. More...
 
std::pair< double, int > depositAndCountWithin (double coneSize, const AbsVetos &vetos, bool skipDepositVeto=false) const
 Get deposit. More...
 
double depositWithin (double coneSize, const Vetos &vetos=Vetos(), bool skipDepositVeto=false) const
 Get deposit. More...
 
double depositWithin (Direction dir, double coneSize, const Vetos &vetos=Vetos(), bool skipDepositVeto=false) const
 Get deposit wrt other direction. More...
 
double depositWithin (double coneSize, const AbsVetos &vetos, bool skipDepositVeto=false) const
 Get deposit with new style vetos. More...
 
const Directiondirection () const
 Get direction of isolation cone. More...
 
const_iterator end () const
 
double eta () const
 
 IsoDeposit (double eta=0, double phi=0)
 Constructor. More...
 
 IsoDeposit (const Direction &candDirection)
 
double maxWithin (double coneSize, const AbsVetos &vetos=AbsVetos(), bool skipDepositVeto=false) const
 
double nearestDR (double coneSize, const AbsVetos &vetos=AbsVetos(), bool skipDepositVeto=false) const
 
double phi () const
 
std::string print () const
 
void setVeto (const Veto &aVeto)
 Set veto. More...
 
double sum2Within (double coneSize, const AbsVetos &vetos=AbsVetos(), bool skipDepositVeto=false) const
 
double sumWithin (double coneSize, const AbsVetos &vetos=AbsVetos(), bool skipDepositVeto=false) const
 
double sumWithin (const Direction &dir, double coneSize, const AbsVetos &vetos=AbsVetos(), bool skipDepositVeto=false) const
 
const Vetoveto () const
 Get veto area. More...
 
virtual ~IsoDeposit ()
 Destructor. More...
 

Private Types

typedef std::multimap
< Distance, float > 
DepositsMultimap
 
typedef Direction::Distance Distance
 the deposits identifed by relative position to center of cone and deposit value More...
 

Private Attributes

float theCandTag
 float tagging cand, ment to be transverse energy or pT attached to cand, More...
 
DepositsMultimap theDeposits
 
Direction theDirection
 direcion of deposit (center of isolation cone) More...
 
Veto theVeto
 area to be excluded in computaion of depositWithin More...
 

Detailed Description

Definition at line 45 of file IsoDeposit.h.

Member Typedef Documentation

Definition at line 49 of file IsoDeposit.h.

Definition at line 50 of file IsoDeposit.h.

typedef std::multimap<Distance, float> reco::IsoDeposit::DepositsMultimap
private

Definition at line 253 of file IsoDeposit.h.

Definition at line 48 of file IsoDeposit.h.

the deposits identifed by relative position to center of cone and deposit value

Definition at line 252 of file IsoDeposit.h.

typedef std::vector<Veto> reco::IsoDeposit::Vetos

Definition at line 58 of file IsoDeposit.h.

Constructor & Destructor Documentation

IsoDeposit::IsoDeposit ( double  eta = 0,
double  phi = 0 
)

Constructor.

Definition at line 16 of file IsoDeposit.cc.

References reco::IsoDeposit::Veto::dR, theDirection, theVeto, and reco::IsoDeposit::Veto::vetoDir.

18 {
20  theVeto.dR = 0.;
21 }
double eta() const
Definition: IsoDeposit.h:69
double phi() const
Definition: IsoDeposit.h:70
Veto theVeto
area to be excluded in computaion of depositWithin
Definition: IsoDeposit.h:246
isodeposit::Direction Direction
Definition: IsoDeposit.h:48
float theCandTag
float tagging cand, ment to be transverse energy or pT attached to cand,
Definition: IsoDeposit.h:249
Direction theDirection
direcion of deposit (center of isolation cone)
Definition: IsoDeposit.h:243
IsoDeposit::IsoDeposit ( const Direction candDirection)

Definition at line 9 of file IsoDeposit.cc.

References reco::IsoDeposit::Veto::dR, theDirection, theVeto, and reco::IsoDeposit::Veto::vetoDir.

10  : theDirection(candDirection),theCandTag(0.)
11 {
13  theVeto.dR = 0.;
14 }
Veto theVeto
area to be excluded in computaion of depositWithin
Definition: IsoDeposit.h:246
float theCandTag
float tagging cand, ment to be transverse energy or pT attached to cand,
Definition: IsoDeposit.h:249
Direction theDirection
direcion of deposit (center of isolation cone)
Definition: IsoDeposit.h:243
virtual reco::IsoDeposit::~IsoDeposit ( )
inlinevirtual

Destructor.

Definition at line 65 of file IsoDeposit.h.

65 {};

Member Function Documentation

void reco::IsoDeposit::addCandEnergy ( double  et)
inline

Set energy or pT attached to cand trajectory.

Definition at line 134 of file IsoDeposit.h.

References theCandTag.

Referenced by muonisolation::PixelTrackExtractor::deposit(), egammaisolation::EgammaTrackExtractor::deposit(), and muonisolation::CaloExtractorByAssociator::deposits().

134 { theCandTag += et;}
float theCandTag
float tagging cand, ment to be transverse energy or pT attached to cand,
Definition: IsoDeposit.h:249
void IsoDeposit::addDeposit ( double  dr,
double  deposit 
)

Add deposit (ie. transverse energy or pT)

Definition at line 23 of file IsoDeposit.cc.

References theDeposits.

Referenced by egammaisolation::EgammaRecHitExtractor::collect(), muonisolation::PixelTrackExtractor::deposit(), egammaisolation::EgammaTrackExtractor::deposit(), and muonisolation::CaloExtractorByAssociator::deposits().

23  {
24  Distance relDir = {float(dr),0.f};
25  theDeposits.insert( std::make_pair( relDir, value));
26 }
Direction::Distance Distance
the deposits identifed by relative position to center of cone and deposit value
Definition: IsoDeposit.h:252
DepositsMultimap theDeposits
Definition: IsoDeposit.h:255
void IsoDeposit::addDeposit ( const Direction depDir,
double  deposit 
)

Definition at line 28 of file IsoDeposit.cc.

References theDeposits, and theDirection.

29 {
30  Distance relDir = depDir - theDirection;
31  theDeposits.insert( std::make_pair( relDir,deposit));
32 }
Direction::Distance Distance
the deposits identifed by relative position to center of cone and deposit value
Definition: IsoDeposit.h:252
DepositsMultimap theDeposits
Definition: IsoDeposit.h:255
Direction theDirection
direcion of deposit (center of isolation cone)
Definition: IsoDeposit.h:243
template<typename Algo >
double IsoDeposit::algoWithin ( double  coneSize,
const AbsVetos vetos = AbsVetos(),
bool  skipDepositVeto = false 
) const

Get some info about the deposit (e.g. sum, max, sum2, count)

Definition at line 261 of file IsoDeposit.h.

References algo, reco::isodeposit::Direction::deltaR(), reco::IsoDeposit::Veto::dR, reco::isodeposit::Direction::eta(), reco::isodeposit::Direction::phi(), theDeposits, theDirection, theVeto, and reco::IsoDeposit::Veto::vetoDir.

262 {
263  using namespace reco::isodeposit;
264  Algo algo;
265  typedef AbsVetos::const_iterator IV;
266  IV ivEnd = vetos.end();
267 
268  Distance maxDistance = {float(coneSize),999.f};
269  typedef DepositsMultimap::const_iterator IM;
270  IM imLoc = theDeposits.upper_bound( maxDistance );
271  for (IM im = theDeposits.begin(); im != imLoc; ++im) {
272  bool vetoed = false;
273  Direction dirDep = theDirection+im->first;
274  for (IV iv = vetos.begin(); iv < ivEnd; ++iv) {
275  if ((*iv)->veto(dirDep.eta(), dirDep.phi(), im->second)) { vetoed = true; break; }
276  }
277  if (!vetoed) {
278  if (skipDepositVeto || (dirDep.deltaR(theVeto.vetoDir) > theVeto.dR)) {
279  algo += im->second;
280  }
281  }
282  }
283  return algo.result();
284 }
Direction::Distance Distance
the deposits identifed by relative position to center of cone and deposit value
Definition: IsoDeposit.h:252
Veto theVeto
area to be excluded in computaion of depositWithin
Definition: IsoDeposit.h:246
DepositsMultimap theDeposits
Definition: IsoDeposit.h:255
LimitAlgo * algo
Definition: Combine.cc:60
Direction theDirection
direcion of deposit (center of isolation cone)
Definition: IsoDeposit.h:243
Definition: fakeMenu.h:4
double deltaR(const Direction &dir2) const
template<typename Algo >
double IsoDeposit::algoWithin ( const Direction dir,
double  coneSize,
const AbsVetos vetos = AbsVetos(),
bool  skipDepositVeto = false 
) const

Get some info about the deposit (e.g. sum, max, sum2, count) w.r.t. other direction.

Definition at line 287 of file IsoDeposit.h.

References algo, reco::isodeposit::Direction::Distance::deltaR, reco::isodeposit::Direction::deltaR(), dir, reco::IsoDeposit::Veto::dR, reco::isodeposit::Direction::eta(), reco::isodeposit::Direction::phi(), theDeposits, theDirection, theVeto, and reco::IsoDeposit::Veto::vetoDir.

289 {
290  using namespace reco::isodeposit;
291  Algo algo;
292  typedef AbsVetos::const_iterator IV;
293  IV ivEnd = vetos.end();
294  typedef DepositsMultimap::const_iterator IM;
295  IM imLoc = theDeposits.end();
296  for (IM im = theDeposits.begin(); im != imLoc; ++im) {
297  bool vetoed = false;
298  Direction dirDep = theDirection+im->first;
299  Distance newDist = dirDep - dir;
300  if(newDist.deltaR > coneSize) continue;
301  for (IV iv = vetos.begin(); iv < ivEnd; ++iv) {
302  if ((*iv)->veto(dirDep.eta(), dirDep.phi(), im->second)) { vetoed = true; break; }
303  }
304  if (!vetoed) {
305  if (skipDepositVeto || (dirDep.deltaR(theVeto.vetoDir) > theVeto.dR)) {
306  algo += im->second;
307  }
308  }
309  }
310  return algo.result();
311 }
Direction::Distance Distance
the deposits identifed by relative position to center of cone and deposit value
Definition: IsoDeposit.h:252
Veto theVeto
area to be excluded in computaion of depositWithin
Definition: IsoDeposit.h:246
DepositsMultimap theDeposits
Definition: IsoDeposit.h:255
dbl *** dir
Definition: mlp_gen.cc:35
LimitAlgo * algo
Definition: Combine.cc:60
Direction theDirection
direcion of deposit (center of isolation cone)
Definition: IsoDeposit.h:243
Definition: fakeMenu.h:4
double deltaR(const Direction &dir2) const
const_iterator reco::IsoDeposit::begin ( void  ) const
inline

Definition at line 158 of file IsoDeposit.h.

References theDeposits.

Referenced by ZMuMuIsolationAnalyzer::Deposits().

158 { return const_iterator(this, theDeposits.begin()); }
DepositsMultimap theDeposits
Definition: IsoDeposit.h:255
double reco::IsoDeposit::candEnergy ( ) const
inline

Get energy or pT attached to cand trajectory.

Definition at line 131 of file IsoDeposit.h.

References theCandTag.

Referenced by ZMuMuIsolationAnalyzer::analyze(), PFCandIsolatorFromDeposits::SingleDeposit::compute(), CandIsolatorFromDeposits::SingleDeposit::compute(), MuonIdProducer::fillMuonIsolation(), and pat::helper::IsoDepositIsolator::getValue().

131 {return theCandTag;}
float theCandTag
float tagging cand, ment to be transverse energy or pT attached to cand,
Definition: IsoDeposit.h:249
double IsoDeposit::countWithin ( double  coneSize,
const AbsVetos vetos = AbsVetos(),
bool  skipDepositVeto = false 
) const

Definition at line 134 of file IsoDeposit.cc.

Referenced by PFCandIsolatorFromDeposits::SingleDeposit::compute(), CandIsolatorFromDeposits::SingleDeposit::compute(), and pat::helper::IsoDepositIsolator::getValue().

135 {
136  return algoWithin<CountAlgo>(coneSize, vetos, skipDepositVeto);
137 }
std::pair< double, int > IsoDeposit::depositAndCountWithin ( double  coneSize,
const Vetos vetos = Vetos(),
double  threshold = -1e+36,
bool  skipDepositVeto = false 
) const

Get deposit.

Definition at line 44 of file IsoDeposit.cc.

References prof2calltree::count, reco::isodeposit::Direction::deltaR(), query::result, theDeposits, theDirection, and theVeto.

Referenced by depositWithin(), MuonIdProducer::fillMuonIsolation(), L3MuonCombinedRelativeIsolationProducer::produce(), L3MuonIsolationProducer::produce(), and muonisolation::IsolatorByDepositCount::result().

46 {
47  double result = 0;
48  int count = 0;
49 
50  Vetos allVetos = vetos;
51  typedef Vetos::const_iterator IV;
52  if (!skipDepositVeto) allVetos.push_back(theVeto);
53  IV ivEnd = allVetos.end();
54 
55  Distance maxDistance = {float(coneSize),999.f};
56  typedef DepositsMultimap::const_iterator IM;
57  IM imLoc = theDeposits.upper_bound( maxDistance );
58  for (IM im = theDeposits.begin(); im != imLoc; ++im) {
59  bool vetoed = false;
60  for ( IV iv = allVetos.begin(); iv < ivEnd; ++iv) {
61  Direction dirDep = theDirection+im->first;
62  if (dirDep.deltaR(iv->vetoDir) < iv->dR) vetoed = true;
63  }
64  if (!vetoed && im->second > threshold){
65  result += im->second;
66  count++;
67  }
68  }
69  return std::pair<double,int>(result,count);
70 }
Direction::Distance Distance
the deposits identifed by relative position to center of cone and deposit value
Definition: IsoDeposit.h:252
Veto theVeto
area to be excluded in computaion of depositWithin
Definition: IsoDeposit.h:246
DepositsMultimap theDeposits
Definition: IsoDeposit.h:255
tuple result
Definition: query.py:137
std::vector< Veto > Vetos
Definition: IsoDeposit.h:58
Direction theDirection
direcion of deposit (center of isolation cone)
Definition: IsoDeposit.h:243
double deltaR(const Direction &dir2) const
std::pair< double, int > IsoDeposit::depositAndCountWithin ( Direction  dir,
double  coneSize,
const Vetos vetos = Vetos(),
double  threshold = -1e+36,
bool  skipDepositVeto = false 
) const

Get deposit wrt other direction.

Definition at line 72 of file IsoDeposit.cc.

References prof2calltree::count, reco::isodeposit::Direction::Distance::deltaR, reco::isodeposit::Direction::deltaR(), dir, query::result, theDeposits, theDirection, and theVeto.

74 {
75  double result = 0;
76  int count = 0;
77 
78  Vetos allVetos = vetos;
79  typedef Vetos::const_iterator IV;
80  if (!skipDepositVeto) allVetos.push_back(theVeto);
81  IV ivEnd = allVetos.end();
82 
83  typedef DepositsMultimap::const_iterator IM;
84  for (IM im = theDeposits.begin(); im != theDeposits.end(); ++im) {
85  bool vetoed = false;
86  Direction dirDep = theDirection+im->first;
87  Distance newDist = dirDep - dir;
88  if (newDist.deltaR > coneSize) continue;
89  for ( IV iv = allVetos.begin(); iv < ivEnd; ++iv) {
90  if (dirDep.deltaR(iv->vetoDir) < iv->dR) vetoed = true;
91  }
92  if (!vetoed && im->second > threshold){
93  result += im->second;
94  count++;
95  }
96  }
97  return std::pair<double,int>(result,count);
98 }
Direction::Distance Distance
the deposits identifed by relative position to center of cone and deposit value
Definition: IsoDeposit.h:252
Veto theVeto
area to be excluded in computaion of depositWithin
Definition: IsoDeposit.h:246
DepositsMultimap theDeposits
Definition: IsoDeposit.h:255
tuple result
Definition: query.py:137
std::vector< Veto > Vetos
Definition: IsoDeposit.h:58
dbl *** dir
Definition: mlp_gen.cc:35
Direction theDirection
direcion of deposit (center of isolation cone)
Definition: IsoDeposit.h:243
double deltaR(const Direction &dir2) const
std::pair< double, int > IsoDeposit::depositAndCountWithin ( double  coneSize,
const AbsVetos vetos,
bool  skipDepositVeto = false 
) const

Get deposit.

Definition at line 100 of file IsoDeposit.cc.

References prof2calltree::count, reco::isodeposit::Direction::deltaR(), reco::IsoDeposit::Veto::dR, reco::isodeposit::Direction::eta(), reco::isodeposit::Direction::phi(), query::result, theDeposits, theDirection, theVeto, and reco::IsoDeposit::Veto::vetoDir.

101 {
102  using namespace reco::isodeposit;
103  double result = 0;
104  int count = 0;
105  typedef AbsVetos::const_iterator IV;
106 
107  IV ivEnd = vetos.end();
108 
109  Distance maxDistance = {float(coneSize),999.f};
110  typedef DepositsMultimap::const_iterator IM;
111  IM imLoc = theDeposits.upper_bound( maxDistance );
112  for (IM im = theDeposits.begin(); im != imLoc; ++im) {
113  bool vetoed = false;
114  Direction dirDep = theDirection+im->first;
115  for ( IV iv = vetos.begin(); iv < ivEnd; ++iv) {
116  if ((*iv)->veto(dirDep.eta(), dirDep.phi(), im->second)) { vetoed = true; break; }
117  }
118  if (!vetoed) {
119  if (skipDepositVeto || (dirDep.deltaR(theVeto.vetoDir) > theVeto.dR)) {
120  result += im->second;
121  count++;
122  }
123  }
124  }
125  return std::pair<double,int>(result,count);
126 }
Direction::Distance Distance
the deposits identifed by relative position to center of cone and deposit value
Definition: IsoDeposit.h:252
Veto theVeto
area to be excluded in computaion of depositWithin
Definition: IsoDeposit.h:246
DepositsMultimap theDeposits
Definition: IsoDeposit.h:255
tuple result
Definition: query.py:137
Direction theDirection
direcion of deposit (center of isolation cone)
Definition: IsoDeposit.h:243
double deltaR(const Direction &dir2) const
double IsoDeposit::depositWithin ( double  coneSize,
const Vetos vetos = Vetos(),
bool  skipDepositVeto = false 
) const

Get deposit.

Definition at line 34 of file IsoDeposit.cc.

References depositAndCountWithin(), and alignCSCRings::e.

Referenced by MuonIdProducer::fillMuonIsolation(), IsolationProducerForTracks::produce(), and L3MuonCombinedRelativeIsolationProducer::produce().

35 {
36  return depositAndCountWithin(coneSize, vetos, -1e+36, skipDepositVeto).first;
37 }
std::pair< double, int > depositAndCountWithin(double coneSize, const Vetos &vetos=Vetos(), double threshold=-1e+36, bool skipDepositVeto=false) const
Get deposit.
Definition: IsoDeposit.cc:44
double IsoDeposit::depositWithin ( Direction  dir,
double  coneSize,
const Vetos vetos = Vetos(),
bool  skipDepositVeto = false 
) const

Get deposit wrt other direction.

Definition at line 39 of file IsoDeposit.cc.

References depositAndCountWithin(), and alignCSCRings::e.

40 {
41  return depositAndCountWithin(dir, coneSize, vetos, -1e+36, skipDepositVeto).first;
42 }
std::pair< double, int > depositAndCountWithin(double coneSize, const Vetos &vetos=Vetos(), double threshold=-1e+36, bool skipDepositVeto=false) const
Get deposit.
Definition: IsoDeposit.cc:44
double IsoDeposit::depositWithin ( double  coneSize,
const AbsVetos vetos,
bool  skipDepositVeto = false 
) const

Get deposit with new style vetos.

Definition at line 129 of file IsoDeposit.cc.

References depositAndCountWithin().

130 {
131  return depositAndCountWithin(coneSize, vetos, skipDepositVeto).first;
132 }
std::pair< double, int > depositAndCountWithin(double coneSize, const Vetos &vetos=Vetos(), double threshold=-1e+36, bool skipDepositVeto=false) const
Get deposit.
Definition: IsoDeposit.cc:44
const Direction& reco::IsoDeposit::direction ( ) const
inline

Get direction of isolation cone.

Definition at line 68 of file IsoDeposit.h.

References theDirection.

Referenced by reco::IsoDeposit::const_iterator::doDir().

68 { return theDirection; }
Direction theDirection
direcion of deposit (center of isolation cone)
Definition: IsoDeposit.h:243
const_iterator reco::IsoDeposit::end ( void  ) const
inline

Definition at line 159 of file IsoDeposit.h.

References theDeposits.

Referenced by Types.LuminosityBlockRange::cppID(), Types.EventRange::cppID(), and ZMuMuIsolationAnalyzer::Deposits().

159 { return const_iterator(this, theDeposits.end()); }
DepositsMultimap theDeposits
Definition: IsoDeposit.h:255
double reco::IsoDeposit::eta ( ) const
inline
double IsoDeposit::maxWithin ( double  coneSize,
const AbsVetos vetos = AbsVetos(),
bool  skipDepositVeto = false 
) const

Definition at line 150 of file IsoDeposit.cc.

Referenced by PFCandIsolatorFromDeposits::SingleDeposit::compute(), CandIsolatorFromDeposits::SingleDeposit::compute(), and pat::helper::IsoDepositIsolator::getValue().

151 {
152  return algoWithin<MaxAlgo>(coneSize, vetos, skipDepositVeto);
153 }
double IsoDeposit::nearestDR ( double  coneSize,
const AbsVetos vetos = AbsVetos(),
bool  skipDepositVeto = false 
) const

Definition at line 155 of file IsoDeposit.cc.

References reco::isodeposit::Direction::deltaR(), reco::IsoDeposit::Veto::dR, reco::isodeposit::Direction::eta(), reco::isodeposit::Direction::phi(), query::result, theDeposits, theDirection, theVeto, and reco::IsoDeposit::Veto::vetoDir.

Referenced by PFCandIsolatorFromDeposits::SingleDeposit::compute(), and CandIsolatorFromDeposits::SingleDeposit::compute().

156 {
157  using namespace reco::isodeposit;
158  double result = coneSize;
159  typedef AbsVetos::const_iterator IV;
160 
161  IV ivEnd = vetos.end();
162 
163  Distance maxDistance = {float(coneSize),999.f};
164  typedef DepositsMultimap::const_iterator IM;
165  IM imLoc = theDeposits.upper_bound( maxDistance );
166  for (IM im = theDeposits.begin(); im != imLoc; ++im) {
167  bool vetoed = false;
168  Direction dirDep = theDirection+im->first;
169  for ( IV iv = vetos.begin(); iv < ivEnd; ++iv) {
170  if ((*iv)->veto(dirDep.eta(), dirDep.phi(), im->second)) { vetoed = true; break; }
171  }
172  if (!vetoed) {
173  if (skipDepositVeto || (dirDep.deltaR(theVeto.vetoDir) > theVeto.dR)) {
174  result = ( dirDep.deltaR(theVeto.vetoDir) < result ) ? dirDep.deltaR(theVeto.vetoDir) : result;
175  }
176  }
177  }
178  return result;
179 }
Direction::Distance Distance
the deposits identifed by relative position to center of cone and deposit value
Definition: IsoDeposit.h:252
Veto theVeto
area to be excluded in computaion of depositWithin
Definition: IsoDeposit.h:246
DepositsMultimap theDeposits
Definition: IsoDeposit.h:255
tuple result
Definition: query.py:137
Direction theDirection
direcion of deposit (center of isolation cone)
Definition: IsoDeposit.h:243
double deltaR(const Direction &dir2) const
double reco::IsoDeposit::phi ( ) const
inline
std::string IsoDeposit::print ( void  ) const

Definition at line 181 of file IsoDeposit.cc.

References reco::IsoDeposit::Veto::dR, reco::isodeposit::Direction::eta(), reco::isodeposit::Direction::phi(), reco::isodeposit::Direction::print(), theDeposits, theDirection, theVeto, and reco::IsoDeposit::Veto::vetoDir.

Referenced by HLTMuonIsoFilter::hltFilter(), L3MuonIsolationProducer::produce(), and L3MuonCombinedRelativeIsolationProducer::produce().

181  {
182  std::ostringstream str;
183  str<<"Direction : "<<theDirection.print()<<std::endl;
184  str<<"Veto: ("<<theVeto.vetoDir.eta()<<", "<<theVeto.vetoDir.phi()<<" dR="<<theVeto.dR<<")"<<std::endl;
185  typedef DepositsMultimap::const_iterator IM;
186  IM imEnd = theDeposits.end();
187  for (IM im = theDeposits.begin(); im != imEnd; ++im) {
188  str<<"(dR="<< im->first.deltaR<<", alpha="<<im->first.relativeAngle<<", Pt="<<im->second<<"),";
189  }
190  str<<std::endl;
191 
192 
193 
194  return str.str();
195 }
Veto theVeto
area to be excluded in computaion of depositWithin
Definition: IsoDeposit.h:246
DepositsMultimap theDeposits
Definition: IsoDeposit.h:255
Direction theDirection
direcion of deposit (center of isolation cone)
Definition: IsoDeposit.h:243
void reco::IsoDeposit::setVeto ( const Veto aVeto)
inline

Set veto.

Definition at line 75 of file IsoDeposit.h.

References theVeto.

Referenced by muonisolation::PixelTrackExtractor::deposit(), egammaisolation::EgammaTrackExtractor::deposit(), and muonisolation::CaloExtractorByAssociator::deposits().

75 { theVeto = aVeto; }
Veto theVeto
area to be excluded in computaion of depositWithin
Definition: IsoDeposit.h:246
double IsoDeposit::sum2Within ( double  coneSize,
const AbsVetos vetos = AbsVetos(),
bool  skipDepositVeto = false 
) const

Definition at line 146 of file IsoDeposit.cc.

Referenced by PFCandIsolatorFromDeposits::SingleDeposit::compute(), CandIsolatorFromDeposits::SingleDeposit::compute(), and pat::helper::IsoDepositIsolator::getValue().

147 {
148  return algoWithin<Sum2Algo>(coneSize, vetos, skipDepositVeto);
149 }
double IsoDeposit::sumWithin ( double  coneSize,
const AbsVetos vetos = AbsVetos(),
bool  skipDepositVeto = false 
) const
double IsoDeposit::sumWithin ( const Direction dir,
double  coneSize,
const AbsVetos vetos = AbsVetos(),
bool  skipDepositVeto = false 
) const

Definition at line 142 of file IsoDeposit.cc.

References dir.

143 {
144  return algoWithin<SumAlgo>(dir, coneSize, vetos, skipDepositVeto);
145 }
dbl *** dir
Definition: mlp_gen.cc:35
const Veto& reco::IsoDeposit::veto ( ) const
inline

Get veto area.

Definition at line 73 of file IsoDeposit.h.

References theVeto.

Referenced by muonisolation::CaloExtractorByAssociator::deposits(), L3MuonCombinedRelativeIsolationProducer::produce(), and L3MuonIsolationProducer::produce().

73 { return theVeto; }
Veto theVeto
area to be excluded in computaion of depositWithin
Definition: IsoDeposit.h:246

Member Data Documentation

float reco::IsoDeposit::theCandTag
private

float tagging cand, ment to be transverse energy or pT attached to cand,

Definition at line 249 of file IsoDeposit.h.

Referenced by addCandEnergy(), and candEnergy().

DepositsMultimap reco::IsoDeposit::theDeposits
private

Definition at line 255 of file IsoDeposit.h.

Referenced by addDeposit(), algoWithin(), begin(), depositAndCountWithin(), end(), nearestDR(), and print().

Direction reco::IsoDeposit::theDirection
private

direcion of deposit (center of isolation cone)

Definition at line 243 of file IsoDeposit.h.

Referenced by addDeposit(), algoWithin(), depositAndCountWithin(), direction(), eta(), IsoDeposit(), nearestDR(), phi(), and print().

Veto reco::IsoDeposit::theVeto
private

area to be excluded in computaion of depositWithin

Definition at line 246 of file IsoDeposit.h.

Referenced by algoWithin(), depositAndCountWithin(), IsoDeposit(), nearestDR(), print(), setVeto(), and veto().