Validation
EventGenerator
interface
WeightManager.h
Go to the documentation of this file.
1
#ifndef Validation_EventGenerator_WeightManager
2
#define Validation_EventGenerator_WeightManager
3
4
// Utility class, that computes the event weight,
5
// either returning the weight as stored in the HepMCCollection
6
// or returning the product of the weights stored in
7
// a vector of GenEventInfoProducts
8
9
#include "
FWCore/Utilities/interface/InputTag.h
"
10
#include "
FWCore/Utilities/interface/InputTag.h
"
11
#include "
SimDataFormats/GeneratorProducts/interface/HepMCProduct.h
"
12
#include "
FWCore/Framework/interface/ConsumesCollector.h
"
13
#include <vector>
14
15
namespace
edm
{
16
class
ParameterSet
;
17
class
Event
;
18
}
// namespace edm
19
20
class
WeightManager
{
21
public
:
22
WeightManager
(
const
edm::ParameterSet
&,
edm::ConsumesCollector
iC);
23
~WeightManager
(){};
24
25
double
weight
(
const
edm::Event
&);
26
27
private
:
28
bool
_useHepMC
;
29
std::vector<edm::InputTag>
_genEventInfos
;
30
edm::InputTag
_hepmcCollection
;
31
32
edm::EDGetTokenT<edm::HepMCProduct>
hepmcCollectionToken_
;
33
std::vector<edm::EDGetTokenT<std::vector<edm::InputTag> > >
genEventInfosTokens_
;
34
};
35
36
#endif
edm::EDGetTokenT< edm::HepMCProduct >
edm
HLT enums.
Definition:
AlignableModifier.h:19
WeightManager::WeightManager
WeightManager(const edm::ParameterSet &, edm::ConsumesCollector iC)
Definition:
WeightManager.cc:12
Event
edm::ParameterSet
Definition:
ParameterSet.h:47
ParameterSet
Definition:
Functions.h:16
WeightManager
Definition:
WeightManager.h:20
WeightManager::_genEventInfos
std::vector< edm::InputTag > _genEventInfos
Definition:
WeightManager.h:29
WeightManager::weight
double weight(const edm::Event &)
Definition:
WeightManager.cc:24
InputTag.h
WeightManager::_hepmcCollection
edm::InputTag _hepmcCollection
Definition:
WeightManager.h:30
WeightManager::_useHepMC
bool _useHepMC
Definition:
WeightManager.h:28
WeightManager::genEventInfosTokens_
std::vector< edm::EDGetTokenT< std::vector< edm::InputTag > > > genEventInfosTokens_
Definition:
WeightManager.h:33
WeightManager::~WeightManager
~WeightManager()
Definition:
WeightManager.h:23
ConsumesCollector.h
HepMCProduct.h
edm::Event
Definition:
Event.h:73
edm::InputTag
Definition:
InputTag.h:15
edm::ConsumesCollector
Definition:
ConsumesCollector.h:45
WeightManager::hepmcCollectionToken_
edm::EDGetTokenT< edm::HepMCProduct > hepmcCollectionToken_
Definition:
WeightManager.h:32
Generated for CMSSW Reference Manual by
1.8.16