Inherits FWCore::GuiBrowsers::ConfigToolBase::ConfigToolBase.
Public Member Functions | |
def | __call__ |
def | __init__ |
def | getDefaultParameters |
def | toolCode |
Private Attributes | |
_comment | |
_parameters | |
Static Private Attributes | |
tuple | _defaultParameters = dicttypes.SortedKeysDict() |
string | _label = 'makeTrackCandidates' |
Create selected tracks and a candidate hypothesis on AOD:
Definition at line 237 of file trackTools.py.
def trackTools::MakeTrackCandidates::__init__ | ( | self | ) |
Definition at line 243 of file trackTools.py.
00244 : 00245 ConfigToolBase.__init__(self) 00246 self.addParameter(self._defaultParameters,'label','TrackCands', "output collection will be <'patAOD'+label>") 00247 self.addParameter(self._defaultParameters,'tracks',cms.InputTag('generalTracks'), 'input tracks') 00248 self.addParameter(self._defaultParameters,'particleType','pi+', 'particle type (for mass)') 00249 self.addParameter(self._defaultParameters,'preselection','pt > 10', 'preselection cut on the AOD candidates') 00250 self.addParameter(self._defaultParameters,'selection','pt > 10', 'selection cut on the PAT candidates (for the selectedLayer1Candidate collection)') 00251 self.addParameter(self._defaultParameters,'isolation',{'tracker':0.3, 'ecalTowers':0.3, 'hcalTowers':0.3}, "isolation to use (as 'source': value of dR)\ntracker : as muon iso from tracks\necalTowers : as muon iso from calo tower\nhcalTowers : as muon iso from calo towers",allowedValues=['tracker','ecalTowers','hcalTowers']) 00252 self.addParameter(self._defaultParameters,'isoDeposits',['tracker','ecalTowers','hcalTowers'], 'iso deposits') 00253 self.addParameter(self._defaultParameters,'mcAs',None, "eplicate mc match as the one used by PAT on this AOD collection (None=no mc match); choose 'photon', 'electron', 'muon', 'tau','jet', 'met' as input string",Type=str,allowedValues=['photon', 'electron', 'muon', 'tau','jet', 'met', None], acceptNoneValue = True) 00254 00255 self._parameters=copy.deepcopy(self._defaultParameters) 00256 self._comment = ""
def trackTools::MakeTrackCandidates::__call__ | ( | self, | |
process, | |||
label = None , |
|||
tracks = None , |
|||
particleType = None , |
|||
preselection = None , |
|||
selection = None , |
|||
isolation = None , |
|||
isoDeposits = None , |
|||
mcAs = None |
|||
) |
Definition at line 260 of file trackTools.py.
00269 : 00270 if label is None: 00271 label=self._defaultParameters['label'].value 00272 if tracks is None: 00273 tracks=self._defaultParameters['tracks'].value 00274 if particleType is None: 00275 particleType=self._defaultParameters['particleType'].value 00276 if preselection is None: 00277 preselection=self._defaultParameters['preselection'].value 00278 if selection is None: 00279 selection=self._defaultParameters['selection'].value 00280 if isolation is None: 00281 isolation=self._defaultParameters['isolation'].value 00282 if isoDeposits is None: 00283 isoDeposits=self._defaultParameters['isoDeposits'].value 00284 if mcAs is None: 00285 mcAs=self._defaultParameters['mcAs'].value 00286 self.setParameter('label',label) 00287 self.setParameter('tracks',tracks) 00288 self.setParameter('particleType',particleType) 00289 self.setParameter('preselection',preselection) 00290 self.setParameter('selection',selection) 00291 self.setParameter('isolation',isolation) 00292 self.setParameter('isoDeposits',isoDeposits) 00293 self.setParameter('mcAs',mcAs,True) 00294 self.apply(process)
def trackTools::MakeTrackCandidates::getDefaultParameters | ( | self | ) |
Definition at line 257 of file trackTools.py.
def trackTools::MakeTrackCandidates::toolCode | ( | self, | |
process | |||
) |
Definition at line 295 of file trackTools.py.
00295 : 00296 label=self._parameters['label'].value 00297 tracks=self._parameters['tracks'].value 00298 particleType=self._parameters['particleType'].value 00299 preselection=self._parameters['preselection'].value 00300 selection=self._parameters['selection'].value 00301 isolation=self._parameters['isolation'].value 00302 isoDeposits=self._parameters['isoDeposits'].value 00303 mcAs=self._parameters['mcAs'].value 00304 00305 makeAODTrackCandidates(process, 00306 tracks = tracks, 00307 particleType = particleType, 00308 candSelection = preselection, 00309 label = label 00310 ) 00311 makePATTrackCandidates(process, 00312 label = label, 00313 input = cms.InputTag('patAOD' + label), 00314 isolation = isolation, 00315 isoDeposits = isoDeposits, 00316 mcAs = mcAs, 00317 selection = selection 00318 ) 00319 00320 makeTrackCandidates=MakeTrackCandidates() 00321
Definition at line 243 of file trackTools.py.
tuple trackTools::MakeTrackCandidates::_defaultParameters = dicttypes.SortedKeysDict() [static, private] |
Definition at line 241 of file trackTools.py.
string trackTools::MakeTrackCandidates::_label = 'makeTrackCandidates' [static, private] |
Definition at line 240 of file trackTools.py.
Definition at line 243 of file trackTools.py.