CMS 3D CMS Logo

Functions | Variables

Mixing Namespace Reference

Functions

def addMixingScenario
def defineMixing
def printMe

Variables

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

Function Documentation

def Mixing::addMixingScenario (   label,
  dict 
)

Definition at line 4 of file Mixing.py.

00005                                  :
00006     global Mixing
00007     if label in Mixing:
00008         print 'duplicated definition of',label
00009     else:
00010         #try:
00011         #    m=__import__(dict['file'])
00012         #except:
00013         #    raise Exception('no file'+dict['file']+'to be loaded')
00014         Mixing[label]=dict

def Mixing::defineMixing (   dict,
  FS = False 
)

Definition at line 165 of file Mixing.py.

00166                                :
00167     commands=[]
00168     if 'N' in dict:
00169         if FS:
00170             commands.append('process.famosPileUp.PileUpSimulator.averageNumber = cms.double(%f)'%(dict['N'],))
00171         else:
00172             commands.append('process.mix.input.nbPileupEvents.averageNumber = cms.double(%f)'%(dict['N'],))
00173         dict.pop('N')
00174     if 'BX' in dict:
00175         commands.append('process.mix.bunchspace = cms.int32(%d)'%(dict['BX'],))
00176         dict.pop('BX')
00177     if 'B' in dict:
00178         commands.append('process.mix.minBunch = cms.int32(%d)'%(dict['B'][0],))
00179         commands.append('process.mix.maxBunch = cms.int32(%d)'%(dict['B'][1],))
00180         dict.pop('B')
00181     if 'F' in dict:
00182         commands.append('process.mix.input.fileNames = cms.untracked.vstring(%s)'%(repr(dict['F'])))
00183         dict.pop('F')
00184     return commands
def Mixing::printMe ( )

Definition at line 150 of file Mixing.py.

00151              :
00152     global Mixing
00153     keys = Mixing.keys()
00154     keys.sort()
00155     fskeys=[]
00156     for key in keys:
00157         if '_FS' in key:
00158             fskeys.append(key)
00159         else:
00160             print 'addMixingScenario("%s",%s)'%(key,repr(Mixing[key]))
00161 
00162     for key in fskeys:
00163         print 'addMixingScenario("%s",%s)'%(key,repr(Mixing[key]))
00164 


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 147 of file Mixing.py.

string Mixing::MixingFSDefaultKey = '2012_Summer_inTimeOnly'

Definition at line 148 of file Mixing.py.