CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ttFullLepEvtBuilder_cff.py
Go to the documentation of this file.
2 
3 
4 ################################################################################
5 # produce ttFullLepEvent structure with all necessary ingredients
6 ################################################################################
7 
8 ## std sequence to produce the ttFullLepEventHypotheses
10 
11 ## configure ttFullLepEventBuilder
13 
14 ## make ttFullLepEvent
15 makeTtFullLepEvent = cms.Sequence(makeTtFullLepHypotheses *
16  ttFullLepEvent
17  )
18 
19 
20 ################################################################################
21 ## helper functions
22 ## (examples of usage can be found in the ttFullLepEvtBuilder_cfg.py)
23 ################################################################################
24 
25 ## remove genMatch hypothesis from the process
27  process.makeTtFullLepHypotheses.remove(process.makeHypothesis_genMatch)
28  process.ttFullLepEvent.hypotheses.remove("ttFullLepHypGenMatch")
29 
30 
31 ## set a specific attribute for all hypotheses to a given value
32 ## -> this works for "jets", "leps", "mets", "maxNJets"
33 def setForAllTtFullLepHypotheses(process, attribute, value):
34  modules = ["ttFullLepHypGenMatch",
35  "ttFullLepHypKinSolution",
36  "kinSolutionTtFullLepEventHypothesis"]
37  for obj in range(len(modules)):
38  object = getattr(process, modules[obj])
39  if hasattr(object, attribute):
40  setattr(object, attribute, value)
41 
42 
43 
def removeTtFullLepHypGenMatch
helper functions (examples of usage can be found in the ttFullLepEvtBuilder_cfg.py) ...
def setForAllTtFullLepHypotheses
set a specific attribute for all hypotheses to a given value -> this works for "jets", "leps", "mets", "maxNJets"
configure ttFullLepEventBuilder
produce ttFullLepEvent structure with all necessary ingredients