From dbddcf6a5fc2b236a649fe073c3b70249da5dddc Mon Sep 17 00:00:00 2001 From: Sebastien Wertz Date: Tue, 14 Feb 2017 17:30:56 +0100 Subject: [PATCH] Fix bending formula for retarded units --- plugins/Tools.cc | 10 ++++------ test/HHConfiguration.py | 8 ++++---- 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/plugins/Tools.cc b/plugins/Tools.cc index a914d65..2084fce 100644 --- a/plugins/Tools.cc +++ b/plugins/Tools.cc @@ -340,12 +340,10 @@ void HHAnalyzer::matchOfflineLepton(const HLTProducer& hlt, HH::Dilepton& dilept } float HHAnalyzer::getL1TPhi(int charge, const LorentzVector& p) { - /*float pt = p.Pt(); - float phi = p.Phi(); - float theta = p.Theta(); - return phi + charge * (1. / pt) * (10.48 - 5.1412 * theta + 0.02308 * theta * theta);*/ - // FIXME - return p.Phi(); + float pt = p.Pt(); + float theta = 180 / M_PI * p.Theta(); + theta = ( theta <= 90 ) ? theta : 180 - theta; + return p.Phi() + M_PI / 180 * charge * (1. / pt) * (10.48 - 5.1412 * theta + 0.02308 * theta * theta); } bool HHAnalyzer::sameEndCap(const LorentzVector& p1, const LorentzVector& p2) { diff --git a/test/HHConfiguration.py b/test/HHConfiguration.py index 37bc915..f4e5886 100644 --- a/test/HHConfiguration.py +++ b/test/HHConfiguration.py @@ -108,13 +108,13 @@ process = framework.create() -process.framework.treeFlushSize = cms.untracked.uint64(5 * 1024 * 1024) - -if runOnData : +if runOnData: process.source.fileNames = cms.untracked.vstring( '/store/data/Run2016F/DoubleMuon/MINIAOD/23Sep2016-v1/50000/040EDEBA-0490-E611-A424-008CFA110C68.root' ) -else : +else: + process.framework.treeFlushSize = cms.untracked.uint64(5 * 1024 * 1024) + process.source.fileNames = cms.untracked.vstring( # Signal '/store/mc/RunIISummer16MiniAODv2/GluGluToHHTo2B2VTo2L2Nu_node_SM_13TeV-madgraph-v2/MINIAODSIM/PUMoriond17_80X_mcRun2_asymptotic_2016_TrancheIV_v6-v1/60000/2E1015E2-71D9-E611-911E-02163E019E19.root'