CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor Class Reference
Inheritance diagram for Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor:
Vispa.Share.BasicDataAccessor.BasicDataAccessor

Public Member Functions

def __init__ (self)
 
def addBranches (self, name, branches)
 
def addConfig (self, accessor)
 
def addContentFile (self, filename)
 
def addContents (self, content, content2)
 
def applyCommands (self, content, outputCommands)
 
def children (self, object)
 
def clear (self)
 
def compareEntry (self, entry1, entry2)
 
def eventContentsList (self)
 
def inContent (self, entry, content)
 
def isContainer (self, object)
 
def label (self, object)
 
def properties (self, object)
 
def topLevelObjects (self)
 
- Public Member Functions inherited from Vispa.Share.BasicDataAccessor.BasicDataAccessor
def addProperty (self, object, name, value, type)
 
def allChildren (self, object)
 
def children (self, object)
 
def isContainer (self, object)
 
def label (self, object)
 
def properties (self, object)
 
def property (self, object, name)
 
def propertyValue (self, object, name)
 
def removeProperty (self, object, name)
 
def setProperty (self, object, name, value, categoryName)
 
def topLevelObjects (self)
 

Private Attributes

 _configAccessors
 
 _eventContents
 

Detailed Description

Definition at line 9 of file EventContentDataAccessor.py.

Constructor & Destructor Documentation

def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.__init__ (   self)

Member Function Documentation

def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.addBranches (   self,
  name,
  branches 
)

Definition at line 69 of file EventContentDataAccessor.py.

References Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor._eventContents.

Referenced by Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.addContentFile().

69  def addBranches(self,name,branches):
70  content = []
71  for branch in branches:
72  type = branch[0]
73  label = branch[1]
74  product = branch[2]
75  process = branch[3]
76  content += [(type,label,product,process)]
77  self._eventContents += [(name, content, False, {})]
78 
def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.addConfig (   self,
  accessor 
)

Definition at line 46 of file EventContentDataAccessor.py.

References Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor._eventContents, Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.addContents(), Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.applyCommands(), and Vispa.Plugins.ConfigEditor.ConfigDataAccessor.ConfigDataAccessor.applyCommands().

46  def addConfig(self, accessor):
47  if not accessor:
48  return
49  configName=os.path.splitext(os.path.basename(accessor.configFile()))[0]
50  name = "Input: " + configName
51  inputContent=accessor.inputEventContent()
52  self._eventContents += [(name, inputContent[0], True, inputContent[1])]
53  output_content=[]
54  if len(self._eventContents)>1:
55  self.addContents(output_content,self._eventContents[-2][1])
56  output_content=self.applyCommands(output_content,accessor.inputCommands())
57  self.addContents(output_content,accessor.outputEventContent())
58  output_content=self.applyCommands(output_content,accessor.outputCommands())
59  name = "Output: " + configName
60  self._eventContents += [(name, output_content, False, {})]
61 
def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.addContentFile (   self,
  filename 
)

Definition at line 62 of file EventContentDataAccessor.py.

References Tracker_OldtoNewConverter.addBranches(), Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.addBranches(), TrackerGeometryIntoNtuples.addBranches(), and split.

62  def addContentFile(self, filename):
63  accessor=EdmDataAccessor()
64  accessor.open(filename)
65  branches=[branch[0].split("_") for branch in accessor.filteredBranches()]
66  name = os.path.splitext(os.path.basename(filename))[0]
67  self.addBranches(name,branches)
68 
double split
Definition: MVATrainer.cc:139
def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.addContents (   self,
  content,
  content2 
)
def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.applyCommands (   self,
  content,
  outputCommands 
)

Definition at line 88 of file EventContentDataAccessor.py.

Referenced by Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.addConfig().

88  def applyCommands(self, content, outputCommands):
89  keep = {}
90  if len(outputCommands)>0 and outputCommands[0]!="keep *":
91  for object in content:
92  keep[object] = False
93  else:
94  for object in content:
95  keep[object] = True
96  for o in outputCommands:
97  command, filter = o.split(" ")
98  if len(filter.split("_")) > 1:
99  module = filter.split("_")[1]
100  product = filter.split("_")[2]
101  process = filter.split("_")[3]
102  else:
103  module = filter
104  product = "*"
105  process = "*"
106  for object in content:
107  if "*" in module:
108  match = module.strip("*") in object[1]
109  else:
110  match = module == object[1]
111  if "*" in product:
112  match = match and product.strip("*") in object[2]
113  else:
114  match = match and product == object[2]
115  if "*" in process:
116  match = match and process.strip("*") in object[3]
117  else:
118  match = match and process == object[3]
119  if match:
120  keep[object] = command == "keep"
121  return [object for object in content if keep[object]]
122 
def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.children (   self,
  object 
)

Definition at line 14 of file EventContentDataAccessor.py.

Referenced by Vispa.Share.BasicDataAccessor.BasicDataAccessor.allChildren(), Vispa.Views.LineDecayView.LineDecayView.autolayout(), Vispa.Views.BoxDecayView.BoxDecayContainer.autolayoutAlgorithm(), Vispa.Gui.WidgetContainer.WidgetContainer.autolayoutChildren(), Vispa.Gui.WidgetContainer.WidgetContainer.autosize(), Vispa.Views.LineDecayView.LineDecayContainer.childContainer(), Vispa.Views.WidgetView.WidgetView.clear(), Vispa.Views.LineDecayView.LineDecayContainer.createDecayObjectsFromPxlObject(), Vispa.Gui.ConnectableWidgetOwner.ConnectableWidgetOwner.deleteSelectedConnections(), Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner.deselectAllWidgets(), Vispa.Gui.ConnectableWidgetOwner.ConnectableWidgetOwner.getWidgetByName(), Vispa.Gui.ConnectableWidgetOwner.ConnectableWidgetOwner.hideMenuWidgets(), Vispa.Views.LineDecayView.LineDecayView.lineDecayContainer(), Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner.mouseReleaseEvent(), Vispa.Gui.ConnectableWidgetOwner.ConnectableWidgetOwner.portConnection(), Vispa.Gui.ConnectableWidgetOwner.ConnectableWidgetOwner.propagateEventUnderConnectionWidget(), Vispa.Views.LineDecayView.LineDecayContainer.scheduleUpdateVisibleList(), Vispa.Views.LineDecayView.LineDecayView.scrollBarValueChanged(), Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner.selectedWidgets(), Vispa.Views.LineDecayView.LineDecayContainer.setAcceptDrops(), Vispa.Gui.VispaWidget.VispaWidget.setDragable(), Vispa.Views.LineDecayView.LineDecayView.setEditable(), Vispa.Gui.ZoomableWidget.ZoomableWidget.setZoom(), Vispa.Gui.WidgetContainer.WidgetContainer.toggleCollapse(), Vispa.Gui.ConnectableWidgetOwner.ConnectableWidgetOwner.updateConnections(), and Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner.widgetDragged().

def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.clear (   self)
def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.compareEntry (   self,
  entry1,
  entry2 
)

Definition at line 79 of file EventContentDataAccessor.py.

Referenced by Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.inContent().

79  def compareEntry(self, entry1, entry2):
80  result=True
81  for i in range(4):
82  result=result and (entry1[i]==entry2[i] or entry1[i]=="*" or entry2[i]=="*")
83  return result
84 
def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.eventContentsList (   self)
return top level objects from file, e.g. the event.

Definition at line 23 of file EventContentDataAccessor.py.

References Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor._eventContents.

def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.inContent (   self,
  entry,
  content 
)
def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.isContainer (   self,
  object 
)

Definition at line 17 of file EventContentDataAccessor.py.

17  def isContainer(self, object):
18  return False
19 
def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.label (   self,
  object 
)

Definition at line 20 of file EventContentDataAccessor.py.

References join().

20  def label(self, object):
21  return "_".join(object)
22 
static std::string join(char **cmd)
Definition: RemoteFile.cc:18
def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.properties (   self,
  object 
)
Make list of all properties 

Definition at line 39 of file EventContentDataAccessor.py.

Referenced by Vispa.Share.BasicDataAccessor.BasicDataAccessor.property().

39  def properties(self, object):
40  """ Make list of all properties """
41  properties = []
42  properties += [("Category", "Object info", "")]
43  properties += [("String", "Label", object)]
44  return properties
45 
def Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor.topLevelObjects (   self)

Definition at line 28 of file EventContentDataAccessor.py.

References Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor._eventContents, and list().

28  def topLevelObjects(self):
29  objects = []
30  for name, content, input, comment in self._eventContents:
31  objects += list(content)
32  return objects
33 
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

Member Data Documentation

Vispa.Plugins.EdmBrowser.EventContentDataAccessor.EventContentDataAccessor._configAccessors
private

Definition at line 12 of file EventContentDataAccessor.py.