13 const std::vector<l1t::Jet> *
input,
14 std::vector<l1t::Jet> *
output) {
15 for (std::vector<l1t::Jet>::const_iterator itJet =
input->begin(); itJet !=
input->end(); ++itJet) {
16 unsigned int pt = itJet->hwPt();
17 if (
pt > ((1 << 10) - 1))
19 unsigned int eta = itJet->hwEta();
24 unsigned int lutAddress = (
eta << 10) +
pt;
26 unsigned int rank =
params->jetCalibrationLUT()->data(lutAddress);
28 ROOT::Math::LorentzVector<ROOT::Math::PxPyPzE4D<double> > ldummy(0, 0, 0, 0);
29 l1t::Jet outJet(*&ldummy, rank, itJet->hwEta(), itJet->hwPhi(), itJet->hwQual());
35 const std::vector<l1t::Tau> *
input,
36 std::vector<l1t::Tau> *
output) {
37 for (std::vector<l1t::Tau>::const_iterator itTau =
input->begin(); itTau !=
input->end(); ++itTau) {
38 unsigned int pt = itTau->hwPt();
39 if (
pt > ((1 << 10) - 1))
41 unsigned int eta = itTau->hwEta();
42 unsigned int lutAddress = (
eta << 10) +
pt;
44 unsigned int rank =
params->tauCalibrationLUT()->data(lutAddress);
46 ROOT::Math::LorentzVector<ROOT::Math::PxPyPzE4D<double> > ldummy(0, 0, 0, 0);
47 l1t::Tau outTau(*&ldummy, rank, itTau->hwEta(), itTau->hwPhi(), itTau->hwQual());
53 const std::vector<l1t::Jet> *
input,
54 std::vector<l1t::Jet> *
output) {
55 for (std::vector<l1t::Jet>::const_iterator itJet =
input->begin(); itJet !=
input->end(); ++itJet) {
56 unsigned newPhi = itJet->hwPhi();
57 unsigned newEta =
gtEta(itJet->hwEta());
61 if ((itJet->hwQual() & 0x10) == 0x10) {
66 ROOT::Math::LorentzVector<ROOT::Math::PxPyPzE4D<double> > ldummy(0, 0, 0, 0);
68 l1t::Jet gtJet(*&ldummy, itJet->hwPt(), newEta, newPhi, itJet->hwQual());
74 const std::vector<l1t::Jet> *
input,
75 std::vector<l1t::Jet> *
output) {
76 for (std::vector<l1t::Jet>::const_iterator itJet =
input->begin(); itJet !=
input->end(); ++itJet) {
77 uint16_t linPt = (uint16_t)itJet->hwPt();
78 if (linPt >
params->jetScale().linScaleMax())
79 linPt =
params->jetScale().linScaleMax();
80 const uint16_t rankPt =
params->jetScale().rank(linPt);
82 ROOT::Math::LorentzVector<ROOT::Math::PxPyPzE4D<double> > ldummy(0, 0, 0, 0);
84 l1t::Jet gtJet(*&ldummy, rankPt, itJet->hwEta(), itJet->hwPhi(), itJet->hwQual());
90 const std::vector<l1t::EGamma> *
input,
91 std::vector<l1t::EGamma> *
output) {
92 for (std::vector<l1t::EGamma>::const_iterator itEGamma =
input->begin(); itEGamma !=
input->end(); ++itEGamma) {
93 unsigned newEta =
gtEta(itEGamma->hwEta());
94 unsigned newPhi = itEGamma->hwPhi();
95 const uint16_t rankPt = (uint16_t)itEGamma->hwPt();
98 if ((itEGamma->hwQual() & 0x10) == 0x10) {
103 ROOT::Math::LorentzVector<ROOT::Math::PxPyPzE4D<double> > ldummy(0, 0, 0, 0);
105 l1t::EGamma gtEGamma(*&ldummy, rankPt, newEta, newPhi, itEGamma->hwQual(), itEGamma->hwIso());
106 output->push_back(gtEGamma);
111 const std::vector<l1t::Tau> *
input,
112 std::vector<l1t::Tau> *
output) {
113 for (std::vector<l1t::Tau>::const_iterator itTau =
input->begin(); itTau !=
input->end(); ++itTau) {
114 unsigned newPhi = itTau->hwPhi();
115 unsigned newEta =
gtEta(itTau->hwEta());
119 if ((itTau->hwQual() & 0x10) == 0x10) {
124 ROOT::Math::LorentzVector<ROOT::Math::PxPyPzE4D<double> > ldummy(0, 0, 0, 0);
126 l1t::Tau gtTau(*&ldummy, itTau->hwPt(), newEta, newPhi, itTau->hwQual(), itTau->hwIso());
132 const std::vector<l1t::Tau> *
input,
133 std::vector<l1t::Tau> *
output) {
134 for (std::vector<l1t::Tau>::const_iterator itTau =
input->begin(); itTau !=
input->end(); ++itTau) {
135 uint16_t linPt = (uint16_t)itTau->hwPt();
136 if (linPt >
params->jetScale().linScaleMax())
137 linPt =
params->jetScale().linScaleMax();
138 const uint16_t rankPt =
params->jetScale().rank(linPt);
140 ROOT::Math::LorentzVector<ROOT::Math::PxPyPzE4D<double> > ldummy(0, 0, 0, 0);
142 l1t::Tau gtTau(*&ldummy, rankPt, itTau->hwEta(), itTau->hwPhi(), itTau->hwQual(), itTau->hwIso());
148 const std::vector<l1t::EtSum> *
input,
149 std::vector<l1t::EtSum> *
output) {
150 for (std::vector<l1t::EtSum>::const_iterator itEtSum =
input->begin(); itEtSum !=
input->end(); ++itEtSum) {
154 rankPt = (uint16_t)itEtSum->hwPt();
164 ROOT::Math::LorentzVector<ROOT::Math::PxPyPzE4D<double> > ldummy(0, 0, 0, 0);
166 l1t::EtSum gtEtSum(*&ldummy, itEtSum->getType(), rankPt, 0, itEtSum->hwPhi(), itEtSum->hwQual());
168 output->push_back(gtEtSum);
174 return (((rctEta % 7) & 0x7) | (
iEta < 11 ? 0x8 : 0));