CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
vertexPlots.VertexSummaryTable Class Reference

Public Member Functions

def __init__ (self, page="vertex")
 
def create (self, tdirectory)
 
def getPage (self)
 
def getPurpose (self)
 
def getSection (self, dqmSubFolder)
 
def headers (self)
 

Private Attributes

 _page
 
 _purpose
 

Detailed Description

Definition at line 366 of file vertexPlots.py.

Constructor & Destructor Documentation

◆ __init__()

def vertexPlots.VertexSummaryTable.__init__ (   self,
  page = "vertex" 
)

Definition at line 367 of file vertexPlots.py.

367  def __init__(self, page="vertex"):
368  self._purpose = PlotPurpose.Vertexing
369  self._page = page
370 
def __init__(self, dataset, job_number, job_id, job_name, isDA, isMC, applyBOWS, applyEXTRACOND, extraconditions, runboundary, lumilist, intlumi, maxevents, gt, allFromGT, alignmentDB, alignmentTAG, apeDB, apeTAG, bowDB, bowTAG, vertextype, tracktype, refittertype, ttrhtype, applyruncontrol, ptcut, CMSSW_dir, the_dir)

Member Function Documentation

◆ create()

def vertexPlots.VertexSummaryTable.create (   self,
  tdirectory 
)

Definition at line 380 of file vertexPlots.py.

References dqmMemoryStats.float, EcalMonitorTask_cff.func, createfilelist.int, and FastTimerService_cff.range.

380  def create(self, tdirectory):
381  def _formatOrNone(num, func):
382  if num is None:
383  return None
384  return func(num)
385 
386  ret = []
387  h = tdirectory.Get("TruePVLocationIndexCumulative")
388  if h:
389  n_events = h.GetEntries()
390  n_pvtagged = h.GetBinContent(2)
391  ret.extend([int(n_events), "%.4f"%(float(n_pvtagged)/float(n_events))])
392  else:
393  ret.extend([None, None])
394 
395  h = tdirectory.Get("globalEfficiencies")
396  if h:
397  d = {}
398  for i in range(1, h.GetNbinsX()+1):
399  d[h.GetXaxis().GetBinLabel(i)] = h.GetBinContent(i)
400  ret.extend([
401  _formatOrNone(d.get("effic_vs_Z", None), lambda n: "%.4f"%n),
402  _formatOrNone(d.get("fakerate_vs_Z", None), lambda n: "%.4f"%n),
403  _formatOrNone(d.get("merged_vs_Z", None), lambda n: "%.4f"%n),
404  _formatOrNone(d.get("duplicate_vs_Z", None), lambda n: "%.4f"%n),
405  ])
406  else:
407  ret.extend([None]*4)
408 
409  if ret.count(None) == len(ret):
410  return None
411 
412  return ret
413 
def create(alignables, pedeDump, additionalData, outputFile, config)

◆ getPage()

def vertexPlots.VertexSummaryTable.getPage (   self)

◆ getPurpose()

def vertexPlots.VertexSummaryTable.getPurpose (   self)

◆ getSection()

def vertexPlots.VertexSummaryTable.getSection (   self,
  dqmSubFolder 
)

Definition at line 377 of file vertexPlots.py.

377  def getSection(self, dqmSubFolder):
378  return dqmSubFolder
379 

◆ headers()

def vertexPlots.VertexSummaryTable.headers (   self)

Definition at line 414 of file vertexPlots.py.

414  def headers(self):
415  return [
416  "Events",
417  "PV reco+tag efficiency",
418  "Efficiency",
419  "Fake rate",
420  "Merge rate",
421  "Duplicate rate",
422  ]
423 

Member Data Documentation

◆ _page

vertexPlots.VertexSummaryTable._page
private

Definition at line 369 of file vertexPlots.py.

Referenced by vertexPlots.VertexSummaryTable.getPage().

◆ _purpose

vertexPlots.VertexSummaryTable._purpose
private

Definition at line 368 of file vertexPlots.py.

Referenced by vertexPlots.VertexSummaryTable.getPurpose().