 |
ATLAS Offline Software
|
Go to the documentation of this file.
14 std::map<std::string, std::vector<std::pair<int,std::string>>> tempMap;
17 for (
const auto & [feb2, muxInfo] : febMap) {
21 m_muxFlags.insert({muxInfo.muxName, {
false,
false}});
24 tempMap[muxInfo.muxName].emplace_back(muxInfo.indexOnMux, feb2);
28 for (
auto& [muxName,
vec] : tempMap) {
29 std::sort(
vec.begin(),
vec.end(), [](
const auto&
a,
const auto&
b) {
30 return a.first < b.first;
34 std::vector<std::string> orderedFeb2s;
35 orderedFeb2s.reserve(
vec.size());
36 for (
const auto& [
idx, feb2] :
vec) {
37 orderedFeb2s.push_back(feb2);
49 for (
const auto& cellPtr :
other) {
66 auto cell = std::make_unique<GlobalLArCell>(theCell);
67 auto* cellPtr =
cell.get();
77 static const std::vector<GlobalLArCell*> emptyCellVector;
84 return emptyCellVector;
91 static const std::vector<std::string> emptyMux;
105 throw std::runtime_error(
"Unknown FEB2 key: " + feb2Key);
114 flags.overflow = overflow;
120 muxFlags.overflow = overflow;
124 muxFlags.error =
error;
bool feb2InOverflow(const std::string &feb2Key) const
Check if a given FEB2 is in overflow.
const std::vector< std::string > & getOrderedFeb2sForMux(const std::string &mux) const
Function to get ordered list of FEB2s for a given MUX name.
bool feb2InError(const std::string &feb2Key) const
Check if a given FEB2 is in error.
GlobalLArCellContainer()=default
Default constructor.
void push_back(const GlobalLArCell &theCell)
Reimplementation of the push_back function to fill LArCells.
std::map< std::string, StatusFlags > m_muxFlags
map which stores overflow and error bits for each MUX
std::vector< size_t > vec
std::unordered_set< std::string > m_muxKeys
vector of all MUX names
std::size_t m_maxCellsPerFeb2
Maximum number of cells per FEB2 in given energy encoding scheme.
AlgTool to obtain a selection of eFex RoIs read in from the event store.
const std::vector< GlobalLArCell * > & getCellsForFeb2(const std::string &feb2) const
Function to get all GlobalLArCells for a given FEB2 name.
std::unordered_set< std::string > m_feb2Keys
vector of all FEB2 names
std::map< std::string, StatusFlags > m_feb2Flags
map which stores overflow and error bits for each FEB2
value_type push_back(value_type pElem)
Add an element to the end of the collection.
const std::string & getMuxForFeb2(const std::string &feb2Key) const
Function to get the associated MUX name for a given FEB2.
bool muxInOverflow(const std::string &muxKey) const
Check if a given MUX is in overflow.
void setFeb2Flags(const std::string &feb2Key, bool overflow, bool error)
Set overflow and error flag for a FEB2.
std::map< std::string, std::vector< GlobalLArCell * > > m_feb2ToCells
map which keeps track of which cells are associated with which FEB2
std::map< std::string, std::vector< std::string > > m_muxToFeb2Ordered
map which holds the ordered list of FEB2s for each MUX
std::map< std::string, std::string > m_feb2ToMux
map which acts as lookuptable to get the associated MUX from a FEB2 name
bool muxInError(const std::string &muxKey) const
Check if a given MUX is in error.