CMS 3D CMS Logo

Functions
genvalidTools Namespace Reference

Functions

def switchGenSource (process, analyzerName, source)
 
def switchGenSourceForValidation (process, source)
 
def useExternalWeight (process, analyzerName, vWeightProducerTags)
 
def useExternalWeightForValidation (process, vWeightProducerTags)
 

Function Documentation

def genvalidTools.switchGenSource (   process,
  analyzerName,
  source 
)

Definition at line 28 of file genvalidTools.py.

References edm.print().

Referenced by switchGenSourceForValidation().

28 def switchGenSource(process, analyzerName, source):
29  analyzer = getattr(process,analyzerName)
30  if analyzer != None:
31  print("Changing inputSource in "+analyzerName)
32  analyzer.hepmcCollection = source
33  setattr(process, analyzerName, analyzer)
34 
35 #function to switch to an alternative gen source (default is "generator") for all analyzers in the validation chain
S & print(S &os, JobReport::InputFile const &f)
Definition: JobReport.cc:65
def switchGenSource(process, analyzerName, source)
def genvalidTools.switchGenSourceForValidation (   process,
  source 
)

Definition at line 36 of file genvalidTools.py.

References switchGenSource().

36 def switchGenSourceForValidation(process, source):
37  process.genParticles.src = 'lhe2HepMCConverter'
38  switchGenSource(process, "basicGenParticleValidation", source)
39  switchGenSource(process, "mbueAndqcdValidation", source)
40  switchGenSource(process, "basicHepMCValidation", source)
41  switchGenSource(process, "drellYanEleValidation", source)
42  switchGenSource(process, "drellYanMuoValidation", source)
43  switchGenSource(process, "wMinusEleValidation", source)
44  switchGenSource(process, "wPlusEleValidation", source)
45  switchGenSource(process, "wMinusMuoValidation", source)
46  switchGenSource(process, "wPlusMuoValidation", source)
47  switchGenSource(process, "tauValidation", source)
48  switchGenSource(process, "duplicationChecker", source)
49 
def switchGenSource(process, analyzerName, source)
def switchGenSourceForValidation(process, source)
def genvalidTools.useExternalWeight (   process,
  analyzerName,
  vWeightProducerTags 
)

Definition at line 5 of file genvalidTools.py.

References edm.print().

Referenced by useExternalWeightForValidation().

5 def useExternalWeight(process, analyzerName, vWeightProducerTags):
6  analyzer = getattr(process,analyzerName)
7  if analyzer != None:
8  print("Changing weight in "+analyzerName)
9  analyzer.UseWeightFromHepMC = cms.bool(False)
10  analyzer.genEventInfos = vWeightProducerTags
11  setattr(process, analyzerName, analyzer)
12 
13 #function to switch to an external weight producer for all analyzers in the validation chain
def useExternalWeight(process, analyzerName, vWeightProducerTags)
Definition: genvalidTools.py:5
S & print(S &os, JobReport::InputFile const &f)
Definition: JobReport.cc:65
def genvalidTools.useExternalWeightForValidation (   process,
  vWeightProducerTags 
)

Definition at line 14 of file genvalidTools.py.

References useExternalWeight().

14 def useExternalWeightForValidation(process, vWeightProducerTags):
15  useExternalWeight(process, "basicGenParticleValidation", vWeightProducerTags)
16  useExternalWeight(process, "mbueAndqcdValidation", vWeightProducerTags)
17  useExternalWeight(process, "basicHepMCValidation", vWeightProducerTags)
18  useExternalWeight(process, "drellYanEleValidation", vWeightProducerTags)
19  useExternalWeight(process, "drellYanMuoValidation", vWeightProducerTags)
20  useExternalWeight(process, "wMinusEleValidation", vWeightProducerTags)
21  useExternalWeight(process, "wPlusEleValidation", vWeightProducerTags)
22  useExternalWeight(process, "wMinusMuoValidation", vWeightProducerTags)
23  useExternalWeight(process, "wPlusMuoValidation", vWeightProducerTags)
24  useExternalWeight(process, "tauValidation", vWeightProducerTags)
25  useExternalWeight(process, "duplicationChecker", vWeightProducerTags)
26 
27 #function to switch to an alternative gen source (default is "generator") for an analyzer in the validation chain
def useExternalWeight(process, analyzerName, vWeightProducerTags)
Definition: genvalidTools.py:5
def useExternalWeightForValidation(process, vWeightProducerTags)