From bb8f2a91675a67c56f1c9aea2563aab5b2451c3e Mon Sep 17 00:00:00 2001 From: jmcarcell Date: Tue, 6 Aug 2024 10:16:04 +0200 Subject: [PATCH] Move Associations to Links see https://github.com/key4hep/EDM4hep/pull/341 --- test/src/MCRecoLinkChecker.cc | 8 ++++---- test/src/MCRecoLinkChecker.h | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/test/src/MCRecoLinkChecker.cc b/test/src/MCRecoLinkChecker.cc index e4fc9924..ac8bb145 100644 --- a/test/src/MCRecoLinkChecker.cc +++ b/test/src/MCRecoLinkChecker.cc @@ -48,8 +48,8 @@ StatusCode MCRecoLinkChecker::execute(const EventContext&) const { return StatusCode::FAILURE; } - if (!(relation.getSim() == mc)) { - auto relMC = relation.getSim(); + if (!(relation.getTo() == mc)) { + auto relMC = relation.getTo(); error() << "Relation " << i << " does not point to the correct MCParticle (expected: " << mc.getObjectID().collectionID << "|" << mc.getObjectID().index << ", actual: " << relMC.getObjectID().collectionID << "|" @@ -57,8 +57,8 @@ StatusCode MCRecoLinkChecker::execute(const EventContext&) const { return StatusCode::FAILURE; } - if (!(relation.getRec() == reco)) { - auto relRec = relation.getRec(); + if (!(relation.getFrom() == reco)) { + auto relRec = relation.getFrom(); error() << "Relation " << i << " does not point to the correct RecoParticle (expected: " << reco.getObjectID().collectionID << "|" << reco.getObjectID().index << ", actual: " << relRec.getObjectID().collectionID << "|" diff --git a/test/src/MCRecoLinkChecker.h b/test/src/MCRecoLinkChecker.h index 61193925..f6e69181 100644 --- a/test/src/MCRecoLinkChecker.h +++ b/test/src/MCRecoLinkChecker.h @@ -20,7 +20,7 @@ #define K4MARLINWRAPPER_TEST_MCRECOLINKCHECKER_H #include "edm4hep/MCParticleCollection.h" -#include "edm4hep/MCRecoParticleAssociationCollection.h" +#include "edm4hep/RecoMCParticleLinkCollection.h" #include "edm4hep/ReconstructedParticleCollection.h" #include "k4FWCore/DataHandle.h" @@ -36,7 +36,7 @@ class MCRecoLinkChecker : public Gaudi::Algorithm { StatusCode execute(const EventContext&) const; private: - mutable DataHandle m_relationCollHandle{ + mutable DataHandle m_relationCollHandle{ "MCRecoTruthLinks", Gaudi::DataHandle::Reader, this}; mutable DataHandle m_mcCollHandle{"MCParticles", Gaudi::DataHandle::Reader, this}; mutable DataHandle m_recoCollHandle{"RecoParticles",