RecoTauTag
RecoTau
interface
PFRecoTauChargedHadronPlugins.h
Go to the documentation of this file.
1
#ifndef RecoTauTag_RecoTau_PFRecoTauChargedHadronPlugins_h
2
#define RecoTauTag_RecoTau_PFRecoTauChargedHadronPlugins_h
3
4
/*
5
* PFRecoTauChargedHadronPlugins
6
*
7
* Author: Christian Veelken, LLR
8
*
9
* Base classes for plugins that construct and rank PFRecoTauChargedHadron
10
* objects from a jet. The builder plugin has an abstract function
11
* that takes a Jet and returns a list of reconstructed photons in
12
* the jet.
13
*
14
* The quality plugin has an abstract function that takes a reference
15
* to a PFRecoTauChargedHadron and returns a double indicating the quality of
16
* the candidate. Lower numbers are better.
17
*
18
*/
19
20
#include <vector>
21
#include <boost/ptr_container/ptr_vector.hpp>
22
#include "
DataFormats/ParticleFlowCandidate/interface/PFCandidateFwd.h
"
23
#include "
RecoTauTag/RecoTau/interface/RecoTauPluginsCommon.h
"
24
25
#include "
FWCore/Framework/interface/ConsumesCollector.h
"
26
27
namespace
reco
{
28
29
// Forward declarations
30
class
Jet
;
31
class
PFRecoTauChargedHadron;
32
33
namespace
tau
{
34
35
class
PFRecoTauChargedHadronBuilderPlugin
:
public
RecoTauEventHolderPlugin
{
36
public
:
37
// Return a vector of pointers
38
typedef
boost::ptr_vector<PFRecoTauChargedHadron>
ChargedHadronVector
;
39
// Storing the result in an auto ptr on function return allows
40
// allows us to safely release the ptr_vector in the virtual function
41
typedef
std::unique_ptr<ChargedHadronVector>
return_type
;
42
explicit
PFRecoTauChargedHadronBuilderPlugin
(
const
edm::ParameterSet
&
pset
,
edm::ConsumesCollector
&& iC)
43
:
RecoTauEventHolderPlugin
(
pset
) {}
44
~PFRecoTauChargedHadronBuilderPlugin
()
override
{}
46
virtual
return_type
operator()
(
const
Jet
&)
const
= 0;
48
void
beginEvent
()
override
{}
49
};
50
51
class
PFRecoTauChargedHadronQualityPlugin
:
public
RecoTauNamedPlugin
{
52
public
:
53
explicit
PFRecoTauChargedHadronQualityPlugin
(
const
edm::ParameterSet
&
pset
) :
RecoTauNamedPlugin
(
pset
) {}
54
~PFRecoTauChargedHadronQualityPlugin
()
override
{}
56
virtual
double
operator()
(
const
PFRecoTauChargedHadron
&)
const
= 0;
57
};
58
59
}
// namespace tau
60
}
// namespace reco
61
62
#include "
FWCore/PluginManager/interface/PluginFactory.h
"
63
64
typedef
edmplugin::PluginFactory
<
reco::tau::PFRecoTauChargedHadronQualityPlugin
*(
const
edm::ParameterSet
&)>
65
PFRecoTauChargedHadronQualityPluginFactory
;
66
typedef
edmplugin::PluginFactory
<
reco::tau::PFRecoTauChargedHadronBuilderPlugin
*(
const
edm::ParameterSet
&,
67
edm::ConsumesCollector
&& iC)>
68
PFRecoTauChargedHadronBuilderPluginFactory
;
69
70
#endif
reco::tau::PFRecoTauChargedHadronQualityPlugin::~PFRecoTauChargedHadronQualityPlugin
~PFRecoTauChargedHadronQualityPlugin() override
Definition:
PFRecoTauChargedHadronPlugins.h:54
PluginFactory.h
reco::tau::PFRecoTauChargedHadronBuilderPlugin
Definition:
PFRecoTauChargedHadronPlugins.h:35
metsig::tau
Definition:
SignAlgoResolutions.h:49
reco
fixed size matrix
Definition:
AlignmentAlgorithmBase.h:46
reco::PFRecoTauChargedHadron
Definition:
PFRecoTauChargedHadron.h:23
reco::tau::PFRecoTauChargedHadronQualityPlugin::PFRecoTauChargedHadronQualityPlugin
PFRecoTauChargedHadronQualityPlugin(const edm::ParameterSet &pset)
Definition:
PFRecoTauChargedHadronPlugins.h:53
RecoTauPluginsCommon.h
Jet
Definition:
Jet.py:1
reco::tau::RecoTauNamedPlugin
Definition:
RecoTauPluginsCommon.h:30
reco::tau::PFRecoTauChargedHadronBuilderPlugin::beginEvent
void beginEvent() override
Hook called at the beginning of the event.
Definition:
PFRecoTauChargedHadronPlugins.h:48
reco::tau::PFRecoTauChargedHadronBuilderPlugin::operator()
virtual return_type operator()(const Jet &) const =0
Build a collection of chargedHadrons from objects in the input jet.
reco::tau::RecoTauEventHolderPlugin
Definition:
RecoTauPluginsCommon.h:41
reco::tau::PFRecoTauChargedHadronBuilderPlugin::ChargedHadronVector
boost::ptr_vector< PFRecoTauChargedHadron > ChargedHadronVector
Definition:
PFRecoTauChargedHadronPlugins.h:38
reco::tau::PFRecoTauChargedHadronBuilderPlugin::return_type
std::unique_ptr< ChargedHadronVector > return_type
Definition:
PFRecoTauChargedHadronPlugins.h:41
edm::ParameterSet
Definition:
ParameterSet.h:47
edmplugin::PluginFactory
Definition:
PluginFactory.h:34
reco::tau::PFRecoTauChargedHadronBuilderPlugin::PFRecoTauChargedHadronBuilderPlugin
PFRecoTauChargedHadronBuilderPlugin(const edm::ParameterSet &pset, edm::ConsumesCollector &&iC)
Definition:
PFRecoTauChargedHadronPlugins.h:42
reco::tau::PFRecoTauChargedHadronBuilderPlugin::~PFRecoTauChargedHadronBuilderPlugin
~PFRecoTauChargedHadronBuilderPlugin() override
Definition:
PFRecoTauChargedHadronPlugins.h:44
reco::tau::PFRecoTauChargedHadronQualityPlugin::operator()
virtual double operator()(const PFRecoTauChargedHadron &) const =0
Return a number indicating the quality of this chargedHadron.
reco::tau::PFRecoTauChargedHadronQualityPlugin
Definition:
PFRecoTauChargedHadronPlugins.h:51
ConsumesCollector.h
edm::ConsumesCollector
Definition:
ConsumesCollector.h:45
muonDTDigis_cfi.pset
pset
Definition:
muonDTDigis_cfi.py:27
PFCandidateFwd.h
Generated for CMSSW Reference Manual by
1.8.16