CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
trackingPlots.TrackingIterationOrder Class Reference

Public Member Functions

def __call__ (self, tdirectory, labels)
 
def __init__ (self)
 

Private Member Functions

def _findOrder (self, f)
 

Private Attributes

 _cache
 

Detailed Description

Definition at line 1722 of file trackingPlots.py.

Constructor & Destructor Documentation

def trackingPlots.TrackingIterationOrder.__init__ (   self)

Member Function Documentation

def trackingPlots.TrackingIterationOrder.__call__ (   self,
  tdirectory,
  labels 
)

Definition at line 1737 of file trackingPlots.py.

References DTCache< T, Coll >._cache, tkal_create_file_lists.FileListCreator._cache, L1MuDTTrackFinder._cache, L1MuBMTrackFinder._cache, DTTrig._cache, trackingPlots.TimePerEventPlot._cache, trackingPlots.TrackingIterationOrder._cache, trackingPlots.TrackingIterationOrder._findOrder(), list(), and FastTimerService_cff.range.

1737  def __call__(self, tdirectory, labels):
1738  ret = list(range(0, len(labels)))
1739  f = tdirectory.GetFile()
1740  if not f:
1741  return ret
1742 
1743  if not f.GetName() in self._cache:
1744  r = self._findOrder(f)
1745  if r is None:
1746  return ret
1747  self._cache[f.GetName()] = r
1748  order = self._cache[f.GetName()]
1749 
1750  # O(N^2) I know, but we're talking about O(10) elements...
1751  orderIndices = []
1752  for l in order:
1753  try:
1754  orderIndices.append(labels.index(l))
1755  except ValueError:
1756  pass
1757  ret = []
1758  for i, l in enumerate(labels):
1759  if l in order:
1760  try:
1761  found = orderIndices.index(i)
1762  if found == 0:
1763  ret.append(i)
1764  else:
1765  ret.append(orderIndices[0])
1766  except ValueError:
1767  ret.append(orderIndices[0])
1768  orderIndices.pop(0)
1769  else:
1770  ret.append(i)
1771  return ret
1772 
def __call__(self, tdirectory, labels)
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger list("!*","!HLTx*"if it matches 2 triggers or more) will accept the event if all the matching triggers are FAIL.It will reject the event if any of the triggers are PASS or EXCEPTION(this matches the behavior of"!*"before the partial wildcard feature was incorporated).Triggers which are in the READY state are completely ignored.(READY should never be returned since the trigger paths have been run
def trackingPlots.TrackingIterationOrder._findOrder (   self,
  f 
)
private

Definition at line 1726 of file trackingPlots.py.

References FastTimerService_cff.range, and python.rootplot.root2matplotlib.replace().

Referenced by trackingPlots.TrackingIterationOrder.__call__().

1726  def _findOrder(self, f):
1727  h = f.Get(_trackingIterationOrderHistogram)
1728  if not h:
1729  return None
1730  xaxis = h.GetXaxis()
1731  def _edit(s):
1732  # remove "Tracks" from the track producer name to get the iteration name
1733  # muonSeeded iterations do not have "Step" in the producer name, so add it here
1734  return s.replace("Tracks", "").replace("muonSeeded", "muonSeededStep")
1735  return [_edit(xaxis.GetBinLabel(i)) for i in range(1, h.GetNbinsX()+1)]
1736 
def replace(string, replacements)

Member Data Documentation

trackingPlots.TrackingIterationOrder._cache
private

Definition at line 1724 of file trackingPlots.py.

Referenced by trackingPlots.TrackingIterationOrder.__call__().