CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Functions | Variables
Mixing Namespace Reference

Functions

def addMixingScenario
 
def defineMixing
 
def printMe
 

Variables

dictionary Mixing = {}
 
string MixingDefaultKey = '2012_Summer_50ns_PoissonOOTPU'
 full sim section More...
 
string MixingFSDefaultKey = '2012_Summer_inTimeOnly'
 

Function Documentation

def Mixing.addMixingScenario (   label,
  dict 
)

Definition at line 4 of file Mixing.py.

4 
5 def addMixingScenario(label,dict):
6  global Mixing
7  if label in Mixing:
8  print 'duplicated definition of',label
9  else:
10  #try:
11  # m=__import__(dict['file'])
12  #except:
13  # raise Exception('no file'+dict['file']+'to be loaded')
14  Mixing[label]=dict
def addMixingScenario
Definition: Mixing.py:4
def Mixing.defineMixing (   dict,
  FS = False 
)

Definition at line 179 of file Mixing.py.

180 def defineMixing(dict,FS=False):
181  commands=[]
182  if 'N' in dict:
183  if FS:
184  commands.append('process.famosPileUp.PileUpSimulator.averageNumber = cms.double(%f)'%(dict['N'],))
185  else:
186  commands.append('process.mix.input.nbPileupEvents.averageNumber = cms.double(%f)'%(dict['N'],))
187  dict.pop('N')
188  if 'BX' in dict:
189  commands.append('process.mix.bunchspace = cms.int32(%d)'%(dict['BX'],))
190  dict.pop('BX')
191  if 'B' in dict:
192  commands.append('process.mix.minBunch = cms.int32(%d)'%(dict['B'][0],))
193  commands.append('process.mix.maxBunch = cms.int32(%d)'%(dict['B'][1],))
194  dict.pop('B')
195  if 'F' in dict:
196  commands.append('process.mix.input.fileNames = cms.untracked.vstring(%s)'%(repr(dict['F'])))
197  dict.pop('F')
198  return commands
def defineMixing
Definition: Mixing.py:179
def Mixing.printMe ( )

Definition at line 164 of file Mixing.py.

165 def printMe():
166  global Mixing
167  keys = Mixing.keys()
168  keys.sort()
169  fskeys=[]
170  for key in keys:
171  if '_FS' in key:
172  fskeys.append(key)
173  else:
174  print 'addMixingScenario("%s",%s)'%(key,repr(Mixing[key]))
175 
176  for key in fskeys:
177  print 'addMixingScenario("%s",%s)'%(key,repr(Mixing[key]))
178 
def printMe
Definition: Mixing.py:164

Variable Documentation

dictionary Mixing.Mixing = {}

Definition at line 1 of file Mixing.py.

string Mixing.MixingDefaultKey = '2012_Summer_50ns_PoissonOOTPU'

full sim section

fastsim section

Definition at line 161 of file Mixing.py.

string Mixing.MixingFSDefaultKey = '2012_Summer_inTimeOnly'

Definition at line 162 of file Mixing.py.