コード例 #1
0
ファイル: historyhelper.py プロジェクト: HEP-FCC/heppy
 def filter_ids(self, ids, type_and_subtype):
     ''' returns a filtered subset of ids which have a type_and_subtype that matchs the type_and_subtype argument
         eg merged_ecal_ids = filter_ids(ids, 'em')
         @param ids: a list of ids
         @param type_and_subtype: a two letter type and subtype eg 'es' for smeared ecal
     '''
     return [uid for uid in ids
             if IdCoder.type_and_subtype(uid) == type_and_subtype]
コード例 #2
0
 def filter_ids(self, ids, type_and_subtype):
     ''' returns a filtered subset of ids which have a type_and_subtype that matchs the type_and_subtype argument
         eg merged_ecal_ids = filter_ids(ids, 'em')
         @param ids: a list of ids
         @param type_and_subtype: a two letter type and subtype eg 'es' for smeared ecal
     '''
     return [
         uid for uid in ids
         if IdCoder.type_and_subtype(uid) == type_and_subtype
     ]
コード例 #3
0
 def type_and_subtype(self, node):
     ''' Return two letter type and subtype code for a node For example 'pg', 'ht' etc
     @param node: a node in the DAG history'''
     return IdCoder.type_and_subtype(node.get_value())
コード例 #4
0
ファイル: dagplotter.py プロジェクト: HEP-FCC/heppy
 def type_and_subtype(self, node):
     ''' Return two letter type and subtype code for a node For example 'pg', 'ht' etc
     @param node: a node in the DAG history'''
     return IdCoder.type_and_subtype(node.get_value())