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

Splitting setNegativeFlags switch into two #17625

Merged
merged 1 commit into from Feb 26, 2017
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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 2 additions & 1 deletion HLTrigger/Configuration/python/customizeHLTforHCALPhaseI.py
Expand Up @@ -98,7 +98,8 @@ def customizeHLTforHEforPhaseI(process):
algoConfigClass = cms.string(""),

# Turn rechit status bit setters on/off
setNegativeFlags = cms.bool(False),
setNegativeFlagsQIE8 = cms.bool(False),
setNegativeFlagsQIE11 = cms.bool(False),
setNoiseFlagsQIE8 = cms.bool(True),
setNoiseFlagsQIE11 = cms.bool(False),
setPulseShapeFlagsQIE8 = cms.bool(True),
Expand Down
Expand Up @@ -68,7 +68,8 @@
algoConfigClass = cms.string(""),

# Turn rechit status bit setters on/off
setNegativeFlags = cms.bool(False),
setNegativeFlagsQIE8 = cms.bool(True),
setNegativeFlagsQIE11 = cms.bool(False),
setNoiseFlagsQIE8 = cms.bool(True),
setNoiseFlagsQIE11 = cms.bool(False),
setPulseShapeFlagsQIE8 = cms.bool(True),
Expand Down
23 changes: 15 additions & 8 deletions RecoLocalCalo/HcalRecProducers/src/HBHEPhase1Reconstructor.cc
Expand Up @@ -286,7 +286,8 @@ class HBHEPhase1Reconstructor : public edm::stream::EDProducer<>
bool recoParamsFromDB_;

// Parameters for turning status bit setters on/off
bool setNegativeFlags_;
bool setNegativeFlagsQIE8_;
bool setNegativeFlagsQIE11_;
bool setNoiseFlagsQIE8_;
bool setNoiseFlagsQIE11_;
bool setPulseShapeFlagsQIE8_;
Expand Down Expand Up @@ -344,7 +345,8 @@ HBHEPhase1Reconstructor::HBHEPhase1Reconstructor(const edm::ParameterSet& conf)
dropZSmarkedPassed_(conf.getParameter<bool>("dropZSmarkedPassed")),
tsFromDB_(conf.getParameter<bool>("tsFromDB")),
recoParamsFromDB_(conf.getParameter<bool>("recoParamsFromDB")),
setNegativeFlags_(conf.getParameter<bool>("setNegativeFlags")),
setNegativeFlagsQIE8_(conf.getParameter<bool>("setNegativeFlagsQIE8")),
setNegativeFlagsQIE11_(conf.getParameter<bool>("setNegativeFlagsQIE11")),
setNoiseFlagsQIE8_(conf.getParameter<bool>("setNoiseFlagsQIE8")),
setNoiseFlagsQIE11_(conf.getParameter<bool>("setNoiseFlagsQIE11")),
setPulseShapeFlagsQIE8_(conf.getParameter<bool>("setPulseShapeFlagsQIE8")),
Expand Down Expand Up @@ -518,11 +520,9 @@ void HBHEPhase1Reconstructor::processData(const Collection& coll,
}

void HBHEPhase1Reconstructor::setCommonStatusBits(
const HBHEChannelInfo& info, const HcalCalibrations& calib,
HBHERecHit* rh)
const HBHEChannelInfo& /* info */, const HcalCalibrations& /* calib */,
HBHERecHit* /* rh */)
{
if (setNegativeFlags_)
runHBHENegativeEFilter(info, rh);
}

void HBHEPhase1Reconstructor::setAsicSpecificBits(
Expand All @@ -535,6 +535,9 @@ void HBHEPhase1Reconstructor::setAsicSpecificBits(

if (setPulseShapeFlagsQIE8_)
hbhePulseShapeFlagSetterQIE8_->SetPulseShapeFlags(*rh, frame, coder, calib);

if (setNegativeFlagsQIE8_)
runHBHENegativeEFilter(info, rh);
}

void HBHEPhase1Reconstructor::setAsicSpecificBits(
Expand All @@ -547,6 +550,9 @@ void HBHEPhase1Reconstructor::setAsicSpecificBits(

if (setPulseShapeFlagsQIE11_)
hbhePulseShapeFlagSetterQIE11_->SetPulseShapeFlags(*rh, frame, coder, calib);

if (setNegativeFlagsQIE11_)
runHBHENegativeEFilter(info, rh);
}

void HBHEPhase1Reconstructor::runHBHENegativeEFilter(const HBHEChannelInfo& info,
Expand Down Expand Up @@ -584,7 +590,7 @@ HBHEPhase1Reconstructor::produce(edm::Event& e, const edm::EventSetup& eventSetu

// Configure the negative energy filter
ESHandle<HBHENegativeEFilter> negEHandle;
if (setNegativeFlags_)
if (setNegativeFlagsQIE8_ || setNegativeFlagsQIE11_)
{
eventSetup.get<HBHENegativeEFilterRcd>().get(negEHandle);
negEFilter_ = negEHandle.product();
Expand Down Expand Up @@ -722,7 +728,8 @@ HBHEPhase1Reconstructor::fillDescriptions(edm::ConfigurationDescriptions& descri
desc.add<bool>("dropZSmarkedPassed");
desc.add<bool>("tsFromDB");
desc.add<bool>("recoParamsFromDB");
desc.add<bool>("setNegativeFlags");
desc.add<bool>("setNegativeFlagsQIE8");
desc.add<bool>("setNegativeFlagsQIE11");
desc.add<bool>("setNoiseFlagsQIE8");
desc.add<bool>("setNoiseFlagsQIE11");
desc.add<bool>("setPulseShapeFlagsQIE8");
Expand Down