ATLAS Offline Software
Loading...
Searching...
No Matches
ActsTrk::SeedContainer Struct Referencefinal

#include <SeedContainer.h>

Collaboration diagram for ActsTrk::SeedContainer:

Public Types

using Index = Acts::SeedIndex2
using value_type = Seed
using const_iterator

Public Member Functions

std::size_t size () const noexcept
bool empty () const noexcept
void reserve (std::size_t size, float averageSpacePoints=3) noexcept
void clear () noexcept
Seed operator[] (Index index) const noexcept
Seed at (Index index) const
SpacePointRange spacePoints (Index index) const noexcept
float quality (Index index) const noexcept
float vertexZ (Index index) const noexcept
const_iterator begin () const noexcept
const_iterator end () const noexcept
Seed push_back (SpacePointRange spacePoints, float quality, float vertexZ)
template<typename arbitrary_sp_range_t, typename xaod_sp_ptr_projector_t>
Seed push_back (const arbitrary_sp_range_t &arbitrarySpacePoints, const xaod_sp_ptr_projector_t &xAODspProjector, float quality, float vertexZ)
Seed push_back (SpacePointRange spacePoints, const Acts::ConstSeedProxy2 &seed)
template<typename xaod_sp_ptr_projector_t>
Seed push_back (const Acts::ConstSeedProxy2 &seed, const xaod_sp_ptr_projector_t &xAODspProjector)
template<typename arbitrary_sp_range_t, typename xaod_sp_ptr_projector_t>
Seed push_back (const arbitrary_sp_range_t &arbitrarySpacePoints, const xaod_sp_ptr_projector_t &xAODspProjector, const Acts::ConstSeedProxy2 &seed)
template<typename sp_proxy_t, std::size_t N>
Seed push_back (const Acts::Seed< sp_proxy_t, N > &pSeed)

Private Member Functions

void push_back_ (std::size_t nSpacePoints, float quality, float vertexZ)

Private Attributes

std::uint32_t m_size {0}
std::vector< std::uint32_t > m_spacePointOffsets
std::vector< std::uint8_t > m_spacePointCounts
std::vector< float > m_qualities
std::vector< float > m_vertexZs
std::vector< const xAOD::SpacePoint * > m_spacePoints

Detailed Description

Definition at line 67 of file SeedContainer.h.

Member Typedef Documentation

◆ const_iterator

Initial value:
Acts::detail::ContainerIterator<SeedContainer, Seed, Index, true>

Definition at line 105 of file SeedContainer.h.

◆ Index

using ActsTrk::SeedContainer::Index = Acts::SeedIndex2

Definition at line 68 of file SeedContainer.h.

◆ value_type

Definition at line 69 of file SeedContainer.h.

Member Function Documentation

◆ at()

Seed ActsTrk::SeedContainer::at ( Index index) const
inline

Definition at line 90 of file SeedContainer.h.

90 {
91 if (index >= size()) {
92 throw std::out_of_range("SeedContainer index out of range");
93 }
94 return Seed(*this, index);
95 }
std::size_t size() const noexcept

◆ begin()

const_iterator ActsTrk::SeedContainer::begin ( ) const
inlinenoexcept

Definition at line 108 of file SeedContainer.h.

108{ return const_iterator(*this, 0); }
Acts::detail::ContainerIterator< SeedContainer, Seed, Index, true > const_iterator

◆ clear()

void ActsTrk::SeedContainer::clear ( )
inlinenoexcept

Definition at line 80 of file SeedContainer.h.

80 {
81 m_size = 0;
82 m_spacePointOffsets.clear();
83 m_spacePointCounts.clear();
84 m_qualities.clear();
85 m_vertexZs.clear();
86 m_spacePoints.clear();
87 }
std::vector< std::uint8_t > m_spacePointCounts
std::vector< const xAOD::SpacePoint * > m_spacePoints
std::vector< float > m_qualities
std::vector< float > m_vertexZs
std::vector< std::uint32_t > m_spacePointOffsets

◆ empty()

bool ActsTrk::SeedContainer::empty ( ) const
inlinenoexcept

Definition at line 72 of file SeedContainer.h.

72{ return size() == 0; }

◆ end()

const_iterator ActsTrk::SeedContainer::end ( ) const
inlinenoexcept

Definition at line 109 of file SeedContainer.h.

109{ return const_iterator(*this, size()); }

◆ operator[]()

Seed ActsTrk::SeedContainer::operator[] ( Index index) const
inlinenoexcept

Definition at line 89 of file SeedContainer.h.

89{ return Seed(*this, index); }

◆ push_back() [1/6]

template<typename xaod_sp_ptr_projector_t>
Seed ActsTrk::SeedContainer::push_back ( const Acts::ConstSeedProxy2 & seed,
const xaod_sp_ptr_projector_t & xAODspProjector )
inline

Definition at line 137 of file SeedContainer.h.

138 {
139 return push_back(seed.spacePointIndices(), xAODspProjector, seed);
140 }
Seed push_back(SpacePointRange spacePoints, float quality, float vertexZ)

◆ push_back() [2/6]

template<typename sp_proxy_t, std::size_t N>
Seed ActsTrk::SeedContainer::push_back ( const Acts::Seed< sp_proxy_t, N > & pSeed)
inline

Definition at line 153 of file SeedContainer.h.

153 {
154 return push_back(
155 pSeed.sp(),
156 [](const sp_proxy_t* sp) { return &sp->externalSpacePoint(); },
157 pSeed.seedQuality(), pSeed.z());
158 }
static Double_t sp

◆ push_back() [3/6]

template<typename arbitrary_sp_range_t, typename xaod_sp_ptr_projector_t>
Seed ActsTrk::SeedContainer::push_back ( const arbitrary_sp_range_t & arbitrarySpacePoints,
const xaod_sp_ptr_projector_t & xAODspProjector,
const Acts::ConstSeedProxy2 & seed )
inline

Definition at line 143 of file SeedContainer.h.

145 {
146 return push_back(arbitrarySpacePoints, xAODspProjector, seed.quality(),
147 seed.vertexZ());
148 }

◆ push_back() [4/6]

template<typename arbitrary_sp_range_t, typename xaod_sp_ptr_projector_t>
Seed ActsTrk::SeedContainer::push_back ( const arbitrary_sp_range_t & arbitrarySpacePoints,
const xaod_sp_ptr_projector_t & xAODspProjector,
float quality,
float vertexZ )
inline

Definition at line 121 of file SeedContainer.h.

123 {
124 push_back_(arbitrarySpacePoints.size(), quality, vertexZ);
125 std::ranges::copy(
126 std::views::transform(arbitrarySpacePoints, xAODspProjector),
127 std::back_inserter(m_spacePoints));
128 return at(m_size++);
129 }
Seed at(Index index) const
void push_back_(std::size_t nSpacePoints, float quality, float vertexZ)
float quality(Index index) const noexcept
float vertexZ(Index index) const noexcept

◆ push_back() [5/6]

Seed ActsTrk::SeedContainer::push_back ( SpacePointRange spacePoints,
const Acts::ConstSeedProxy2 & seed )
inline

Definition at line 131 of file SeedContainer.h.

132 {
133 return push_back(spacePoints, seed.quality(), seed.vertexZ());
134 }
SpacePointRange spacePoints(Index index) const noexcept

◆ push_back() [6/6]

Seed ActsTrk::SeedContainer::push_back ( SpacePointRange spacePoints,
float quality,
float vertexZ )
inline

Definition at line 113 of file SeedContainer.h.

113 {
115 m_spacePoints.insert(m_spacePoints.end(), spacePoints.begin(),
116 spacePoints.end());
117 return at(m_size++);
118 }

◆ push_back_()

void ActsTrk::SeedContainer::push_back_ ( std::size_t nSpacePoints,
float quality,
float vertexZ )
inlineprivate

Definition at line 169 of file SeedContainer.h.

169 {
170 const std::uint32_t offset =
171 static_cast<std::uint32_t>(m_spacePoints.size());
172 const std::uint8_t count = static_cast<std::uint8_t>(nSpacePoints);
173
174 m_spacePointOffsets.push_back(offset);
175 m_spacePointCounts.push_back(count);
176 m_qualities.push_back(quality);
177 m_vertexZs.push_back(vertexZ);
178 }
int count(std::string s, const std::string &regx)
count how many occurances of a regx are in a string
Definition hcg.cxx:146

◆ quality()

float ActsTrk::SeedContainer::quality ( Index index) const
inlinenoexcept

Definition at line 102 of file SeedContainer.h.

102{ return m_qualities[index]; }
str index
Definition DeMoScan.py:362

◆ reserve()

void ActsTrk::SeedContainer::reserve ( std::size_t size,
float averageSpacePoints = 3 )
inlinenoexcept

Definition at line 73 of file SeedContainer.h.

73 {
75 m_spacePointCounts.reserve(size);
76 m_qualities.reserve(size);
77 m_vertexZs.reserve(size);
78 m_spacePoints.reserve(static_cast<std::size_t>(size * averageSpacePoints));
79 }

◆ size()

std::size_t ActsTrk::SeedContainer::size ( ) const
inlinenoexcept

Definition at line 71 of file SeedContainer.h.

71{ return m_size; }

◆ spacePoints()

SpacePointRange ActsTrk::SeedContainer::spacePoints ( Index index) const
inlinenoexcept

Definition at line 97 of file SeedContainer.h.

97 {
98 const std::uint32_t offset = m_spacePointOffsets[index];
99 const std::uint8_t count = m_spacePointCounts[index];
100 return SpacePointRange(m_spacePoints.data() + offset, count);
101 }

◆ vertexZ()

float ActsTrk::SeedContainer::vertexZ ( Index index) const
inlinenoexcept

Definition at line 103 of file SeedContainer.h.

103{ return m_vertexZs[index]; }

Member Data Documentation

◆ m_qualities

std::vector<float> ActsTrk::SeedContainer::m_qualities
private

Definition at line 164 of file SeedContainer.h.

◆ m_size

std::uint32_t ActsTrk::SeedContainer::m_size {0}
private

Definition at line 161 of file SeedContainer.h.

161{0};

◆ m_spacePointCounts

std::vector<std::uint8_t> ActsTrk::SeedContainer::m_spacePointCounts
private

Definition at line 163 of file SeedContainer.h.

◆ m_spacePointOffsets

std::vector<std::uint32_t> ActsTrk::SeedContainer::m_spacePointOffsets
private

Definition at line 162 of file SeedContainer.h.

◆ m_spacePoints

std::vector<const xAOD::SpacePoint*> ActsTrk::SeedContainer::m_spacePoints
private

Definition at line 167 of file SeedContainer.h.

◆ m_vertexZs

std::vector<float> ActsTrk::SeedContainer::m_vertexZs
private

Definition at line 165 of file SeedContainer.h.


The documentation for this struct was generated from the following file: