CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Classes | Functions | Variables
trigTools Namespace Reference

Classes

class  RemoveCleaningFromTriggerMatching
 
class  SwitchOnTrigger
 
class  SwitchOnTriggerMatchEmbedding
 
class  SwitchOnTriggerMatching
 
class  SwitchOnTriggerMatchingStandAlone
 
class  SwitchOnTriggerStandAlone
 

Functions

def _addEventContent
 
def _modulesInSequence
 

Variables

string _defaultHltProcess = 'HLT'
 
string _defaultHltProcessComment = "HLT process name, default: %s"
 
string _defaultOutputModule = 'out'
 
string _defaultOutputModuleComment = "Output module label, empty label indicates no output, default: %s"
 
string _defaultSequence = 'patDefaultSequence'
 
string _defaultSequenceComment = "Name of sequence to use, default: %s"
 
string _defaultTriggerEventProducer = 'patTriggerEvent'
 
string _defaultTriggerEventProducerComment = "PATTriggerEventProducer module label, default: %s"
 
list _defaultTriggerMatchers
 
string _defaultTriggerMatchersComment = "Trigger matcher modules' labels, default: ..."
 
string _defaultTriggerProducer = 'patTrigger'
 
string _defaultTriggerProducerComment = "PATTriggerProducer module label, default: %s"
 
string _longLine = '---------------------------------------------------------------------'
 
tuple removeCleaningFromTriggerMatching = RemoveCleaningFromTriggerMatching()
 
tuple switchOnTrigger = SwitchOnTrigger()
 
tuple switchOnTriggerMatchEmbedding = SwitchOnTriggerMatchEmbedding()
 
tuple switchOnTriggerMatching = SwitchOnTriggerMatching()
 
tuple switchOnTriggerMatchingStandAlone = SwitchOnTriggerMatchingStandAlone()
 
tuple switchOnTriggerStandAlone = SwitchOnTriggerStandAlone()
 

Function Documentation

def trigTools._addEventContent (   outputCommands,
  eventContent 
)
private

Definition at line 34 of file trigTools.py.

Referenced by trigTools.SwitchOnTrigger.toolCode(), trigTools.SwitchOnTriggerStandAlone.toolCode(), trigTools.SwitchOnTriggerMatching.toolCode(), trigTools.SwitchOnTriggerMatchingStandAlone.toolCode(), and trigTools.SwitchOnTriggerMatchEmbedding.toolCode().

34 
35 def _addEventContent( outputCommands, eventContent ):
36  # add new entry to event content
37  for content in eventContent:
38  if content not in outputCommands:
39  outputCommands += [ content ]
40  # check for obsolete entries
41  listToRemove = []
42  for i in range( len( outputCommands ) ):
43  if i in listToRemove:
44  continue
45  command = outputCommands[ i ]
46  if command[ : 4 ] == 'keep':
47  dropCommand = command.replace( 'keep ', 'drop ' )
48  for j in range( i + 1, len( outputCommands ) ):
49  testCommand = outputCommands[ j ]
50  if testCommand == command:
51  listToRemove += [ j ]
52  elif testCommand == dropCommand:
53  listToRemove += [ i, j ]
54  break
55  # copy entries excl. obsolete ones
56  newOutputCommands = cms.untracked.vstring()
57  for i in range( len( outputCommands ) ):
58  if i not in listToRemove:
59  newOutputCommands += [ outputCommands[ i ] ]
60  # return result
61  return newOutputCommands
62 
def _addEventContent
Definition: trigTools.py:34
def trigTools._modulesInSequence (   process,
  sequenceLabel 
)
private

Definition at line 30 of file trigTools.py.

References helpers.listModules().

Referenced by trigTools.SwitchOnTrigger.toolCode(), trigTools.SwitchOnTriggerStandAlone.toolCode(), trigTools.SwitchOnTriggerMatching.toolCode(), trigTools.SwitchOnTriggerMatchingStandAlone.toolCode(), trigTools.SwitchOnTriggerMatchEmbedding.toolCode(), and trigTools.RemoveCleaningFromTriggerMatching.toolCode().

30 
31 def _modulesInSequence( process, sequenceLabel ):
32  return [ m.label() for m in listModules( getattr( process, sequenceLabel ) ) ]
33 
def listModules
Definition: helpers.py:203
def _modulesInSequence
Definition: trigTools.py:30

Variable Documentation

string trigTools._defaultHltProcess = 'HLT'

Definition at line 17 of file trigTools.py.

string trigTools._defaultHltProcessComment = "HLT process name, default: %s"

Definition at line 24 of file trigTools.py.

string trigTools._defaultOutputModule = 'out'

Definition at line 18 of file trigTools.py.

string trigTools._defaultOutputModuleComment = "Output module label, empty label indicates no output, default: %s"

Definition at line 25 of file trigTools.py.

string trigTools._defaultSequence = 'patDefaultSequence'

Definition at line 16 of file trigTools.py.

string trigTools._defaultSequenceComment = "Name of sequence to use, default: %s"

Definition at line 23 of file trigTools.py.

string trigTools._defaultTriggerEventProducer = 'patTriggerEvent'

Definition at line 15 of file trigTools.py.

string trigTools._defaultTriggerEventProducerComment = "PATTriggerEventProducer module label, default: %s"

Definition at line 22 of file trigTools.py.

list trigTools._defaultTriggerMatchers
Initial value:
1 = [ 'cleanMuonTriggerMatchHLTMu20'
2  , 'cleanMuonTriggerMatchHLTDoubleMu6'
3  , 'cleanPhotonTriggerMatchHLTPhoton26IsoVLPhoton18'
4  , 'cleanElectronTriggerMatchHLTEle27CaloIdVTCaloIsoTTrkIdTTrkIsoT'
5  , 'cleanTauTriggerMatchHLTDoubleIsoPFTau20Trk5'
6  , 'cleanJetTriggerMatchHLTJet240'
7  , 'metTriggerMatchHLTMET100'
8  ]

Definition at line 6 of file trigTools.py.

string trigTools._defaultTriggerMatchersComment = "Trigger matcher modules' labels, default: ..."

Definition at line 20 of file trigTools.py.

string trigTools._defaultTriggerProducer = 'patTrigger'

Definition at line 14 of file trigTools.py.

string trigTools._defaultTriggerProducerComment = "PATTriggerProducer module label, default: %s"

Definition at line 21 of file trigTools.py.

string trigTools._longLine = '---------------------------------------------------------------------'

Definition at line 27 of file trigTools.py.

tuple trigTools.removeCleaningFromTriggerMatching = RemoveCleaningFromTriggerMatching()

Definition at line 769 of file trigTools.py.

tuple trigTools.switchOnTrigger = SwitchOnTrigger()

Definition at line 189 of file trigTools.py.

Referenced by trigTools.SwitchOnTriggerMatching.toolCode().

tuple trigTools.switchOnTriggerMatchEmbedding = SwitchOnTriggerMatchEmbedding()

Definition at line 669 of file trigTools.py.

tuple trigTools.switchOnTriggerMatching = SwitchOnTriggerMatching()

Definition at line 424 of file trigTools.py.

tuple trigTools.switchOnTriggerMatchingStandAlone = SwitchOnTriggerMatchingStandAlone()

Definition at line 529 of file trigTools.py.

Referenced by trigTools.SwitchOnTriggerMatchEmbedding.toolCode().

tuple trigTools.switchOnTriggerStandAlone = SwitchOnTriggerStandAlone()

Definition at line 284 of file trigTools.py.

Referenced by trigTools.SwitchOnTriggerMatchingStandAlone.toolCode().