Created
August 11, 2022 11:07
-
-
Save mmusich/80fa5cb6e192c9f424f715b598b22604 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import FWCore.ParameterSet.Config as cms | |
process = cms.Process("ONLYHISTOS") | |
#process.load("Alignment.OfflineValidation.Dataset_Validation_DoubleMuon_Run2022C_cff") | |
readFiles = cms.untracked.vstring() | |
process.source = cms.Source("PoolSource", | |
fileNames = readFiles) | |
readFiles.extend([ | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/368/00000/38b7a3a2-ab33-46ba-8ab3-7c341f20d344.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/369/00000/30b032da-aa0d-438e-9a37-fc7695ba6b2e.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/374/00000/f73c9563-c359-481a-a7ef-433303244440.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/375/00000/a1818280-7532-44d4-a45b-347f43d0b507.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/376/00000/51c77bed-d916-4a5f-9685-a2119df4cb79.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/379/00000/d70f91e0-5701-4ce5-b831-c377565cb466.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/380/00000/e35cbdf3-57aa-45d0-854c-d91c9f361a07.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/381/00000/80a33624-04d7-483b-8dd4-59b0fa0ac84f.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/382/00000/c0f8b32e-c4f9-4b4a-9908-83bdef5c353e.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/383/00000/962260e0-7cbc-4f5f-9520-95e9a7d8c70c.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/400/00000/9283d615-15fb-4332-8015-092deec53699.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/404/00000/f03bd96f-ed3a-44c2-9ef2-6e1dd5dba1c3.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/405/00000/8784ad87-5731-4426-aa3b-d06daaf3535e.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/406/00000/054240f4-7a57-4cec-9688-cb5aa7a55fc1.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/407/00000/fb9c7f49-7f05-4cc0-9738-56f7e8f295e9.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/411/00000/3ac4c128-b841-4760-b017-1d9a23bd88cf.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/414/00000/e0453995-0ecf-4841-83f0-eb24feca7a01.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/415/00000/d775fbb2-9c9f-498f-b83c-cf94bb9ce016.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/417/00000/89573cd1-a95d-4cdf-90e8-fdf5bffbd709.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/418/00000/e343abb9-216d-4ddd-b639-13b56f14d6ef.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/419/00000/ad4b8d39-292c-4fc7-bc41-dddd3e6e250a.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/429/00000/f30423ee-0407-4565-a0b4-8b442728b7c6.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/435/00000/6d0b27aa-8dc5-4e6e-b187-d4d9961b042c.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/437/00000/86cffa23-e76c-4881-adf3-fb04f01774ee.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/438/00000/9efb60dc-d8f2-45d6-8671-f7268858d35b.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/439/00000/afaf0ec1-a916-43f2-8985-b0afe9242175.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/441/00000/f6cb177b-2b5a-4669-b87b-020ba9c0fe07.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/442/00000/79d5ad07-3894-4808-a51f-40c7a4593f8a.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/443/00000/f17f4254-f335-4d82-9d08-a6737ff9e8ba.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/444/00000/0102c721-b0dc-40e1-91c8-72cfebf26bcb.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/445/00000/454641f9-7e2f-4718-9757-80ca1f2b31f7.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/453/00000/94c07250-b184-41b5-844b-f48403667d7c.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/454/00000/6bd698b5-0960-4ab5-b023-71f82dfa1c2b.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/455/00000/dcc35a10-4bfb-4c0b-a7fe-09229074dd30.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/456/00000/bd1c585b-343e-4769-83f5-728485f0d73d.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/457/00000/6a6901d9-3dfe-4e10-8d57-56aa4f9aad22.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/463/00000/70e087b3-931c-4ed1-9c83-68983110f590.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/552/00000/2a86a9f2-0981-42dd-b046-ed68b3ced756.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/558/00000/633d3307-47a8-4dd3-8432-304ed534b6a3.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/559/00000/9e5a570c-fefd-4985-ac98-c7ac433e2264.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/627/00000/098e74fb-2829-4d87-9a3a-5a9d3b3031f5.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/628/00000/3ac7c5c7-e070-4d7f-a2b7-9a5909295d4f.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/629/00000/ce9b92ba-5615-4842-8cc2-fc5141ed8bb6.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/630/00000/96d6a706-a250-4792-ad03-d292b88ae8cc.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/631/00000/895dd9a0-36e6-4ac3-8446-7b3bc336194c.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/671/00000/8b1655f8-0d63-4d4e-a0f8-525e86a6ee62.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/678/00000/bbd8e6b0-dcb1-41df-ae62-171e4869c347.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/679/00000/2b54fe70-e2e2-48eb-b1ef-ab03c1ef82cb.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/680/00000/b059179f-ee76-4db4-af84-32089d3dffad.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/765/00000/49281eb3-27ee-4b7f-b3f1-ee84e594bc3b.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/768/00000/095ee734-1ee9-448e-8366-d7adfc853bc1.root", | |
"/store/data/Run2022B/DoubleMuon/ALCARECO/TkAlZMuMu-PromptReco-v1/000/355/769/00000/cfba9a0c-71b2-409d-b20e-725798ea2542.root", | |
]) | |
process.maxEvents = cms.untracked.PSet( | |
input = cms.untracked.int32(int(-1 / 1)) | |
) | |
process.source.skipEvents=cms.untracked.uint32(int(0*-1/1)) | |
process.options = cms.untracked.PSet( | |
wantSummary = cms.untracked.bool(False), | |
Rethrow = cms.untracked.vstring("ProductNotFound"), # make this exception fatal | |
fileMode = cms.untracked.string('NOMERGE') # no ordering needed, but calls endRun/beginRun etc. at file boundaries | |
) | |
process.load("FWCore.MessageLogger.MessageLogger_cfi") | |
process.MessageLogger.cerr.FwkReport.reportEvery = 1000 | |
process.MessageLogger.cout.enableStatistics = cms.untracked.bool(True) | |
process.load("RecoVertex.BeamSpotProducer.BeamSpot_cff") | |
process.load("Configuration.Geometry.GeometryDB_cff") | |
process.load('Configuration.StandardSequences.Services_cff') | |
process.load("Configuration.StandardSequences.MagneticField_cff") | |
process.load("RecoMuon.DetLayers.muonDetLayerGeometry_cfi") | |
process.load("Geometry.MuonNumbering.muonNumberingInitialization_cfi") | |
process.load("RecoMuon.TrackingTools.MuonServiceProxy_cff") | |
process.load("Configuration.StandardSequences.Reconstruction_cff") | |
process.load("RecoTracker.TrackProducer.TrackRefitters_cff") | |
process.TrackRefitter.src = "ALCARECOTkAlZMuMu" | |
process.TrackRefitter.TTRHBuilder = "WithAngleAndTemplate" | |
process.TrackRefitter.NavigationSchool = "" | |
#Global tag | |
process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff") | |
from Configuration.AlCa.GlobalTag import GlobalTag | |
process.GlobalTag = GlobalTag(process.GlobalTag,"124X_dataRun3_Express_v4") | |
import CalibTracker.Configuration.Common.PoolDBESSource_cfi | |
process.conditionsInTrackerAlignmentRcd = CalibTracker.Configuration.Common.PoolDBESSource_cfi.poolDBESSource.clone( | |
connect = cms.string('frontier://FrontierProd/CMS_CONDITIONS'), | |
toGet = cms.VPSet(cms.PSet(record = cms.string('TrackerAlignmentRcd'), | |
tag = cms.string('TrackerAlignment_HGPCL_ForComparison2022_v1') | |
) | |
) | |
) | |
process.prefer_conditionsInTrackerAlignmentRcd = cms.ESPrefer("PoolDBESSource", "conditionsInTrackerAlignmentRcd") | |
compressionSettings = 207 | |
###### MuSclFit SETTINGS ############################################## | |
### MuScleFit specific configuration | |
process.looper = cms.Looper( | |
"MuScleFit", | |
# Only used when reading events from a root tree | |
MaxEventsFromRootTree = cms.int32(-1), | |
# Specify a file if you want to read events from a root tree in a local file. | |
# In this case the input source should be an empty source with 0 events. | |
InputRootTreeFileName = cms.string(""), | |
# Specify the file name where you want to save a root tree with the muon pairs. | |
# Leave empty if no file should be written. | |
OutputRootTreeFileName = cms.string(""), | |
# Choose the kind of muons you want to run on | |
# ------------------------------------------- | |
MuonLabel = cms.InputTag("TrackRefitter"), | |
#MuonType = cms.int32(11), | |
MuonType = cms.int32(5), | |
# This line allows to switch to PAT muons. Default is false. | |
# Note that the onia selection works only with onia patTuples. | |
PATmuons = cms.untracked.bool(False), | |
# ---------------- # | |
# Select resonance # | |
# ---------------- # | |
# The resonances are to be specified in this order: | |
# Z0, Y(3S), Y(2S), Y(1S), Psi(2S), J/Psi | |
# ------------------------------------------------- | |
resfind = cms.vint32( | |
int("Z" == "Z"), | |
int("Z" == "Y3S"), | |
int("Z" == "Y2S"), | |
int("Z" == "Y1S"), | |
int("Z" == "Psi2S"), | |
int("Z" == "JPsi") | |
), | |
# Likelihood settings | |
# ------------------- | |
maxLoopNumber = cms.untracked.int32(1), | |
# Select which fits to do in which loop (0 = do not, 1 = do) | |
doResolFit = cms.vint32(0), | |
doScaleFit = cms.vint32(0), | |
doBackgroundFit = cms.vint32(0), | |
doCrossSectionFit = cms.vint32(0), | |
# Use the probability file or not. If not it will perform a simpler selection taking the muon pair with | |
# invariant mass closer to the pdf value and will crash if some fit is attempted. | |
UseProbsFile = cms.untracked.bool(False), | |
# False = use also MC information | |
speedup = cms.bool(True), | |
# Set this to false if you do not want to use simTracks. | |
# (Note that this is skipped anyway if speedup == True). | |
compareToSimTracks = cms.bool(False), | |
# Output settings | |
# --------------- | |
# Use compressions settings of TFile | |
# see https://root.cern.ch/root/html534/TFile.html#TFile:SetCompressionSettings | |
# settings = 100 * algorithm + level | |
# level is from 1 (small) to 9 (large compression) | |
# algo: 1 (ZLIB), 2 (LMZA) | |
# see more about compression & performance: https://root.cern.ch/root/html534/guides/users-guide/InputOutput.html#compression-and-performance | |
OutputFileName = cms.untracked.string("zmumuHisto.root"), | |
compressionSettings = cms.untracked.int32(compressionSettings), | |
# BiasType=0 means no bias to muon momenta | |
# ---------------------------------------- | |
BiasType = cms.int32(0), | |
parBias = cms.vdouble(), | |
# SmearType=0 means no smearing applied to muon momenta | |
# ----------------------------------------------------- | |
SmearType = cms.int32(0), | |
parSmear = cms.vdouble(), | |
### taken from J/Psi ######################### | |
# ResolFitType = cms.int32(14), | |
# parResol = cms.vdouble(0.007,0.015, -0.00077, 0.0063, 0.0018, 0.0164), | |
# parResolFix = cms.vint32(0, 0, 0,0, 0,0), | |
# parResolOrder = cms.vint32(0, 0, 0, 0, 0, 0), | |
ResolFitType = cms.int32(0), | |
parResol = cms.vdouble(0), | |
parResolFix = cms.vint32(0), | |
parResolOrder = cms.vint32(0), | |
# -------------------- # | |
# Scale fit parameters # | |
# -------------------- # | |
# ----------------------------------------------------------------------------------- | |
# ScaleFitType = cms.int32(18), | |
# parScaleOrder = cms.vint32(0, 0, 0, 0), | |
# parScaleFix = cms.vint32(0, 0, 0, 0), | |
# parScale = cms.vdouble(1, 1, 1, 1), | |
ScaleFitType = cms.int32(0), | |
parScaleOrder = cms.vint32(0), | |
parScaleFix = cms.vint32(0), | |
parScale = cms.vdouble(0), | |
# ---------------------------- # | |
# Cross section fit parameters # | |
# ---------------------------- # | |
# Note that the cross section fit works differently than the others, it | |
# fits ratios of parameters. Fix and Order should not be used as is, they | |
# are there mainly for compatibility. | |
parCrossSectionOrder = cms.vint32(0, 0, 0, 0, 0, 0), | |
parCrossSectionFix = cms.vint32(0, 0, 0, 0, 0, 0), | |
parCrossSection = cms.vdouble(1.233, 2.07, 6.33, 13.9, 2.169, 127.2), | |
# ------------------------- # | |
# Background fit parameters # | |
# ------------------------- # | |
# Window factors for: Z, Upsilons and (J/Psi,Psi2S) regions | |
LeftWindowBorder = cms.vdouble(70., 8., 1.391495), | |
RightWindowBorder = cms.vdouble(110., 12., 5.391495), | |
# The two parameters of BgrFitType=2 are respectively: | |
# bgr fraction, (negative of) bgr exp. slope, bgr constant | |
# -------------------------------------------------------- | |
# The function types for resonances in a region must be the same | |
BgrFitType = cms.vint32(2, 2, 2), # regions | |
# These empty parameters should be used when there is no background | |
parBgr = cms.vdouble(0., 0., 0., 0., 0., 0., | |
0., 0., 0., 0., 0., 0., 0.,0., 0.,0., 0.,0.), | |
parBgrFix = cms.vint32(0, 0, 0, 0, 0, 0, | |
# The rest of the parameters is used for the resonance regions. They are automatically fixed in the code | |
# because they are never used to fit the background, but only after the rescaling. | |
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1), | |
parBgrOrder = cms.vint32(0, 0, 0, 0, 0, 0, | |
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), | |
# ----------------------- # | |
# Set Minuit fit strategy | |
FitStrategy = cms.int32(1), | |
# Fit accuracy and debug parameters | |
StartWithSimplex = cms.bool(True), | |
ComputeMinosErrors = cms.bool(False), | |
MinimumShapePlots = cms.bool(True), | |
########## TO BE ENABLED ################################ | |
# Set the cuts on muons to be used in the fit | |
MinMuonPt = cms.untracked.double(0.), | |
MaxMuonPt = cms.untracked.double(1000.), | |
MinMuonEtaFirstRange = cms.untracked.double(-2.4), | |
MaxMuonEtaFirstRange = cms.untracked.double(2.4), | |
MinMuonEtaSecondRange = cms.untracked.double(-2.4), | |
MaxMuonEtaSecondRange = cms.untracked.double(2.4), | |
PileUpSummaryInfo = cms.untracked.InputTag("addPileupInfo"), | |
PrimaryVertexCollection = cms.untracked.InputTag("offlinePrimaryVertices"), | |
# The following parameters can be used to filter events | |
TriggerResultsLabel = cms.untracked.string("TriggerResults"), | |
TriggerResultsProcess = cms.untracked.string("HLT"), | |
TriggerPath = cms.untracked.vstring(""), | |
# Negate the result of the trigger | |
NegateTrigger = cms.untracked.bool(False), | |
debug = cms.untracked.int32(0), | |
) | |
process.p = cms.Path( | |
process.offlineBeamSpot*process.TrackRefitter | |
) | |
print("Done") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment