ATLAS Offline Software
Loading...
Searching...
No Matches
FPGATrackSimModuleRelabel.h
Go to the documentation of this file.
1// Copyright (C) 2023-2025 CERN for the benefit of the ATLAS collaboration
2
3// Module relabel object for remapping pixel endcap hits.
4// This small header contains a very simple object, which implements
5// the geokey -> ring index lookup for use in multiple places and provides
6// a function for actually remapping pixel endcap hits.
7
8#ifndef FPGATRACKSIMMODULERELABEL_H
9#define FPGATRACKSIMMODULERELABEL_H
10#include "AthenaBaseComps/AthMessaging.h" //inheritance
11
12
13#include <map>
14#include <vector>
15#include <string>
16
17class FPGATrackSimHit;
18
19// this doesn't necessarily have to live in a namespace, but it would
20// if it were in FPGATrackSimMacros.h.
21// New supported geometries should be added here.
22namespace htt {
23 const std::map<const std::string, const std::vector<uint>> ringIndices = {
24 {"ATLAS-P2-ITK-22-02-00", {0, 17, 47, 58, 66}},
25 {"ATLAS-P2-ITK-23-00-01", {0, 15, 44, 50, 61, 69, 77, 86}},
26 {"ATLAS-P2-RUN4-03-00-00", {0, 15, 21, 44, 50, 61, 69, 77, 86}}
27 };
28}
29
31
32public:
33
34 // Constructor, maps geokey -> ringIndex.
35 FPGATrackSimModuleRelabel(const std::string & geokey, bool remapModules);
36
37 bool remap(FPGATrackSimHit& hit) const;
38
39private:
40
41 // Geometry version, set by constructor.
42 std::string m_geoKey;
43
44 // Should we remap modules in addition to layers.
45 bool m_remapModules = false;
46
47 // Vector of size (nrings): used to remap (ring, module) -> (layer).
48 // Indexed by ring number.
49 const std::vector<uint>* m_ringIndex = nullptr;
50
51};
52
53#endif
AthMessaging(IMessageSvc *msgSvc, const std::string &name)
Constructor.
const std::vector< uint > * m_ringIndex
FPGATrackSimModuleRelabel(const std::string &geokey, bool remapModules)
std::map< std::string, std::string > remap
list of directories to be explicitly remapped
Definition hcg.cxx:95
const std::map< const std::string, const std::vector< uint > > ringIndices