CMS 3D CMS Logo

ALCARECOSiStripCalCosmicsNano_cff.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 from Calibration.TkAlCaRecoProducers.ALCARECOSiStripCalCosmics_cff import ALCARECOSiStripCalCosmics
4 from CalibTracker.SiStripCommon.prescaleEvent_cfi import prescaleEvent
5 from HLTrigger.HLTfilters.triggerResultsFilter_cfi import triggerResultsFilter
6 
7 ALCARECOSiStripCalCosmicsNanoPrescale = prescaleEvent.clone(prescale=1)
8 
9 ALCARECOSiStripCalCosmicsNanoHLT = triggerResultsFilter.clone(
10  triggerConditions=cms.vstring("HLT_L1SingleMuCosmics_v*"),
11  hltResults=cms.InputTag("TriggerResults", "", "HLT"),
12  l1tResults=cms.InputTag(""),
13  throw=cms.bool(False)
14  )
15 
16 # Select only events where tracker had HV on (according to DCS bit information)
17 # AND respective partition is in the run (according to FED information)
18 import CalibTracker.SiStripCommon.SiStripDCSFilter_cfi
19 DCSStatusForSiStripCalCosmicsNano = CalibTracker.SiStripCommon.SiStripDCSFilter_cfi.siStripDCSFilter.clone(
20  DetectorType = cms.vstring('TIBTID','TOB','TECp','TECm'),
21  ApplyFilter = cms.bool(True),
22  AndOr = cms.bool(True),
23  DebugOn = cms.untracked.bool(False)
24  )
25 
26 from CalibTracker.Configuration.Filter_Refit_cff import CalibrationTracks, CalibrationTracksRefit, MeasurementTrackerEvent, offlineBeamSpot
27 
28 ALCARECOSiStripCalCosmicsNanoCalibTracks = CalibrationTracks.clone(src=cms.InputTag("ALCARECOSiStripCalCosmics"))
29 ALCARECOSiStripCalCosmicsNanoCalibTracksRefit = CalibrationTracksRefit.clone(
30  src=cms.InputTag("ALCARECOSiStripCalCosmicsNanoCalibTracks")
31  )
32 
33 ALCARECOSiStripCalCosmicsNanoTkCalSeq = cms.Sequence(
34  ALCARECOSiStripCalCosmicsNanoPrescale*
35  ALCARECOSiStripCalCosmicsNanoHLT*
36  DCSStatusForSiStripCalCosmicsNano*
37  ALCARECOSiStripCalCosmicsNanoCalibTracks,
38  cms.Task(MeasurementTrackerEvent),
39  cms.Task(offlineBeamSpot),
40  cms.Task(ALCARECOSiStripCalCosmicsNanoCalibTracksRefit)
41  )
42 
44 from PhysicsTools.NanoAOD.nano_cff import nanoMetadata
45 from CalibTracker.SiStripCommon.siStripPositionCorrectionsTable_cfi import siStripPositionCorrectionsTable
46 from CalibTracker.SiStripCommon.siStripLorentzAngleRunInfoTable_cfi import siStripLorentzAngleRunInfoTable
47 
48 ALCARECOSiStripCalCosmicsNanoTracksTable = cms.EDProducer("SimpleTrackFlatTableProducer",
49  src=cms.InputTag("ALCARECOSiStripCalCosmicsNanoCalibTracksRefit"),
50  cut=cms.string(""),
51  name=cms.string("track"),
52  doc=cms.string("SiStripCalCosmics ALCARECO tracks"),
53  singleton=cms.bool(False),
54  extension=cms.bool(False),
55  variables=cms.PSet(
56  chi2ndof=Var("chi2()/ndof", float),
57  pt=Var("pt()", float),
58  hitsvalid=Var("numberOfValidHits()", int),
59  phi=Var("phi()", float),
60  eta=Var("eta()", float),
61  )
62  )
63 
64 ALCARECOSiStripCalCosmicsNanoMeasTable = siStripPositionCorrectionsTable.clone(
65  Tracks=cms.InputTag("ALCARECOSiStripCalCosmicsNanoCalibTracksRefit"))
66 
67 ALCARECOSiStripCalCosmicsNanoTables = cms.Task(
68  nanoMetadata,
69  ALCARECOSiStripCalCosmicsNanoTracksTable,
70  ALCARECOSiStripCalCosmicsNanoMeasTable,
71  siStripLorentzAngleRunInfoTable
72  )
73 
74 seqALCARECOSiStripCalCosmicsNano = cms.Sequence(ALCARECOSiStripCalCosmicsNanoTkCalSeq, ALCARECOSiStripCalCosmicsNanoTables)
def Var(expr, valtype, compression=None, doc=None, mcOnly=False, precision=-1)
Definition: common_cff.py:20