CMS 3D CMS Logo

Classes | Functions | Variables
makeTrackValidationPlots Namespace Reference

Classes

class  LimitTrackAlgo
 

Functions

def limitRelVal (algo, quality)
 
def main (opts)
 

Variables

 action
 
 default
 
 description
 
 group
 
 help
 
 limit_tracking_algo
 
 metavar
 
 nargs
 
 opts
 
 parser
 
 str
 
 type
 

Function Documentation

def makeTrackValidationPlots.limitRelVal (   algo,
  quality 
)

Definition at line 23 of file makeTrackValidationPlots.py.

23 def limitRelVal(algo, quality):
24  return quality in ["", "highPurity", "ByOriginalAlgo", "highPurityByOriginalAlgo"]
25 
def makeTrackValidationPlots.main (   opts)

Definition at line 26 of file makeTrackValidationPlots.py.

References edm.print().

26 def main(opts):
27  sample = SimpleSample(opts.subdirprefix, opts.html_sample, [(f, f.replace(".root", "")) for f in opts.files])
28 
29  drawArgs={}
30  if opts.no_ratio:
31  drawArgs["ratio"] = False
32  if opts.separate:
33  drawArgs["separate"] = True
34  if opts.png:
35  drawArgs["saveFormat"] = ".png"
36  if opts.verbose:
37  plotting.verbose = True
38 
39  val = SimpleValidation([sample], opts.outputDir)
40  htmlReport = val.createHtmlReport(validationName=opts.html_validation_name)
41 
42  limitProcessing = LimitTrackAlgo(opts.limit_tracking_algo, includePtCut=opts.ptcut)
43  kwargs_tracking = {
44  "limitSubFoldersOnlyTo": {
45  "": limitProcessing,
46  "allTPEffic": limitProcessing,
47  "fromPV": limitProcessing,
48  "fromPVAllTP": limitProcessing,
49  "tpPtLess09": limitProcessing,
50  "seeding": limitProcessing,
51  "building": limitProcessing,
52  "bhadron": limitProcessing,
53  }
54  }
55  if opts.limit_relval:
56  ignore = lambda a,q: False
57  kwargs_tracking["limitSubFoldersOnlyTo"] = {
58  "": limitRelVal,
59  "allTPEffic": ignore,
60  "fromPV": ignore,
61  "fromPVAllTP": ignore,
62  "tpPtLess09": limitRelVal,
63  "seeding": ignore,
64  "bhadron": limitRelVal,
65  }
66 
67  trk = [trackingPlots.plotter]
68  other = [trackingPlots.timePlotter, vertexPlots.plotter, trackingPlots.plotterHLT]
69  if opts.extended:
70  trk.append(trackingPlots.plotterExt)
71  other.extend([vertexPlots.plotterExt, trackingPlots.plotterHLTExt])
72  val.doPlots(trk, plotterDrawArgs=drawArgs, **kwargs_tracking)
73  val.doPlots(other, plotterDrawArgs=drawArgs)
74  print()
75  if opts.no_html:
76  print("Plots created into directory '%s'." % opts.outputDir)
77  else:
78  htmlReport.write()
79  print("Plots and HTML report created into directory '%s'. You can just move it to some www area and access the pages via web browser" % opts.outputDir)
80 
S & print(S &os, JobReport::InputFile const &f)
Definition: JobReport.cc:66

Variable Documentation

makeTrackValidationPlots.action

Definition at line 89 of file makeTrackValidationPlots.py.

makeTrackValidationPlots.default

Definition at line 85 of file makeTrackValidationPlots.py.

makeTrackValidationPlots.description

Definition at line 82 of file makeTrackValidationPlots.py.

makeTrackValidationPlots.group

Definition at line 112 of file makeTrackValidationPlots.py.

makeTrackValidationPlots.help

Definition at line 84 of file makeTrackValidationPlots.py.

makeTrackValidationPlots.limit_tracking_algo

Definition at line 137 of file makeTrackValidationPlots.py.

makeTrackValidationPlots.metavar

Definition at line 83 of file makeTrackValidationPlots.py.

makeTrackValidationPlots.nargs

Definition at line 83 of file makeTrackValidationPlots.py.

makeTrackValidationPlots.opts

Definition at line 120 of file makeTrackValidationPlots.py.

makeTrackValidationPlots.parser

Definition at line 82 of file makeTrackValidationPlots.py.

makeTrackValidationPlots.str

Definition at line 83 of file makeTrackValidationPlots.py.

makeTrackValidationPlots.type

Definition at line 83 of file makeTrackValidationPlots.py.