From ab17494fd86e5e94167dd8ba1ca74f58cb8210a0 Mon Sep 17 00:00:00 2001 From: Emanuele Di Marco Date: Wed, 10 Jun 2015 11:37:44 +0200 Subject: [PATCH] * added the possibility to run on the pi0 stream * make the saving of the event plots automatic if running on splashes * added min number of entries in the calib maps --- .../test/ecalTime_fromAlcaStream_cfg.py | 26 +++++++++++++++---- 1 file changed, 21 insertions(+), 5 deletions(-) diff --git a/EcalTiming/test/ecalTime_fromAlcaStream_cfg.py b/EcalTiming/test/ecalTime_fromAlcaStream_cfg.py index 6c9917b..cda4b9d 100644 --- a/EcalTiming/test/ecalTime_fromAlcaStream_cfg.py +++ b/EcalTiming/test/ecalTime_fromAlcaStream_cfg.py @@ -23,9 +23,14 @@ "0=false, 1=true" ) ### setup any defaults you want +streamName = "AlCaPhiSym" options.output="ecalTiming.root" options.secondaryOutput="ntuple.root" -options.files= "/store/data/Commissioning2015/AlCaPhiSym/RAW/v1/000/244/768/00000/A8219906-44FD-E411-8DA9-02163E0121C5.root" +if(streamName=="AlCaP0"): options.files = "/store/data/Commissioning2015/AlCaP0/RAW/v1/000/246/342/00000/048ECF48-F906-E511-95AC-02163E011909.root" +elif(streamName=="AlCaPhiSym"): options.files = "/store/data/Commissioning2015/AlCaPhiSym/RAW/v1/000/244/768/00000/A8219906-44FD-E411-8DA9-02163E0121C5.root" +else: + print "stream ",streamName," not foreseen" + exit options.maxEvents = -1 # -1 means all events ### get and parse the command line arguments options.parseArguments() @@ -43,6 +48,7 @@ process.load('Configuration.StandardSequences.GeometryRecoDB_cff') process.load('Configuration.StandardSequences.MagneticField_38T_cff') + if(options.isSplash==1): ## Get Cosmic Reconstruction process.load('Configuration/StandardSequences/ReconstructionCosmics_cff') @@ -63,6 +69,14 @@ process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_condDBv2_cff') process.load('EcalTiming.EcalTiming.ecalLocalRecoSequenceAlCaStream_cff') +if(streamName=="AlCaP0"): + process.ecalMultiFitUncalibRecHit.EBdigiCollection = cms.InputTag("hltAlCaPi0EBRechitsToDigis","pi0EBDigis") + process.ecalMultiFitUncalibRecHit.EEdigiCollection = cms.InputTag("hltAlCaPi0EERechitsToDigis","pi0EEDigis") +else: + process.ecalMultiFitUncalibRecHit.EBdigiCollection = cms.InputTag("HLTEcalPhiSymFilter","phiSymEcalDigisEB") + process.ecalMultiFitUncalibRecHit.EEdigiCollection = cms.InputTag("HLTEcalPhiSymFilter","phiSymEcalDigisEE") + + ## Raw to Digi process.load('Configuration/StandardSequences/RawToDigi_Data_cff') @@ -187,16 +201,18 @@ ### Schedule ### process.schedule = cms.Schedule(process.p) # , process.endp) +evtPlots = True if options.isSplash else False process.looper = cms.Looper("EcalTimingCalibProducer", maxLoop = cms.uint32(2), isSplash = cms.bool(True if options.isSplash == 1 else False), - makeEventPlots = cms.bool(True), + makeEventPlots = cms.bool(evtPlots), recHitEBCollection = cms.InputTag("ecalRecHit","EcalRecHitsEB"), recHitEECollection = cms.InputTag("ecalRecHit","EcalRecHitsEE"), recHitFlags = cms.vint32([0]), # only recHits with these flags are accepted for calibration - recHitMinimumN = cms.uint32(10), - #recHitMinimumN = cms.uint32(2), - minRecHitEnergy = cms.double(0), + #recHitMinimumN = cms.uint32(10), + recHitMinimumN = cms.uint32(2), + minRecHitEnergy = cms.double(1), + minEntries = cms.uint32(1), globalOffset = cms.double(options.offset), produceNewCalib = cms.bool(True), outputDumpFile = process.TFileService.fileName,