CMS 3D CMS Logo

Generator_cff.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 #
4 # generator level info
5 #
12 # Vertex smearing
13 #
14 # There're several types of Vertex smearing module (Gauss, Flat, BeamProfile, Betafunc, BetafuncEarlyCollisions);
15 # the cff's are available for each one :
16 # Configuration/StandardSequences/data/VtxSmearedGauss.cff
17 # Configuration/StandardSequences/data/VtxSmearedFlat.cff
18 # Configuration/StandardSequences/data/VtxSmearedBeamProfile.cff
19 # Configuration/StandardSequences/data/VtxSmearedBetafuncNominalCollision.cff
20 # Configuration/StandardSequences/data/VtxSmearedBetafuncEarlyCollision.cff
21 #
22 # Either of the above returns label "generatorSmeared" that is already in the path below
23 # (but not included here!!!)
24 #
25 # Note 1 : one and only label is allowed for either of these modules,
26 # that is VtxSmeared (the reason is not to allow multiple smearing);
27 # an attempt to use any other label will cause the Fwk to throw
28 # Note 2 : because only one label is allowed, a user can have only one
29 # instance of the Vertex smearing module in a given configuration;
30 # in other words, if you put in 2 or all 3 of the available cfi's,
31 # the Fwk will throw
32 #
33 # Currently, we suggest using Betafunc vertex smearing in the desired LHC configuration
34 #
35 # The vertex smearing needs to be called before the particle candidate generation
36 #
37 # REMINDER : vertex smearing need a startup seed;
38 # in your cfg, do NOT forget to give seeds via RandomNumberGeneratorService !!!
39 #
40 # Example configuration of the RandomNumberGeneratorService to appear in cfg:
41 # service = RandomNumberGeneratorService
42 # {
43 # untracked uint32 sourceSeed = 123456789
44 # PSet moduleSeeds =
45 # {
46 # untracked uint32 VtxSmeared = 98765432
47 # }
48 # }
49 
50 GeneInfoTask = cms.Task(genParticles)
51 genJetMETTask = cms.Task(genJetParticlesTask, recoGenJetsTask, genMETParticlesTask, recoGenMETTask)
52 
53 VertexSmearing = cms.Sequence(cms.SequencePlaceholder("VtxSmeared"))
54 GenSmeared = cms.Sequence(generatorSmeared)
55 GeneInfo = cms.Sequence(GeneInfoTask)
56 genJetMET = cms.Sequence(genJetMETTask)
57 
59 pgen = cms.Sequence(cms.SequencePlaceholder("randomEngineStateProducer")+VertexSmearing+GenSmeared+GeneInfo+genJetMET, PPSTransportTask)
60 
61 # sequence for bare generator result only, without vertex smearing and analysis objects added
62 
63 pgen_genonly = cms.Sequence(cms.SequencePlaceholder("randomEngineStateProducer"))
64 
65 fixGenInfoTask = cms.Task(GeneInfoTask, genJetMETTask)
66 fixGenInfo = cms.Sequence(fixGenInfoTask)
67 
68 
70 genstepfilter = HLTrigger.HLTfilters.triggerResultsFilter_cfi.triggerResultsFilter.clone(
71  l1tResults = cms.InputTag(''),
72  hltResults = cms.InputTag('TriggerResults'),
73  triggerConditions = cms.vstring()
74 )