Main Page
Namespaces
Classes
Package Documentation
RecoBTag
SoftLepton
src
LeptonTaggerByPt.cc
Go to the documentation of this file.
1
#include <limits>
2
3
#include "
DataFormats/BTauReco/interface/CandSoftLeptonTagInfo.h
"
4
#include "
RecoBTag/SoftLepton/interface/LeptonTaggerByPt.h
"
5
#include "
RecoBTag/SoftLepton/interface/LeptonSelector.h
"
6
8
float
LeptonTaggerByPt::discriminator
(
const
TagInfoHelper
& tagInfo)
const
{
9
// default value, used if there are no leptons associated to this jet
10
float
bestTag = -
std::numeric_limits<float>::infinity
();
11
const
reco::CandSoftLeptonTagInfo
&
info
= tagInfo.
get
<
reco::CandSoftLeptonTagInfo
>();
12
// if there are multiple leptons, look for the one with the highest pT_rel
13
for
(
unsigned
int
i
= 0;
i
< info.
leptons
();
i
++) {
14
const
reco::SoftLeptonProperties
& properties = info.
properties
(
i
);
15
if
(
m_selector
(properties)) {
16
float
tag
= properties.
ptRel
;
17
if
(tag > bestTag)
18
bestTag =
tag
;
19
}
20
}
21
return
bestTag;
22
}
reco::SoftLeptonProperties::ptRel
float ptRel
Definition:
TemplatedSoftLeptonTagInfo.h:36
reco::TemplatedSoftLeptonTagInfo
Definition:
TemplatedSoftLeptonTagInfo.h:117
info
static const TGPicture * info(bool iBackgroundIsBlack)
Definition:
FWCollectionSummaryWidget.cc:170
JetTagComputer::TagInfoHelper::get
const T & get(unsigned int index=0) const
Definition:
JetTagComputer.h:49
GlobalPosition_Frontier_DevDB_cff.tag
tag
Definition:
GlobalPosition_Frontier_DevDB_cff.py:11
mps_fire.i
i
Definition:
mps_fire.py:338
LeptonTaggerByPt::discriminator
float discriminator(const TagInfoHelper &tagInfo) const override
b-tag a jet based on track-to-jet parameters in the extened info collection
Definition:
LeptonTaggerByPt.cc:8
JetTagComputer::TagInfoHelper
Definition:
JetTagComputer.h:16
reco::TemplatedSoftLeptonTagInfo::properties
const SoftLeptonProperties & properties(size_t i) const
Definition:
TemplatedSoftLeptonTagInfo.h:135
LeptonSelector.h
infinity
const double infinity
Definition:
CSCChamberFitter.cc:10
LeptonTaggerByPt.h
LeptonTaggerByPt::m_selector
btag::LeptonSelector m_selector
Definition:
LeptonTaggerByPt.h:34
reco::SoftLeptonProperties
Definition:
TemplatedSoftLeptonTagInfo.h:15
reco::TemplatedSoftLeptonTagInfo::leptons
unsigned int leptons(void) const
Definition:
TemplatedSoftLeptonTagInfo.h:127
CandSoftLeptonTagInfo.h
Generated for CMSSW Reference Manual by
1.8.11