Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes to accommodate Splash events in ECAL DQM [CMSSW_12_0_X] #35747

Merged
merged 1 commit into from
Oct 22, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions DQM/EcalMonitorTasks/interface/TimingTask.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ namespace ecaldqm {
float energyThresholdEEFwd_;
float timingVsBXThreshold_;
float timeErrorThreshold_;
bool splashSwitch_;

MESet* meTimeMapByLS;
};
Expand Down
3 changes: 2 additions & 1 deletion DQM/EcalMonitorTasks/python/TimingTask_cfi.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@
energyThresholdEEFwd = cms.untracked.double(energyThresholdEEFwd),
energyThresholdEB = cms.untracked.double(energyThresholdEB),
timingVsBXThreshold = cms.untracked.double(timingVsBXThreshold),
timeErrorThreshold = cms.untracked.double(timeErrorThreshold)
timeErrorThreshold = cms.untracked.double(timeErrorThreshold),
splashSwitch = cms.untracked.bool(False)
),
MEs = cms.untracked.PSet(
TimeMap = cms.untracked.PSet(
Expand Down
24 changes: 13 additions & 11 deletions DQM/EcalMonitorTasks/src/TimingTask.cc
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ namespace ecaldqm {
energyThresholdEEFwd_ = _params.getUntrackedParameter<double>("energyThresholdEEFwd");
timingVsBXThreshold_ = _params.getUntrackedParameter<double>("timingVsBXThreshold");
timeErrorThreshold_ = _params.getUntrackedParameter<double>("timeErrorThreshold");
splashSwitch_ = _params.getUntrackedParameter<bool>("splashSwitch");
}

bool TimingTask::filterRunType(short const* _runType) {
Expand Down Expand Up @@ -80,18 +81,12 @@ namespace ecaldqm {
float time(hit.time());
float energy(hit.energy());

float chi2Threshold, energyThreshold;
float energyThreshold;
if (id.subdetId() == EcalBarrel) {
chi2Threshold = chi2ThresholdEB_;
energyThreshold = energyThresholdEB_;
signedSubdet = EcalBarrel;
} else {
chi2Threshold = chi2ThresholdEE_;
energyThreshold = (isForward(id)) ? energyThresholdEEFwd_ : energyThresholdEE_;
}

if (id.subdetId() == EcalBarrel)
signedSubdet = EcalBarrel;
else {
EEDetId eeId(hit.id());
if (eeId.zside() < 0)
signedSubdet = -EcalEndcap;
Expand All @@ -102,10 +97,17 @@ namespace ecaldqm {
if (energy > energyThreshold)
meChi2.fill(getEcalDQMSetupObjects(), signedSubdet, hit.chi2());

// Apply cut on chi2 of pulse shape fit
if (hit.chi2() > chi2Threshold)
return;
if (!splashSwitch_) { //Not applied for splash events
float chi2Threshold;
if (id.subdetId() == EcalBarrel)
chi2Threshold = chi2ThresholdEB_;
else
chi2Threshold = chi2ThresholdEE_;

//Apply cut on chi2 of pulse shape fit
if (hit.chi2() > chi2Threshold)
return;
}
// Apply cut based on timing error of rechit
if (hit.timeError() > timeErrorThreshold_)
return;
Expand Down
30 changes: 29 additions & 1 deletion DQM/Integration/python/clients/ecal_dqm_sourceclient-live_cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
from DQM.Integration.config.unittestinputsource_cfi import options
else:
process.load("DQM.Integration.config.inputsource_cfi")
from DQM.Integration.config.inputsource_cfi import options
from DQM.Integration.config.inputsource_cfi import options, set_BeamSplashRun_settings

process.load("DQM.Integration.config.environment_cfi")
process.load("DQM.Integration.config.FrontierCondition_GT_cfi")
Expand Down Expand Up @@ -87,6 +87,34 @@
process.maxEvents = cms.untracked.PSet(
input = cms.untracked.int32(-1)
)
if not unitTest:
if options.BeamSplashRun:
set_BeamSplashRun_settings( process.source )
process.ecalMonitorTask.workerParameters.TimingTask.params.splashSwitch = True
process.ecalMonitorTask.workerParameters.TimingTask.MEs.TimeMap.zaxis.high = cms.untracked.double(30.)
process.ecalMonitorTask.workerParameters.TimingTask.MEs.TimeMap.zaxis.low = cms.untracked.double(-30.)
process.ecalMonitorTask.workerParameters.TimingTask.MEs.TimeMapByLS.zaxis.high = cms.untracked.double(30.)
process.ecalMonitorTask.workerParameters.TimingTask.MEs.TimeMapByLS.zaxis.low = cms.untracked.double(-30.)
process.ecalMonitorTask.workerParameters.TimingTask.MEs.TimeAll.xaxis.high = cms.untracked.double(30.)
process.ecalMonitorTask.workerParameters.TimingTask.MEs.TimeAll.xaxis.low = cms.untracked.double(-30.)
process.ecalMonitorTask.workerParameters.TimingTask.MEs.Time1D.xaxis.high = cms.untracked.double(30.)
process.ecalMonitorTask.workerParameters.TimingTask.MEs.Time1D.xaxis.low = cms.untracked.double(-30.)
process.ecalMonitorTask.workerParameters.TimingTask.MEs.TimeAllMap.zaxis.high = cms.untracked.double(25.)
process.ecalMonitorTask.workerParameters.TimingTask.MEs.TimeAllMap.zaxis.low = cms.untracked.double(-25.)
process.ecalMonitorTask.workerParameters.TimingTask.params.chi2ThresholdEE = cms.untracked.double(1000.)
process.ecalMonitorTask.workerParameters.TimingTask.params.chi2ThresholdEB = cms.untracked.double(1000.)

process.ecalMonitorClient.workerParameters.TimingClient.MEs.FwdvBkwd.yaxis.high = cms.untracked.double(30.)
process.ecalMonitorClient.workerParameters.TimingClient.MEs.FwdvBkwd.yaxis.low = cms.untracked.double(-30.)
process.ecalMonitorClient.workerParameters.TimingClient.MEs.FwdvBkwd.xaxis.high = cms.untracked.double(30.)
process.ecalMonitorClient.workerParameters.TimingClient.MEs.FwdvBkwd.xaxis.low = cms.untracked.double(-30.)
process.ecalMonitorClient.workerParameters.TimingClient.MEs.FwdBkwdDiff.xaxis.high = cms.untracked.double(25.)
process.ecalMonitorClient.workerParameters.TimingClient.MEs.FwdBkwdDiff.xaxis.low = cms.untracked.double(-25.)
process.ecalMonitorClient.workerParameters.TimingClient.MEs.MeanSM.xaxis.high = cms.untracked.double(30.)
process.ecalMonitorClient.workerParameters.TimingClient.MEs.MeanSM.xaxis.low = cms.untracked.double(-30.)
process.ecalMonitorClient.workerParameters.TimingClient.MEs.MeanAll.xaxis.high = cms.untracked.double(30.)
process.ecalMonitorClient.workerParameters.TimingClient.MEs.MeanAll.xaxis.low = cms.untracked.double(-30.)
process.ecalMonitorClient.workerParameters.TimingClient.params.minChannelEntries = cms.untracked.int32(0)

process.ecalMonitorClient.verbosity = 0
process.ecalMonitorClient.workers = ['IntegrityClient', 'OccupancyClient', 'PresampleClient', 'RawDataClient', 'TimingClient', 'SelectiveReadoutClient', 'TrigPrimClient', 'SummaryClient']
Expand Down