CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
l1t::Stage1Layer2JetAlgorithmImpPP Class Reference

#include <Stage1Layer2JetAlgorithmImp.h>

Inheritance diagram for l1t::Stage1Layer2JetAlgorithmImpPP:
l1t::Stage1Layer2JetAlgorithm

Public Member Functions

void processEvent (const std::vector< l1t::CaloRegion > &regions, const std::vector< l1t::CaloEmCand > &EMCands, std::vector< l1t::Jet > *jets, std::vector< l1t::Jet > *preGtJets) override
 
 Stage1Layer2JetAlgorithmImpPP (CaloParamsHelper const *params)
 
 ~Stage1Layer2JetAlgorithmImpPP () override=default
 
- Public Member Functions inherited from l1t::Stage1Layer2JetAlgorithm
virtual ~Stage1Layer2JetAlgorithm ()
 

Private Attributes

CaloParamsHelper const *const params_
 

Detailed Description

Definition at line 40 of file Stage1Layer2JetAlgorithmImp.h.

Constructor & Destructor Documentation

Stage1Layer2JetAlgorithmImpPP::Stage1Layer2JetAlgorithmImpPP ( CaloParamsHelper const *  params)

Definition at line 20 of file Stage1Layer2JetAlgorithmImpPP.cc.

20 : params_(params) {};
l1t::Stage1Layer2JetAlgorithmImpPP::~Stage1Layer2JetAlgorithmImpPP ( )
overridedefault

Member Function Documentation

void Stage1Layer2JetAlgorithmImpPP::processEvent ( const std::vector< l1t::CaloRegion > &  regions,
const std::vector< l1t::CaloEmCand > &  EMCands,
std::vector< l1t::Jet > *  jets,
std::vector< l1t::Jet > *  preGtJets 
)
overridevirtual

Implements l1t::Stage1Layer2JetAlgorithm.

Definition at line 23 of file Stage1Layer2JetAlgorithmImpPP.cc.

References l1t::JetCalibration(), l1t::CaloParamsHelper::jetCalibrationParams(), l1t::CaloParamsHelper::jetCalibrationType(), l1t::CaloParamsHelper::jetSeedThreshold(), l1t::JetToGtEtaScales(), l1t::JetToGtPtScales(), params_, l1t::RegionCorrection(), l1t::slidingWindowJetFinder(), l1t::SortJets(), AlCaHLTBitMon_QueryRunRegistry::string, and l1t::CaloParamsHelper::towerLsbSum().

26  {
27 
28 
29  std::vector<l1t::CaloRegion> subRegions;
30  std::vector<l1t::Jet> uncalibjets;
31  std::vector<l1t::Jet> unSortedJets;
32  std::vector<l1t::Jet> preGtEtaJets;
33 
34  double towerLsb = params_->towerLsbSum();
35  int jetSeedThreshold = floor( params_->jetSeedThreshold()/towerLsb + 0.5);
36  std::string jetCalibrationType = params_->jetCalibrationType();
37  std::vector<double> jetCalibrationParams = params_->jetCalibrationParams();
38 
39  //Region Correction will return uncorrected subregions
40  //if regionPUSType is set to None in the config
41  RegionCorrection(regions, &subRegions, params_);
42 
43 
44  slidingWindowJetFinder(jetSeedThreshold, &subRegions, &uncalibjets);
45 
46  //will return jets with no response corrections
47  //if jetCalibrationType is set to None in the config
48  JetCalibration(&uncalibjets, jetCalibrationParams, &unSortedJets, jetCalibrationType, towerLsb);
49 
50  SortJets(&unSortedJets, &preGtEtaJets);
51 
52  // takes input jets (using region scales/eta) and outputs jets using Gt scales/eta
53  JetToGtEtaScales(params_, &preGtEtaJets, preGtJets);
54  JetToGtPtScales(params_, preGtJets, jets);
55 
56  //the jets should be sorted, highest pT first.
57  // do not truncate the tau list, GT converter handles that
58  // auto comp = [&](l1t::Jet i, l1t::Jet j)-> bool {
59  // return (i.hwPt() < j.hwPt() );
60  // };
61 
62  // std::sort(jets->begin(), jets->end(), comp);
63  // std::reverse(jets->begin(), jets->end());
64 }
void JetCalibration(std::vector< l1t::Jet > *uncalibjets, std::vector< double > jetCalibrationParams, std::vector< l1t::Jet > *jets, std::string jetCalibrationType, double jetLSB)
std::string const & jetCalibrationType() const
void SortJets(std::vector< l1t::Jet > *input, std::vector< l1t::Jet > *output)
void RegionCorrection(const std::vector< l1t::CaloRegion > &regions, std::vector< l1t::CaloRegion > *subRegions, CaloParamsHelper const *params)
------— New region correction (PUsub, no response correction at the moment) --------— ...
std::vector< double > const & jetCalibrationParams() const
void JetToGtEtaScales(CaloParamsHelper const *params, const std::vector< l1t::Jet > *input, std::vector< l1t::Jet > *output)
vector< PseudoJet > jets
void JetToGtPtScales(CaloParamsHelper const *params, const std::vector< l1t::Jet > *input, std::vector< l1t::Jet > *output)
void slidingWindowJetFinder(const int, const std::vector< l1t::CaloRegion > *regions, std::vector< l1t::Jet > *uncalibjets)
double towerLsbSum() const
double jetSeedThreshold() const

Member Data Documentation

CaloParamsHelper const* const l1t::Stage1Layer2JetAlgorithmImpPP::params_
private

Definition at line 49 of file Stage1Layer2JetAlgorithmImp.h.

Referenced by processEvent().