Skip to content

Commit 93d17b3

Browse files
committed
Update KCaloJet
nConst is now nConstituents. Use floats as the reco data format also uses floats.
1 parent 395bd6a commit 93d17b3

File tree

3 files changed

+11
-9
lines changed

3 files changed

+11
-9
lines changed

DataFormats/interface/KJetMET.h

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,15 @@
1414

1515
struct KCaloJet : public KLV
1616
{
17-
double area;
18-
double fHPD, fRBX;
19-
double fEM, fHO;
20-
int nConst, n90Hits;
17+
float area; //< jet area
18+
19+
float fEM; //< energy fraction in the ECAL
20+
float fHO; //< energy fraction in HO
21+
float fHPD; //< energy fraction from dominant hybrid photo diode
22+
float fRBX; //< energy fraction from dominant readout box
23+
24+
short nConstituents; //< number of constituents (calo towers)
25+
short n90Hits; //< number of hits 90% of the jet energy
2126
};
2227
typedef std::vector<KCaloJet> KCaloJets;
2328

DataFormats/test/KDebug.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ std::ostream &operator<<(std::ostream &os, const KElectron &e)
5353
std::ostream &operator<<(std::ostream &os, const KCaloJet &jet)
5454
{
5555
os << static_cast<const KLV>(jet) << std::endl;
56-
os << "\t#Const=" << jet.nConst << " n90Hits=" << jet.n90Hits << std::endl;
56+
os << "\tnConstituents=" << jet.nConstituents << " n90Hits=" << jet.n90Hits << std::endl;
5757
os << "\tfHPD=" << jet.fHPD << " fRBX=" << jet.fRBX << std::endl;
5858
return os << "\tfEM=" << jet.fEM << " fHO=" << jet.fHO << " area=" << jet.area;
5959
}

Producers/interface/KCaloJetProducer.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ class KCaloJetProducer : public KBaseMultiLVProducer<reco::CaloJetCollection, KC
3636
copyP4(in, out.p4);
3737
out.area = in.jetArea();
3838
out.fEM = in.emEnergyFraction();
39-
out.nConst = in.getJetConstituents().size();
39+
out.nConstituents = in.getJetConstituents().size();
4040

4141
// Jet ID variables
4242
out.n90Hits = -2;
@@ -48,11 +48,8 @@ class KCaloJetProducer : public KBaseMultiLVProducer<reco::CaloJetCollection, KC
4848
edm::RefToBase<reco::Jet> jetRef(edm::Ref<reco::CaloJetCollection>(handle, this->nCursor));
4949
const reco::JetID &jetID = (*hJetID)[jetRef];
5050
out.n90Hits = (int)(jetID.n90Hits);
51-
// energy fraction from dominant hybrid photo diode
5251
out.fHPD = jetID.fHPD;
53-
// energy fraction from dominant readout box
5452
out.fRBX = jetID.fRBX;
55-
// energy fraction in HO
5653
out.fHO = jetID.fHO;
5754
}
5855
}

0 commit comments

Comments
 (0)