Main Page
Namespaces
Classes
Package Documentation
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Pages
RecoTauTag
TauTagTools
plugins
RecoTauRandomDiscriminant.cc
Go to the documentation of this file.
1
/*
2
* Produce a tau discriminator that produces a random discriminant output,
3
* useful for testing.
4
*
5
* Author: Evan Friis, UC Davis
6
*
7
*/
8
9
#include "
RecoTauTag/RecoTau/interface/TauDiscriminationProducerBase.h
"
10
#include "TRandom3.h"
11
12
class
PFTauRandomDiscriminator
:
public
PFTauDiscriminationProducerBase
{
13
public
:
14
PFTauRandomDiscriminator
(
const
edm::ParameterSet
& pset):
15
PFTauDiscriminationProducerBase
(pset) {
16
passRate_
= pset.
getParameter
<
double
>(
"passRate"
);
17
}
18
19
double
discriminate
(
const
reco::PFTauRef
&
tau
) {
20
return
randy_
.Rndm() <
passRate_
;
21
}
22
private
:
23
TRandom3
randy_
;
24
double
passRate_
;
25
};
26
27
DEFINE_FWK_MODULE
(
PFTauRandomDiscriminator
);
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
TauDiscriminationProducerBase.h
DEFINE_FWK_MODULE
#define DEFINE_FWK_MODULE(type)
Definition:
MakerMacros.h:17
PFTauRandomDiscriminator::randy_
TRandom3 randy_
Definition:
RecoTauRandomDiscriminant.cc:23
PFTauRandomDiscriminator::PFTauRandomDiscriminator
PFTauRandomDiscriminator(const edm::ParameterSet &pset)
Definition:
RecoTauRandomDiscriminant.cc:14
metsig::tau
Definition:
SignAlgoResolutions.h:41
TauDiscriminationProducerBase
Definition:
TauDiscriminationProducerBase.h:47
PFTauRandomDiscriminator::passRate_
double passRate_
Definition:
RecoTauRandomDiscriminant.cc:24
edm::ParameterSet
Definition:
ParameterSet.h:35
PFTauRandomDiscriminator
Definition:
RecoTauRandomDiscriminant.cc:12
edm::Ref< PFTauCollection >
PFTauRandomDiscriminator::discriminate
double discriminate(const reco::PFTauRef &tau)
Definition:
RecoTauRandomDiscriminant.cc:19
Generated for CMSSW Reference Manual by
1.8.5