|
ATLAS Offline Software
|
Go to the documentation of this file.
20 template <
class RefPartType,
class SearchPartType>
21 const SearchPartType* findClosestParticle(
const RefPartType*
reference,
23 const SearchPartType*
best{
nullptr};
24 for (
const SearchPartType* candidate : candidateContainer) {
36 MuonRecoChainTester::MuonRecoChainTester(
const std::string&
name, ISvcLocator* pSvcLocator):
77 return StatusCode::SUCCESS;
85 const EventContext& ctx{Gaudi::Hive::currentContext()};
108 if (!truth->isMuon())
continue;
109 if (truth->status() != 1)
continue;
110 truthParts.push_back(truth);
113 constexpr
double matchDR = 0.05;
129 return StatusCode::FAILURE;
131 return StatusCode::SUCCESS;
135 return StatusCode::SUCCESS;
std::shared_ptr< MuonVal::IParticleFourMomBranch > m_TrksSegmentR4
StatusCode init(OWNER *instance)
Initialize method.
@ VIEW_ELEMENTS
this data object is a view, it does not own its elmts
DataVector adapter that acts like it holds const pointers.
@ isMC
Flag determining whether the branch is simulation.
SG::ReadHandleKey< xAOD::TrackParticleContainer > m_TrackKeyR4
Gaudi::Property< std::string > m_legacySegmentKey
Keys to the segment collections.
double deltaR2(double rapidity1, double phi1, double rapidity2, double phi2)
from bare rapidity,phi
bool empty() const
Test if the key is blank.
SG::ReadHandleKey< xAOD::TruthParticleContainer > m_truthKey
Key to the truth particle collection.
virtual StatusCode finalize() override
double deltaR(double rapidity1, double phi1, double rapidity2, double phi2)
from bare bare rapidity,phi
::StatusCode StatusCode
StatusCode definition for legacy code.
Class describing a truth particle in the MC record.
SG::ReadHandleKey< xAOD::TrackParticleContainer > m_TrackKeyHoughR4
Gaudi::Property< std::string > m_truthSegmentKey
Segment from the truth hits.
def best(iterable, priorities=[3, 2, 1, -1, 0])
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
std::shared_ptr< MuonVal::IParticleFourMomBranch > m_TrksHoughR4
Lightweight algorithm to read xAOD MDT sim hits and (fast-digitised) drift circles from SG and fill a...
std::shared_ptr< MuonVal::IParticleFourMomBranch > m_legacyTrks
Gaudi::Property< std::string > m_segmentKeyR4
Segments made from the R4 segment maker.
Class to store array like branches into the n-tuples.
std::shared_ptr< MuonVal::IParticleFourMomBranch > m_truthTrks
Gaudi::Property< bool > m_isMC
DataVector adapter that acts like it holds const pointers.
virtual StatusCode initialize() override
Gaudi::Property< std::string > m_r4PatternSegmentKey
Segments seeded from the R4 pattern but made with the legacy segment maker.
bool fill(const EventContext &ctx)
Fills the tree per call.
StatusCode write()
Finally write the TTree objects.
MuonVal::MuonTesterTree m_tree
Class describing a TrackParticle.
Handle class for reading from StoreGate.
virtual StatusCode execute() override
SG::ReadHandleKey< xAOD::TrackParticleContainer > m_legacyTrackKey
Key to the track collections.
bool addBranch(std::shared_ptr< IMuonTesterBranch > branch)
Branch is added to the tree without transferring the ownership.