|
ATLAS Offline Software
|
Go to the documentation of this file.
26 if (m_measKeys.empty()) {
27 ATH_MSG_FATAL(
"Please configure the measurement containers to decorate.");
28 return StatusCode::FAILURE;
31 for (
const auto&
key : m_measKeys) {
32 m_writeMarkKeys.emplace_back(
key, m_writeMarker);
33 m_writeSegLinkKeys.emplace_back(
key, m_segLink);
36 ATH_CHECK(m_writeSegLinkKeys.initialize());
37 return StatusCode::SUCCESS;
42 std::unordered_map<const SG::AuxVectorData*, MarkerHandle_t>
markers{};
43 std::unordered_map<Muon::MuonStationIndex::TechnologyIndex, std::vector<const PrdCont_t*>> techConts{};
47 if (readHandle->empty()) {
51 markers.insert(std::make_pair(readHandle.cptr(), std::move(decor)));
54 techConts[techIdx].push_back(readHandle.cptr());
56 std::unordered_map<const SG::AuxVectorData*, LinkHandle_t>
links{};
59 if (readHandle->empty()){
63 links.insert(std::make_pair(readHandle.cptr(), std::move(decor)));
67 for (
const PrdCont_t* prdCont : techConts[m_idHelperSvc->technologyIndex(hit->identify())]){
70 ATH_MSG_VERBOSE(
"Found hit matched to "<<m_idHelperSvc->toString(hit->identify()));
75 ATH_MSG_VERBOSE(
"Nothing could be matched to "<<m_idHelperSvc->toString(hit->identify()));
92 return StatusCode::SUCCESS;
Property holding a SG store/key/clid/attr name from which a WriteDecorHandle is made.
const Identifier & identify(const UncalibratedMeasurement *meas)
Returns the associated identifier from the muon measurement.
xAOD::UncalibratedMeasurementContainer PrdCont_t
SG::ReadHandle< T > makeHandle(const SG::View *view, const SG::ReadHandleKey< T > &rhKey, const EventContext &context)
navigate from the TrigComposite to nearest view and fetch object from it
SG::WriteDecorHandle< PrdCont_t, SegLinkVec_t > LinkHandle_t
Class describing a MuonSegment.
#define ATH_MSG_VERBOSE(x)
virtual StatusCode initialize() override final
SG::WriteDecorHandle< PrdCont_t, bool > MarkerHandle_t
::StatusCode StatusCode
StatusCode definition for legacy code.
Handle class for adding a decoration to an object.
Handle class for adding a decoration to an object.
ElementLink< xAOD::MuonSegmentContainer > SegLink_t
ElementLink implementation for ROOT usage.
UncalibratedMeasurementContainer_v1 UncalibratedMeasurementContainer
Define the version of the uncalibrated measurement container.
virtual StatusCode execute(const EventContext &ctx) const override final
This header ties the generic definitions in this package.
ElementConstPointer cptr() const
Return a pointer to the referenced element.
std::vector< SegLink_t > SegLinkVec_t
SG::WriteDecorHandleKey< xAOD::UncalibratedMeasurementContainer > WriteDecorKey_t
const xAOD::MuonSimHit * getTruthMatchedHit(const xAOD::UncalibratedMeasurement &prdHit)
Returns the MuonSimHit, if there's any, matched to the uncalibrated muon measurement.
Handle class for reading a decoration on an object.
const SG::AuxVectorData * container() const
Return the container holding this element.
Handle class for reading from StoreGate.
TechnologyIndex
enum to classify the different layers in the muon spectrometer
std::unordered_set< const xAOD::MuonSimHit * > getMatchingSimHits(const xAOD::MuonSegment &segment)
: Returns all sim hits matched to a xAOD::MuonSegment
Muon::NSW_PadTriggerSegment segment(const NSWL1::PadTrigger &data)