CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes | Static Private Attributes
trackTools.MakeTrackCandidates Class Reference
Inheritance diagram for trackTools.MakeTrackCandidates:

Public Member Functions

def __call__ (self, process, label=None, tracks=None, particleType=None, preselection=None, selection=None, isolation=None, isoDeposits=None, mcAs=None)
 
def __init__ (self)
 
def getDefaultParameters (self)
 
def toolCode (self, process)
 

Private Attributes

 _comment
 
 _parameters
 

Static Private Attributes

 _defaultParameters
 
 _label
 

Detailed Description

Create selected tracks and a candidate hypothesis on AOD:

Definition at line 233 of file trackTools.py.

Constructor & Destructor Documentation

◆ __init__()

def trackTools.MakeTrackCandidates.__init__ (   self)

Definition at line 239 of file trackTools.py.

239  def __init__(self):
240  ConfigToolBase.__init__(self)
241  self.addParameter(self._defaultParameters,'label','TrackCands', "output collection will be <'patAOD'+label>")
242  self.addParameter(self._defaultParameters,'tracks',cms.InputTag('generalTracks'), 'input tracks')
243  self.addParameter(self._defaultParameters,'particleType','pi+', 'particle type (for mass)')
244  self.addParameter(self._defaultParameters,'preselection','pt > 10', 'preselection cut on the AOD candidates')
245  self.addParameter(self._defaultParameters,'selection','pt > 10', 'selection cut on the PAT candidates (for the selectedLayer1Candidate collection)')
246  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'])
247  self.addParameter(self._defaultParameters,'isoDeposits',['tracker','ecalTowers','hcalTowers'], 'iso deposits')
248  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)
249 
250  self._parameters=copy.deepcopy(self._defaultParameters)
251  self._comment = ""
252 

References heavyIonTools.ConfigureHeavyIons._defaultParameters, metTools.AddMETCollection._defaultParameters, trackTools.MakeAODTrackCandidates._defaultParameters, coreTools.RunOnData._defaultParameters, heavyIonTools.ProductionDefaults._defaultParameters, cmsswVersionTools.PickRelValInputFiles._defaultParameters, coreTools.RemoveMCMatching._defaultParameters, trackTools.MakePATTrackCandidates._defaultParameters, heavyIonTools.SelectionDefaults._defaultParameters, heavyIonTools.DisbaleMonteCarloDeps._defaultParameters, tauTools.AddTauCollection._defaultParameters, trackTools.MakeTrackCandidates._defaultParameters, jetTools.AddJetCollection._defaultParameters, jetTools.SwitchJetCollection._defaultParameters, jetTools.UpdateJetCollection._defaultParameters, jetTools.AddJetID._defaultParameters, jetTools.SetTagInfos._defaultParameters, root::helper::RootFunctionAdapter< F, args >.addParameter(), root::helper::RootFunctionHelper< F, args, Tag >.addParameter(), ParameterMgr.addParameter(), fit::RootMinuit< Function >.addParameter(), DropBoxMetadata::Parameters.addParameter(), Python11ParameterSet.addParameter(), cmspython3::Python11ParameterSet.addParameter(), l1t::TriggerSystem.addParameter(), LutXml.addParameter(), ConfigToolBase.ConfigToolBase.addParameter(), and edm::ParameterSet.addParameter().

Member Function Documentation

◆ __call__()

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 256 of file trackTools.py.

256  def __call__(self,process,
257  label = None,
258  tracks = None,
259  particleType = None,
260  preselection = None,
261  selection = None,
262  isolation = None,
263  isoDeposits = None,
264  mcAs = None) :
265  if label is None:
266  label=self._defaultParameters['label'].value
267  if tracks is None:
268  tracks=self._defaultParameters['tracks'].value
269  if particleType is None:
270  particleType=self._defaultParameters['particleType'].value
271  if preselection is None:
272  preselection=self._defaultParameters['preselection'].value
273  if selection is None:
274  selection=self._defaultParameters['selection'].value
275  if isolation is None:
276  isolation=self._defaultParameters['isolation'].value
277  if isoDeposits is None:
278  isoDeposits=self._defaultParameters['isoDeposits'].value
279  if mcAs is None:
280  mcAs=self._defaultParameters['mcAs'].value
281  self.setParameter('label',label)
282  self.setParameter('tracks',tracks)
283  self.setParameter('particleType',particleType)
284  self.setParameter('preselection',preselection)
285  self.setParameter('selection',selection)
286  self.setParameter('isolation',isolation)
287  self.setParameter('isoDeposits',isoDeposits)
288  self.setParameter('mcAs',mcAs,True)
289  self.apply(process)
290 

References heavyIonTools.ConfigureHeavyIons._defaultParameters, metTools.AddMETCollection._defaultParameters, trackTools.MakeAODTrackCandidates._defaultParameters, coreTools.RunOnData._defaultParameters, heavyIonTools.ProductionDefaults._defaultParameters, cmsswVersionTools.PickRelValInputFiles._defaultParameters, coreTools.RemoveMCMatching._defaultParameters, trackTools.MakePATTrackCandidates._defaultParameters, heavyIonTools.SelectionDefaults._defaultParameters, heavyIonTools.DisbaleMonteCarloDeps._defaultParameters, tauTools.AddTauCollection._defaultParameters, trackTools.MakeTrackCandidates._defaultParameters, jetTools.AddJetCollection._defaultParameters, jetTools.SwitchJetCollection._defaultParameters, jetTools.UpdateJetCollection._defaultParameters, jetTools.AddJetID._defaultParameters, jetTools.SetTagInfos._defaultParameters, SignedImpactParameter3D.apply(), SignedDecayLength3D.apply(), SignedTransverseImpactParameter.apply(), gen::PhotosInterfaceBase.apply(), SurveyParameters.apply(), DummyOOTPileupCorrection.apply(), MatrixReader.MatrixReader.apply, gen::PhotosppInterface.apply(), gen::PhotosInterface.apply(), FWPSetCellEditor.apply(), RigidBodyAlignmentParameters.apply(), BeamSpotAlignmentParameters.apply(), FWGUIEventFilter.apply(), DeviationsFromFileSensor2D.apply(), AlignmentParameters.apply(), ConfigToolBase.ConfigToolBase.apply(), BowedSurfaceAlignmentParameters.apply(), OOTPileupCorrData.apply(), AbsOOTPileupCorrection.apply(), TwoBowedSurfacesAlignmentParameters.apply(), reco::modules::TrackerTrackHitFilter::Rule.apply(), cmsswVersionTools.PickRelValInputFiles.apply(), models.RegExp.apply(), ArrayND< Numeric, Len2, Dim2 >.apply(), npstat::ArrayND< Num1, Len1, Dim1 >.apply(), ArrayND< Accumulator >.apply(), ArrayND< Num2, Len2, Dim2 >.apply(), npstat::ArrayND< Numeric, StackLen, StackDim >.apply(), npstat::ArrayND< Numeric >.apply(), ArrayND< Numeric, Len, Dim >.apply(), Config.ProcessModifier.apply(), PedeReader.setParameter(), QIE8Simulator.setParameter(), AbsElectronicODERHS.setParameter(), SiStripLorentzAngleCalibration.setParameter(), IntegratedCalibrationBase.setParameter(), SiPixelLorentzAngleCalibration.setParameter(), SiStripBackplaneCalibration.setParameter(), fit::RootMinuit< Function >.setParameter(), and ConfigToolBase.ConfigToolBase.setParameter().

◆ getDefaultParameters()

def trackTools.MakeTrackCandidates.getDefaultParameters (   self)

◆ toolCode()

def trackTools.MakeTrackCandidates.toolCode (   self,
  process 
)

Definition at line 291 of file trackTools.py.

291  def toolCode(self, process):
292  label=self._parameters['label'].value
293  tracks=self._parameters['tracks'].value
294  particleType=self._parameters['particleType'].value
295  preselection=self._parameters['preselection'].value
296  selection=self._parameters['selection'].value
297  isolation=self._parameters['isolation'].value
298  isoDeposits=self._parameters['isoDeposits'].value
299  mcAs=self._parameters['mcAs'].value
300 
301  makeAODTrackCandidates(process,
302  tracks = tracks,
303  particleType = particleType,
304  candSelection = preselection,
305  label = label
306  )
307  makePATTrackCandidates(process,
308  label = label,
309  input = cms.InputTag('patAOD' + label),
310  isolation = isolation,
311  isoDeposits = isoDeposits,
312  mcAs = mcAs,
313  selection = selection
314  )
315 
316 makeTrackCandidates=MakeTrackCandidates()

References heavyIonTools.ConfigureHeavyIons._parameters, trackTools.MakeAODTrackCandidates._parameters, coreTools.RunOnData._parameters, metTools.AddMETCollection._parameters, heavyIonTools.ProductionDefaults._parameters, ConfigToolBase.ConfigToolBase._parameters, TAbsFitConstraint._parameters, TAbsFitParticle._parameters, cmsswVersionTools.PickRelValInputFiles._parameters, coreTools.RemoveMCMatching._parameters, trackTools.MakePATTrackCandidates._parameters, heavyIonTools.SelectionDefaults._parameters, heavyIonTools.DisbaleMonteCarloDeps._parameters, tauTools.AddTauCollection._parameters, trackTools.MakeTrackCandidates._parameters, jetTools.AddJetCollection._parameters, jetTools.SwitchJetCollection._parameters, jetTools.UpdateJetCollection._parameters, jetTools.AddJetID._parameters, and jetTools.SetTagInfos._parameters.

Member Data Documentation

◆ _comment

trackTools.MakeTrackCandidates._comment
private

Definition at line 251 of file trackTools.py.

◆ _defaultParameters

trackTools.MakeTrackCandidates._defaultParameters
staticprivate

Definition at line 237 of file trackTools.py.

Referenced by runJetUncertainties.RunJetUncertainties.__call__(), trigTools.SwitchOnTrigger.__call__(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.__call__(), trigTools.SwitchOnTriggerStandAlone.__call__(), trackTools.MakeTrackCandidates.__call__(), trigTools.SwitchOnTriggerMatching.__call__(), trigTools.SwitchOnTriggerMatchingStandAlone.__call__(), trigTools.SwitchOnTriggerMatchEmbedding.__call__(), runJetUncertainties.RunJetUncertainties.__init__(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.__init__(), trigTools.SwitchOnTrigger.__init__(), trigTools.SwitchOnTriggerStandAlone.__init__(), trackTools.MakeTrackCandidates.__init__(), trigTools.SwitchOnTriggerMatching.__init__(), trigTools.SwitchOnTriggerMatchingStandAlone.__init__(), trigTools.SwitchOnTriggerMatchEmbedding.__init__(), ConfigToolBase.ConfigToolBase.dumpPython(), ConfigToolBase.ConfigToolBase.getAllowedValues(), trigTools.SwitchOnTrigger.getDefaultParameters(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.getDefaultParameters(), trigTools.SwitchOnTriggerStandAlone.getDefaultParameters(), trackTools.MakeTrackCandidates.getDefaultParameters(), trigTools.SwitchOnTriggerMatching.getDefaultParameters(), trigTools.SwitchOnTriggerMatchingStandAlone.getDefaultParameters(), trigTools.SwitchOnTriggerMatchEmbedding.getDefaultParameters(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.initializeInputTag(), ConfigToolBase.ConfigToolBase.reset(), and ConfigToolBase.ConfigToolBase.setParameter().

◆ _label

trackTools.MakeTrackCandidates._label
staticprivate

◆ _parameters

trackTools.MakeTrackCandidates._parameters
private

Definition at line 250 of file trackTools.py.

Referenced by runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.ak4JetReclustering(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.createMVAMETModule(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.createSmearedJetModule(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.extractMET(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.getCorrectedMET(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.getMETUncertainties(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.getUnclusteredVariationsForMVAMET(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.getVariations(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.jetCleaning(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.jetConfiguration(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.miniAODConfiguration(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.miniAODConfigurationPost(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.recomputeRawMetFromPfcs(), runJetUncertainties.RunJetUncertainties.toolCode(), trigTools.SwitchOnTrigger.toolCode(), trigTools.SwitchOnTriggerStandAlone.toolCode(), runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.toolCode(), trackTools.MakeTrackCandidates.toolCode(), trigTools.SwitchOnTriggerMatching.toolCode(), trigTools.SwitchOnTriggerMatchingStandAlone.toolCode(), trigTools.SwitchOnTriggerMatchEmbedding.toolCode(), and runMETCorrectionsAndUncertainties.RunMETCorrectionsAndUncertainties.updateJECs().