|
ATLAS Offline Software
|
Go to the documentation of this file.
5 #ifndef FPGATRACKSIM_MAPMAKERALG_H
6 #define FPGATRACKSIM_MAPMAKERALG_H
13 #include "GaudiKernel/ToolHandle.h"
45 ToolHandle<IFPGATrackSimEventInputHeaderTool>
m_hitInputTool {
this,
"InputTool",
"FPGATrackSimSGToRawHitsTool/FPGATrackSimInputTool",
"HitInput Tool" };
77 Gaudi::Property<int>
m_maxEvents {
this,
"maxEvents", 10000,
"Max Events"};
78 Gaudi::Property<int>
m_region {
this,
"region", 0,
"Region"};
79 Gaudi::Property<float>
m_trim {
this,
"trim", 0.1,
"trim modules with less than given percent of tracks"};
80 Gaudi::Property<std::string>
m_outFileName {
this,
"OutFileName",
"",
"naming convention for maps"};
81 Gaudi::Property<std::string>
m_keystring {
this,
"KeyString",
"strip,barrel,2",
"key layer to use for subrmap"};
82 Gaudi::Property<std::string>
m_keystring2 {
this,
"KeyString2",
"",
"second key layer for 2D slicing"};
83 Gaudi::Property<int>
m_nSlices {
this,
"nSlices", -1,
"default is full granularity/maximum number of slices possible"};
84 Gaudi::Property<bool>
m_doSpacePoints {
this,
"doSpacePoints",
false,
"Use 9L instead of 8L configuration for first stage (for example)"};
85 Gaudi::Property<float>
m_globalTrim {
this,
"globalTrim", 0.1,
"Trimming applied globally to the key layer before determining slice boundaries"};
86 Gaudi::Property<std::string>
m_description {
this,
"description",
"",
"tag description"};
87 Gaudi::Property<std::string>
m_geoTag {
this,
"GeometryVersion",
"ATLAS-P2-ITK-22-02-00",
"Geometry tag that this set of maps is for. TODO can we store/read from wrappers?"};
88 Gaudi::Property<bool>
m_remapModules {
this,
"remapModules",
false,
"Allow maps to be drawn that slice modules more finely, by remapping module indices"};
89 Gaudi::Property<bool>
m_drawSlices {
this,
"drawSlices",
false,
"Draw the huge 2D slice histograms"};
90 Gaudi::Property<bool>
m_insideout {
this,
"doInsideOut",
false,
"5 layers pixel-only configuration"};
115 const std::vector<std::vector<std::vector<std::string>>>*
m_planes{};
119 {
"pb4"},{
"sb0"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"}
123 {
"pb4"},{
"sb0"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"}
126 {
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"}
129 {
"pb4",
"pe83+",
"pe84+",
"pe85+",
"pe86+",
"pe87+",
"pe88+",
"pe89+"},{
"se5+"},{
"se6+"},{
"se7+"},{
"se8+"},{
"se9+"},{
"se10+"},{
"se11+"}
132 {
"pe34+",
"pe12+"},{
"pe36+",
"pe29+"},{
"pe8+",
"pe40+",
"pe30+"},{
"pe56+",
"pe65+"},{
"pe10+",
"pe6+"},{
"pe11+",
"pe7+"},{
"pe31+",
"pe32+"},{
"pe9+",
"pe53+"}
135 {
"pb4"},{
"sb0"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"}
138 {
"pb4"},{
"sb0"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"}
141 {
"pb4"},{
"sb0"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"}
148 const std::vector< std::vector< std::vector<std::string> > >
m_planes_sp =
151 {
"pb4"},{
"sb0"},{
"sb1"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"}
155 {
"pb4"},{
"sb0"},{
"sb1"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"}
158 {
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"}
161 {
"pb4",
"pe83+",
"pe84+",
"pe85+",
"pe86+",
"pe87+",
"pe88+",
"pe89+"},{
"se4+"},{
"se5+"},{
"se6+"},{
"se7+"},{
"se8+"},{
"se9+"},{
"se10+"},{
"se11+"}
165 {
"pe4+",
"pe5+",
"pe6+"},
166 {
"pe7+",
"pe8+",
"pe9+"},
167 {
"pe10+",
"pe11+",
"pe12+",
"pe29+"},
168 {
"pe30+",
"pe31+",
"pe32+",
"pe33+"},
171 {
"pe38+",
"pe40+",
"pe42+",
"pe53+"},
173 {
"pe56+",
"pe57+",
"pe65+"}
176 {
"pb4"},{
"sb0"},{
"sb1"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"}
179 {
"pb4"},{
"sb0"},{
"sb1"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"}
182 {
"pb4"},{
"sb0"},{
"sb1"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"}
186 const std::vector <std::vector <std::vector <std::string> > >
m_planes2 =
189 {
"pb4"},{
"sb0"},{
"sb1"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"},{
"pb0"},{
"pb1"},{
"pb2"},{
"pb3"}
192 {
"pb4"},{
"sb0"},{
"sb1"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"},{
"pb0"},{
"pb1"},{
"pb2"},{
"pb3"}
195 {
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"}
198 {
"pb4",
"pe83+",
"pe84+",
"pe85+",
"pe86+",
"pe87+",
"pe88+",
"pe89+"},{
"se4+"},{
"se5+"},{
"se6+"},{
"se7+"},{
"se8+"},{
"se9+"},{
"se10+"},{
"se11+"},{
"pb2"},{
"pb3",
"pe58+"},{
"se2+"},{
"se3+"},
201 {
"pe0+"},{
"pe1+"},{
"pe2+"},{
"pe3+"},{
"pe4+"},{
"pe5+"},{
"pe6+"},{
"pe7+"},{
"pe8+"},{
"pe9+"},{
"pe10+"},{
"pe11+"},{
"pe12+"}
204 {
"pb4"},{
"sb0"},{
"sb1"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"},{
"pb0"},{
"pb1"},{
"pb2"},{
"pb3"}
207 {
"pb4"},{
"sb0"},{
"sb1"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"},{
"pb0"},{
"pb1"},{
"pb2"},{
"pb3"}
210 {
"pb4"},{
"sb0"},{
"sb1"},{
"sb2"},{
"sb3"},{
"sb4"},{
"sb5"},{
"sb6"},{
"sb7"},{
"pb0"},{
"pb1"},{
"pb2"},{
"pb3"}
217 {
"pb0"},{
"pb1"},{
"pb2"},{
"pb3"},{
"pb4"}
220 {
"pb0"},{
"pb1"},{
"pb2"},{
"pb3"},{
"pb4"}
223 {
"-1"},{
"-1"},{
"-1"},{
"-1"},{
"-1"}
226 {
"pb0",
"pe0+",
"pe1+",
"pe2+",
"pe3+",
"pe4+",
"pe5+",
"pe6+",
"pe7+",
"pe8+",
"pe9+",
"pe10+",
"pe11+",
"pe12+",
"pe13+",
"pe14+",
"pe15+",
"pe16+", },
227 {
"pb1",
"pe19+",
"pe23+",
"pe25+", },
229 "pe31+",
"pe32+",
"pe33+",
"pe34+",
"pe35+",
"pe36+",
"pe37+",
"pe38+",
"pe39+",
"pe40+",
230 "pe41+",
"pe42+",
"pe43+",
"pe44+",
"pe45+",
"pe46+",
231 "pe47+",
"pe48+",
"pe49+",
"pe50+",
"pe51+",
"pe52+",
"pe53+",
"pe54+",
"pe55+",
"pe56+", },
233 "pe57+",
"pe58+",
"pe59+",
"pe60+",
"pe61+",
"pe62+",
"pe63+",
"pe64+",
"pe65+",
"pe66+",
"pe67+",
"pe68+",
"pe69+"},
234 {
"pb4",
"pe70+",
"pe71+",
"pe72+",
"pe73+",
"pe74+",
"pe75+",
"pe76+",
"pe77+",
"pe78+",
"pe79+",
235 "pe80+",
"pe81+",
"pe82+",
"pe83+",
"pe84+",
"pe85+",
"pe86+",
"pe87+",
"pe88+",
"pe89+",}
238 {
"pe0+"},{
"pe1+"},{
"pe2+"},{
"pe3+"},{
"pe4+"}
241 {
"pb0"},{
"pb1"},{
"pb2"},{
"pb3"},{
"pb4"}
244 {
"pb0"},{
"pb1"},{
"pb2"},{
"pb3"},{
"pb4"}
247 {
"pb0"},{
"pb1"},{
"pb2"},{
"pb3"},{
"pb4"}
258 std::vector <std::vector < std::vector<float> > >
m_radii;
259 std::vector <std::vector < std::vector<float> > >
m_z;
269 StatusCode writePmapAndRmap(std::vector<FPGATrackSimHit>
const & pbHits, std::vector<FPGATrackSimHit>
const & peHits, std::vector<FPGATrackSimHit>
const & sbHits, std::vector<FPGATrackSimHit>
const & seHits,
int region);
276 void drawSlices(std::vector<FPGATrackSimHit>
const & allHits);
280 int findPlane(
const std::vector<std::vector<std::string>>& planes,
const std::string&
test);
287 #endif // FPGATRACKSIMMAPMAKERALG_H
const std::vector< std::vector< std::vector< std::string > > > m_planes_default
std::string makeSubrmapLines(std::vector< Module * > const &allmods, SiliconTech det, DetectorZone bec, int max)
Gaudi::Property< std::string > m_description
bool operator>(const Module &m) const
std::map< int, std::vector< Module * > > m_track2modules
Gaudi::Property< std::string > m_outFileName
Gaudi::Property< int > m_maxEvents
std::unique_ptr< TFile > m_monitorFile
void drawSlices(std::vector< FPGATrackSimHit > const &allHits)
const std::vector< std::vector< std::vector< std::string > > > m_planes_sp
StatusCode initialize() override
bool isOnKeyLayer(int keynum, SiliconTech det, DetectorZone bec, int lyr)
Gaudi::Property< float > m_globalTrim
std::vector< FPGATrackSimHit > m_sbHits
std::map< std::string, SiliconTech > m_det2tech
int findPlane(const std::vector< std::vector< std::string >> &planes, const std::string &test)
StatusCode readInputs(bool &done)
FPGATrackSimEventInputHeader m_eventHeader
ToolHandle< IFPGATrackSimEventInputHeaderTool > m_hitInputTool
std::vector< FPGATrackSimHit > m_pbHits
std::tuple< SiliconTech, DetectorZone, int, int, int > FPGATrackSimModuleId
bool operator<(const Module &m) const
std::vector< FPGATrackSimHit > m_peHits
FPGATrackSimModuleId moduleId() const
Gaudi::Property< bool > m_insideout
StatusCode writePmapAndRmap(std::vector< FPGATrackSimHit > const &pbHits, std::vector< FPGATrackSimHit > const &peHits, std::vector< FPGATrackSimHit > const &sbHits, std::vector< FPGATrackSimHit > const &seHits, int region)
virtual ~FPGATrackSimMapMakerAlg()=default
std::map< int, int > m_track2slice
const std::vector< std::vector< std::vector< std::string > > > m_planes_insideout
std::map< std::string, std::set< int > > m_keylayer2
const std::vector< uint32_t > m_diskIndex
StatusCode writeRadiiFile(std::vector< FPGATrackSimHit > const &allHits)
std::map< int, int > m_key_etamods
std::set< int > m_usedTracks
const std::vector< std::vector< std::vector< std::string > > > m_planes2
Gaudi::Property< std::string > m_keystring2
std::string makeRmapLines(std::vector< FPGATrackSimHit > const &hits, SiliconTech det, DetectorZone bec, int max)
::StatusCode StatusCode
StatusCode definition for legacy code.
std::vector< std::vector< std::vector< float > > > m_radii
Gaudi::Property< bool > m_drawSlices
Module(SiliconTech det, DetectorZone bec, int lyr, int eta, int phi)
std::map< std::string, std::set< int > > m_keylayer
StatusCode writeEtaPatterns()
Gaudi::Property< int > m_nSlices
Gaudi::Property< bool > m_remapModules
std::map< std::string, DetectorZone > m_bec2zone
Gaudi::Property< std::string > m_keystring
std::set< int > m_key_etamods2
StatusCode writeMedianZFile(std::vector< FPGATrackSimHit > const &allHits)
std::vector< std::vector< std::vector< float > > > m_z
Gaudi::Property< float > m_trim
Gaudi::Property< bool > m_doSpacePoints
FPGATrackSimMapMakerAlg(const std::string &name, ISvcLocator *pSvcLocator)
StatusCode finalize() override
Gaudi::Property< std::string > m_geoTag
std::vector< FPGATrackSimHit > m_seHits
std::map< FPGATrackSimModuleId, Module > m_modules
FPGATrackSimModuleRelabel * m_moduleRelabel
std::vector< int > m_semax
std::vector< int > m_pemax
StatusCode writeSubrmap(std::vector< FPGATrackSimHit > const &allHits)
Gaudi::Property< int > m_region
std::vector< int > numTracks
bool operator==(const Module &m) const
std::vector< FPGATrackSimHit > m_allHits
std::map< int, std::vector< Module * > > m_slice2modules
const std::vector< std::vector< std::vector< std::string > > > * m_planes
StatusCode execute() override