3 import globalDictionaries
4 from genericValidation
import GenericValidationData
5 from helperFunctions
import replaceByMap
6 from TkAlExceptions
import AllInOneError
10 def __init__(self, valName, alignment, config,
11 configBaseName =
"TkAlZMuMuValidation", scriptBaseName =
"TkAlZMuMuValidation", crabCfgBaseName =
"TkAlZMuMuValidation",
12 resultBaseName =
"ZMuMuValidation", outputBaseName =
"ZMuMuValidation"):
14 "zmumureference": (
"/store/caf/user/emiglior/Alignment/TkAlDiMuonValidation/Reference/BiasCheck_DYToMuMu_Summer12_TkAlZMuMu_IDEAL.root"),
17 mandatories = [
"etamaxneg",
"etaminneg",
"etamaxpos",
"etaminpos"]
24 GenericValidationData.__init__(self, valName, alignment, config,
25 "zmumu", addDefaults=defaults,
26 addMandatories=mandatories)
27 if self.
general[
"zmumureference"].startswith(
"/store"):
28 self.
general[
"zmumureference"] =
"root://eoscms//eos/cms" + self.
general[
"zmumureference"]
30 raise AllInOneError(
"Parallel jobs not implemented for the Z->mumu validation!\n"
31 "Please set parallelJobs = 1.")
35 self.alignmentToValidate.name )
37 cfgs = {cfgName: configTemplates.ZMuMuValidationTemplate}
38 GenericValidationData.createConfiguration(self, cfgs, path, repMap = repMap)
41 return GenericValidationData.createScript(self, path, template = configTemplates.zMuMuScriptTemplate)
44 return GenericValidationData.createCrabCfg(self, path, self.
crabCfgBaseName)
49 repMap = GenericValidationData.getRepMap(self, alignment)
51 "nEvents": self.
general[
"maxevents"],
52 "outputFile": (
"0_zmumuHisto.root"
53 ",genSimRecoPlots.root"
54 ",FitParameters.txt"),
56 "workingdir":
".oO[datadir]Oo./%s/%s/%s" % (self.
outputBaseName, self.
name, alignment.name),
57 "plotsdir":
".oO[datadir]Oo./%s/%s/%s/plots" % (self.
outputBaseName, self.
name, alignment.name),