Skip to content
Snippets Groups Projects
Commit 67ff53ce authored by Scott Snyder's avatar Scott Snyder Committed by Walter Lampl
Browse files

JetTagTools: Fix clang warnings.

JetTagTools: Fix clang warnings.

Binding references to temporaries in range-for.
parent 523734ce
No related branches found
Tags nightly/main/2024-03-09T2001
No related merge requests found
......@@ -78,14 +78,14 @@ StatusCode CTTDecorCheckInTool::execute()
//save all TrackParticles in an std::vector (needed as input to the CTT tool)
std::vector<const xAOD::TrackParticle*> trkparticles(0);
for(const auto& trkPart : *trackTES){
for(const auto trkPart : *trackTES){
trkparticles.emplace_back(trkPart);
}
//first decorate all jets with the CTT method
m_classifiedTrackTagger->decorateJets(trkparticles, *primVertex, *jetTES);
for(const auto& curjet : *jetTES){
for(const auto curjet : *jetTES){
ATH_MSG_DEBUG( " Jet pt: " << curjet->pt()<<" eta: "<<curjet->eta()<<" phi: "<< curjet->phi() );
float CTTScore = m_classifiedTrackTagger->bJetWgts(trkparticles, *primVertex, curjet->p4());
ATH_MSG_DEBUG ("Retrieved CTT score from CTT tool: " << CTTScore);
......
......@@ -138,7 +138,7 @@ namespace Analysis {
void ClassifiedTrackTaggerTool::decorateJets(const std::vector<const xAOD::TrackParticle*> & InpTrk, const xAOD::Vertex & primVertex, const xAOD::JetContainer & jets) const
{
SG::WriteDecorHandle< xAOD::JetContainer, float > jetWriteDecorHandle (m_jetWriteDecorKey);
for(const auto& curjet : jets){
for(const auto curjet : jets){
ATH_MSG_DEBUG( " Jet pt: " << curjet->pt()<<" eta: "<<curjet->eta()<<" phi: "<< curjet->phi() );
float CTTScore = bJetWgts(InpTrk, primVertex, curjet->p4());
jetWriteDecorHandle(*curjet) = CTTScore;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment