ATLAS Offline Software
Public Member Functions | Private Types | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
ActsTrk::SiSpacePointsSeedMaker Class Reference

#include <SiSpacePointsSeedMaker.h>

Inheritance diagram for ActsTrk::SiSpacePointsSeedMaker:
Collaboration diagram for ActsTrk::SiSpacePointsSeedMaker:

Public Member Functions

 SiSpacePointsSeedMaker (const std::string &t, const std::string &n, const IInterface *p)
 
virtual ~SiSpacePointsSeedMaker () override=default
 
virtual StatusCode initialize () override
 
virtual void newEvent (const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, int iteration=-1) const override
 
virtual void find3Sp (const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const std::list< Trk::Vertex > &lv) const override
 
virtual const InDet::SiSpacePointsSeednext (const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data) const override
 
virtual void writeNtuple (const InDet::SiSpacePointsSeed *seed, const Trk::Track *track, int seedType, long eventNumber) const override
 
virtual bool getWriteNtupleBoolProperty () const override
 
virtual MsgStream & dump (InDet::SiSpacePointsSeedMakerEventData &data, MsgStream &out) const override
 
virtual void newRegion (const EventContext &, InDet::SiSpacePointsSeedMakerEventData &, const std::vector< IdentifierHash > &, const std::vector< IdentifierHash > &) const override
 
virtual void newRegion (const EventContext &, InDet::SiSpacePointsSeedMakerEventData &, const std::vector< IdentifierHash > &, const std::vector< IdentifierHash > &, const IRoiDescriptor &) const override
 
virtual void find2Sp (InDet::SiSpacePointsSeedMakerEventData &, const std::list< Trk::Vertex > &) const override
 
virtual void find3Sp (const EventContext &, InDet::SiSpacePointsSeedMakerEventData &, const std::list< Trk::Vertex > &, const double *) const override
 with three space points with or without vertex constraint with information about min and max Z of the vertex More...
 
virtual void findVSp (const EventContext &, InDet::SiSpacePointsSeedMakerEventData &, const std::list< Trk::Vertex > &) const override
 with variable number space points with or without vertex constraint Variable means (2,3,4,....) any number space points More...
 

Private Types

enum  SeedStrategy : short { PPP, SSS }
 

Private Member Functions

MsgStream & dumpConditions (InDet::SiSpacePointsSeedMakerEventData &data, MsgStream &out) const
 
void buildBeamFrameWork (const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data) const
 
void newSpacePoint (InDet::SiSpacePointsSeedMakerEventData &data, const xAOD::SpacePoint *const &sp) const
 
bool skipSpacePoint (float x, float y, float z) const
 
bool convertPixelSeed (const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const ActsTrk::SeedContainer &seedPtrs) const
 
bool convertStripSeed (const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const ActsTrk::SeedContainer &seedPtrs) const
 
StatusCode retrievePixel (const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const Trk::PRDtoTrackMap *prd_to_track_map_cptr) const
 
StatusCode retrieveStrip (const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const Trk::PRDtoTrackMap *prd_to_track_map_cptr) const
 
StatusCode retrieveOverlap (const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const Trk::PRDtoTrackMap *prd_to_track_map_cptr) const
 
StatusCode retrievePixel (const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const std::vector< IdentifierHash > &ids, const Trk::PRDtoTrackMap *prd_to_track_map_cptr=nullptr) const
 
StatusCode retrieveStrip (const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const std::vector< IdentifierHash > &ids, const Trk::PRDtoTrackMap *prd_to_track_map_cptr=nullptr) const
 
StatusCode retrieveOverlap (const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const std::vector< IdentifierHash > &ids, const Trk::PRDtoTrackMap *prd_to_track_map_cptr) const
 
StatusCode InitTree ()
 
bool isUsed (const Trk::SpacePoint *, const Trk::PRDtoTrackMap &prd_to_track_map) const
 
bool isUsed (const xAOD::SpacePoint *, const Trk::PRDtoTrackMap &prd_to_track_map) const
 

Static Private Member Functions

static MsgStream & dumpEvent (InDet::SiSpacePointsSeedMakerEventData &data, MsgStream &out)
 
static void pixInform (const Trk::SpacePoint *const &sp, float *r)
 
static void stripInform (InDet::SiSpacePointsSeedMakerEventData &data, const Trk::SpacePoint *const &sp, float *r)
 

Private Attributes

ToolHandle< ActsTrk::ISeedingToolm_seedsToolPixel {this, "SeedToolPixel", "","Seed Tool for Pixel detector"}
 
ToolHandle< ActsTrk::ISeedingToolm_seedsToolStrip {this, "SeedToolStrip", "","Seed Tool for Strip detector"}
 
SG::ReadHandleKey< Trk::PRDtoTrackMapm_prdToTrackMap {this, "PRDtoTrackMap", "", "option PRD-to-track association"}
 
SG::ReadHandleKey< xAOD::SpacePointContainerm_actsSpacepointsPixel {this, "ActsSpacePointsPixelName", "", "Pixel space points container"}
 
SG::ReadHandleKey< xAOD::SpacePointContainerm_actsSpacepointsStrip {this, "ActsSpacePointsStripName", "", "Strip space points container"}
 
SG::ReadHandleKey< xAOD::SpacePointContainerm_actsSpacepointsOverlap {this, "ActsSpacePointsOverlapName", "", "Strip overlap space points container"}
 
SG::ReadCondHandleKey< InDet::BeamSpotDatam_beamSpotKey {this, "BeamSpotKey", "BeamSpotData", "SG key for beam spot"}
 
SG::ReadCondHandleKey< AtlasFieldCacheCondObjm_fieldCondObjInputKey
 
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollectionm_pixelDetEleCollKey
 
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollectionm_stripDetEleCollKey
 
Gaudi::Property< bool > m_pixel {this, "usePixel", true}
 
Gaudi::Property< bool > m_strip {this, "useStrip", true }
 
Gaudi::Property< bool > m_useOverlap {this, "useOverlapSpCollection", true}
 
Gaudi::Property< bool > m_fastTracking {this, "useFastTracking", false}
 
Gaudi::Property< bool > m_doSeedConversion {this, "doSeedConversion", true, "Convert ActsTrk::Seed into ITk::SiSpacePointsProSeed"}
 
Gaudi::Property< bool > m_useClusters {this, "useClustersForSeedConversion", false}
 
Gaudi::Property< bool > m_writeNtuple {this, "WriteNtuple", false}
 
std::mutex m_mutex
 
ITHistSvc * m_thistSvc = nullptr
 
TTree * m_outputTree = nullptr
 
std::string m_treeName ATLAS_THREAD_SAFE = ""
 
std::string m_treeFolder ATLAS_THREAD_SAFE = "/valNtuples/"
 
float m_d0 ATLAS_THREAD_SAFE = 0
 
float m_z0 ATLAS_THREAD_SAFE = 0
 
float m_pt ATLAS_THREAD_SAFE = 0
 
float m_eta ATLAS_THREAD_SAFE = 0
 
double m_x1 ATLAS_THREAD_SAFE = 0
 
double m_x2 ATLAS_THREAD_SAFE = 0
 
double m_x3 ATLAS_THREAD_SAFE = 0
 
double m_y1 ATLAS_THREAD_SAFE = 0
 
double m_y2 ATLAS_THREAD_SAFE = 0
 
double m_y3 ATLAS_THREAD_SAFE = 0
 
double m_z1 ATLAS_THREAD_SAFE = 0
 
double m_z2 ATLAS_THREAD_SAFE = 0
 
double m_z3 ATLAS_THREAD_SAFE = 0
 
double m_r1 ATLAS_THREAD_SAFE = 0
 
double m_r2 ATLAS_THREAD_SAFE = 0
 
double m_r3 ATLAS_THREAD_SAFE = 0
 
float m_quality ATLAS_THREAD_SAFE = 0
 
int m_type ATLAS_THREAD_SAFE = 0
 
double m_dzdr_t ATLAS_THREAD_SAFE = 0
 
double m_dzdr_b ATLAS_THREAD_SAFE = 0
 
bool m_givesTrack ATLAS_THREAD_SAFE = false
 
float m_trackPt ATLAS_THREAD_SAFE = 0
 
float m_trackEta ATLAS_THREAD_SAFE = 0
 
long m_eventNumber ATLAS_THREAD_SAFE = 0
 

Detailed Description

Definition at line 44 of file SiSpacePointsSeedMaker.h.

Member Enumeration Documentation

◆ SeedStrategy

Enumerator
PPP 
SSS 

Definition at line 47 of file SiSpacePointsSeedMaker.h.

47 : short {PPP, SSS};

Constructor & Destructor Documentation

◆ SiSpacePointsSeedMaker()

ActsTrk::SiSpacePointsSeedMaker::SiSpacePointsSeedMaker ( const std::string &  t,
const std::string &  n,
const IInterface *  p 
)

Definition at line 36 of file SiSpacePointsSeedMaker.cxx.

37  : base_class(t, n, p)
38  {}

◆ ~SiSpacePointsSeedMaker()

virtual ActsTrk::SiSpacePointsSeedMaker::~SiSpacePointsSeedMaker ( )
overridevirtualdefault

Member Function Documentation

◆ buildBeamFrameWork()

void ActsTrk::SiSpacePointsSeedMaker::buildBeamFrameWork ( const EventContext &  ctx,
InDet::SiSpacePointsSeedMakerEventData data 
) const
private

Definition at line 412 of file SiSpacePointsSeedMaker.cxx.

414  {
416 
417  const Amg::Vector3D &cb = beamSpotHandle->beamPos();
418  double tx = std::tan(beamSpotHandle->beamTilt(0));
419  double ty = std::tan(beamSpotHandle->beamTilt(1));
420 
421  double phi = std::atan2(ty, tx);
422  double theta = std::acos(1. / std::sqrt(1. + tx * tx + ty * ty));
423  double sinTheta = std::sin(theta);
424  double cosTheta = std::cos(theta);
425  double sinPhi = std::sin(phi);
426  double cosPhi = std::cos(phi);
427 
428  data.xbeam[0] = static_cast<float>(cb.x());
429  data.xbeam[1] = static_cast<float>(cosTheta * cosPhi * cosPhi + sinPhi * sinPhi);
430  data.xbeam[2] = static_cast<float>(cosTheta * sinPhi * cosPhi - sinPhi * cosPhi);
431  data.xbeam[3] = -static_cast<float>(sinTheta * cosPhi);
432 
433  data.ybeam[0] = static_cast<float>(cb.y());
434  data.ybeam[1] = static_cast<float>(cosTheta * cosPhi * sinPhi - sinPhi * cosPhi);
435  data.ybeam[2] = static_cast<float>(cosTheta * sinPhi * sinPhi + cosPhi * cosPhi);
436  data.ybeam[3] = -static_cast<float>(sinTheta * sinPhi);
437 
438  data.zbeam[0] = static_cast<float>(cb.z());
439  data.zbeam[1] = static_cast<float>(sinTheta * cosPhi);
440  data.zbeam[2] = static_cast<float>(sinTheta * sinPhi);
441  data.zbeam[3] = static_cast<float>(cosTheta);
442 
443  // Acts Seed Tool requires both MagneticFieldContext and BeamSpotData
444  // we need to retrieve them both from StoreGate
445  // Read the b-field information
447  if ( not readHandle.isValid() ) {
448  throw std::runtime_error("Error while retrieving Atlas Field Cache Cond DB");
449  }
450  const AtlasFieldCacheCondObj* fieldCondObj{ *readHandle };
451  if (fieldCondObj == nullptr) {
452  throw std::runtime_error("Failed to retrieve AtlasFieldCacheCondObj with key " + m_fieldCondObjInputKey.key());
453  }
454 
455  // Get the magnetic field
456  // Using ACTS classes in order to be sure we are consistent
457  Acts::MagneticFieldContext magFieldContext(fieldCondObj);
458 
459  // Beam Spot Position
460  Acts::Vector3 beamPos( data.xbeam[0] * Acts::UnitConstants::mm,
461  data.ybeam[0] * Acts::UnitConstants::mm,
462  0. );
463 
464  // Magnetic Field
465  ATLASMagneticFieldWrapper magneticField;
466  Acts::MagneticFieldProvider::Cache magFieldCache = magneticField.makeCache( magFieldContext );
467  Acts::Vector3 bField = *magneticField.getField( beamPos,
468  magFieldCache );
469 
470  data.bField[0] = bField[0];
471  data.bField[1] = bField[1];
472  data.bField[2] = bField[2];
473 
474  data.K = 2. * s_toTesla / (300. * bField[2]);
475 
476  }

◆ convertPixelSeed()

bool ActsTrk::SiSpacePointsSeedMaker::convertPixelSeed ( const EventContext &  ctx,
InDet::SiSpacePointsSeedMakerEventData data,
const ActsTrk::SeedContainer seedPtrs 
) const
private

Definition at line 979 of file SiSpacePointsSeedMaker.cxx.

981  {
982  // If the read handle key for clusters is not empty, that means the xAOD->InDet Cluster link is available
983  // Else we can use xAOD->Trk Space Point link
984  // If none of these is available, we have a JO misconfguration!
985  static const SG::AuxElement::Accessor< ElementLink< InDet::PixelClusterCollection > > pixelLinkAcc("pixelClusterLink");
986  static const SG::AuxElement::Accessor< ElementLink< ::SpacePointCollection > > linkAcc("pixelSpacePointLink");
987 
988  if (m_useClusters) {
989  data.v_PixelSpacePointForSeed.clear();
990  }
991 
992  data.v_PixelSiSpacePointForSeed.clear();
993  data.v_PixelSiSpacePointForSeed.reserve(data.ns);
994  std::unordered_map<std::size_t, std::size_t> bridge_idx_sispacepoints;
995 
996  std::array<const Trk::SpacePoint*, 3> spacePoints {nullptr, nullptr, nullptr};
997  std::array<ITk::SiSpacePointForSeed*, 3> pixelSpacePointsForSeeds {nullptr, nullptr, nullptr};
998 
999  for (const ActsTrk::Seed* seed : seedPtrs) {
1000  std::array<std::size_t, 3> indexes {
1001  seed->sp()[0]->index(),
1002  seed->sp()[1]->index(),
1003  seed->sp()[2]->index()
1004  };
1005 
1006  const auto [bottom_idx, medium_idx, top_idx] = indexes;
1007  std::size_t max_index = std::max(bottom_idx, std::max(medium_idx, top_idx));
1008  if (data.v_PixelSpacePointForSeed.size() < max_index + 1) {
1009  data.v_PixelSpacePointForSeed.resize( max_index + 1 );
1010  }
1011 
1012  // Retrieve/make the space points!
1013  if (not m_useClusters) {
1014  // Get the Space Point from the element link
1015  if (not linkAcc.isAvailable(*seed->sp()[0])){
1016  ATH_MSG_FATAL("no pixelSpacePointLink for bottom sp!");
1017  return false;
1018  }
1019  if (not linkAcc.isAvailable(*seed->sp()[1])){
1020  ATH_MSG_FATAL("no pixelSpacePointLink for middle sp!");
1021  return false;
1022  }
1023  if (not linkAcc.isAvailable(*seed->sp()[2])){
1024  ATH_MSG_FATAL("no pixelSpacePointLink for top sp!");
1025  return false;
1026  }
1027 
1028  spacePoints = {
1029  *linkAcc(*seed->sp()[0]),
1030  *linkAcc(*seed->sp()[1]),
1031  *linkAcc(*seed->sp()[2])
1032  };
1033  }
1034  else {
1035  // Get the clusters from the xAOD::Clusters and then make the space points
1036  const xAOD::PixelCluster* bottom_cluster = reinterpret_cast<const xAOD::PixelCluster*>(seed->sp()[0]->measurements()[0]);
1037  const xAOD::PixelCluster* medium_cluster = reinterpret_cast<const xAOD::PixelCluster*>(seed->sp()[1]->measurements()[0]);
1038  const xAOD::PixelCluster* top_cluster = reinterpret_cast<const xAOD::PixelCluster*>(seed->sp()[2]->measurements()[0]);
1039 
1040  if (not pixelLinkAcc.isAvailable(*bottom_cluster)) {
1041  ATH_MSG_FATAL("no pixelClusterLink for cluster associated to bottom sp!");
1042  return false;
1043  }
1044  if (not pixelLinkAcc.isAvailable(*medium_cluster)) {
1045  ATH_MSG_FATAL("no pixelClusterLink for cluster associated to middle sp!");
1046  return false;
1047  }
1048  if (not pixelLinkAcc.isAvailable(*top_cluster)) {
1049  ATH_MSG_FATAL("no pixelClusterLink for cluster associated to top sp!");
1050  return false;
1051  }
1052 
1053  if (not data.v_PixelSpacePointForSeed[bottom_idx])
1054  data.v_PixelSpacePointForSeed[bottom_idx] = std::make_unique<InDet::PixelSpacePoint>(bottom_cluster->identifierHash(), *(pixelLinkAcc(*bottom_cluster)));
1055  if (not data.v_PixelSpacePointForSeed[medium_idx])
1056  data.v_PixelSpacePointForSeed[medium_idx] = std::make_unique<InDet::PixelSpacePoint>(medium_cluster->identifierHash(), *(pixelLinkAcc(*medium_cluster)));
1057  if (not data.v_PixelSpacePointForSeed[top_idx])
1058  data.v_PixelSpacePointForSeed[top_idx] = std::make_unique<InDet::PixelSpacePoint>(top_cluster->identifierHash(), *(pixelLinkAcc(*top_cluster)));
1059 
1060  spacePoints = {
1061  data.v_PixelSpacePointForSeed[bottom_idx].get(),
1062  data.v_PixelSpacePointForSeed[medium_idx].get(),
1063  data.v_PixelSpacePointForSeed[top_idx].get()
1064  };
1065 
1066  }
1067 
1068  for (int index = 0; index<3; ++index) {
1069  std::size_t sp_idx = indexes[index];
1070 
1071  // Try add an element.
1072  // If already there just return the old value
1073  // If not present, we add a new element to it
1074  auto [itr, outcome] = bridge_idx_sispacepoints.try_emplace(sp_idx, data.v_PixelSiSpacePointForSeed.size());
1075  std::size_t mapped_idx = itr->second;
1076  // We added a new element
1077  if (outcome) {
1078  float r[15];
1079  r[0] = seed->sp()[index]->x();
1080  r[1] = seed->sp()[index]->y();
1081  r[2] = seed->sp()[index]->z();
1082  pixInform(spacePoints[index], r);
1083  data.v_PixelSiSpacePointForSeed.emplace_back( spacePoints[index], r );
1084 
1085  }
1086  data.v_PixelSiSpacePointForSeed[mapped_idx].setQuality(-seed->seedQuality());
1087  pixelSpacePointsForSeeds[index] = &data.v_PixelSiSpacePointForSeed[mapped_idx];
1088  }
1089 
1090  data.i_ITkSeeds.emplace_back(pixelSpacePointsForSeeds[0],
1091  pixelSpacePointsForSeeds[1],
1092  pixelSpacePointsForSeeds[2],
1093  seed->z());
1094  data.i_ITkSeeds.back().setQuality(-seed->seedQuality());
1095  }
1096 
1097  return true;
1098  }

◆ convertStripSeed()

bool ActsTrk::SiSpacePointsSeedMaker::convertStripSeed ( const EventContext &  ctx,
InDet::SiSpacePointsSeedMakerEventData data,
const ActsTrk::SeedContainer seedPtrs 
) const
private

Definition at line 855 of file SiSpacePointsSeedMaker.cxx.

857  {
858  // If the read handle key for clusters is not empty, that means the xAOD->InDet Cluster link is available
859  // Else we can use xAOD->Trk Space Point link
860  // If none of these is available, we have a JO misconfguration!
861  static const SG::AuxElement::Accessor< ElementLink< ::SpacePointCollection > > linkAcc("sctSpacePointLink");
862  static const SG::AuxElement::Accessor< ElementLink< ::SpacePointOverlapCollection > > overlaplinkAcc("stripOverlapSpacePointLink");
863  static const SG::AuxElement::Accessor< ElementLink< InDet::SCT_ClusterCollection > > stripLinkAcc("sctClusterLink");
864 
865  if (m_useClusters) {
866  data.v_StripSpacePointForSeed.clear();
867  }
868 
869  std::array<const Trk::SpacePoint*, 3> spacePoints {};
870  std::array<ITk::SiSpacePointForSeed*, 3> stripSpacePointsForSeeds {};
871 
872  for (const ActsTrk::Seed* seed : seedPtrs) {
873  // Retrieve/make space points
874  if (not m_useClusters) {
875  // Get the space point from the element link
876  if (not linkAcc.isAvailable(*seed->sp()[0]) and
877  not overlaplinkAcc.isAvailable(*seed->sp()[0])) {
878  ATH_MSG_FATAL("no sctSpacePointLink/stripOverlapSpacePointLink for bottom sp!");
879  return false;
880  }
881  if (not linkAcc.isAvailable(*seed->sp()[1]) and
882  not overlaplinkAcc.isAvailable(*seed->sp()[1])) {
883  ATH_MSG_FATAL("no sctSpacePointLink/stripOverlapSpacePointLink for middle sp!");
884  return false;
885  }
886  if (not linkAcc.isAvailable(*seed->sp()[2]) and
887  not overlaplinkAcc.isAvailable(*seed->sp()[2])) {
888  ATH_MSG_FATAL("no sctSpacePointLink/stripOverlapSpacePointLink for top sp!");
889  return false;
890  }
891 
892  for (std::size_t nsp(0ul); nsp < 3ul; ++nsp) {
893  spacePoints[nsp] = linkAcc.isAvailable(*seed->sp()[nsp])
894  ? *linkAcc(*seed->sp()[nsp])
895  : *overlaplinkAcc(*seed->sp()[nsp]);
896  }
897  }
898  else {
899  // Get the clusters from the xAOD::Clusters and then make the space points
900  const auto& bottom_idx = seed->sp()[0]->measurements();
901  const auto& medium_idx = seed->sp()[1]->measurements();
902  const auto& top_idx = seed->sp()[2]->measurements();
903 
904  std::array<const xAOD::StripCluster*, 6> strip_cluster {
905  reinterpret_cast<const xAOD::StripCluster*>(bottom_idx[0]),
906  reinterpret_cast<const xAOD::StripCluster*>(bottom_idx[1]),
907  reinterpret_cast<const xAOD::StripCluster*>(medium_idx[0]),
908  reinterpret_cast<const xAOD::StripCluster*>(medium_idx[1]),
909  reinterpret_cast<const xAOD::StripCluster*>(top_idx[0]),
910  reinterpret_cast<const xAOD::StripCluster*>(top_idx[1])
911  };
912 
913  if (not stripLinkAcc.isAvailable(*strip_cluster[0]) or
914  not stripLinkAcc.isAvailable(*strip_cluster[1])){
915  ATH_MSG_FATAL("no sctClusterLink for clusters associated to bottom sp!");
916  return false;
917  }
918  if (not stripLinkAcc.isAvailable(*strip_cluster[2]) or
919  not stripLinkAcc.isAvailable(*strip_cluster[3])){
920  ATH_MSG_FATAL("no sctClusterLink for clusters associated to middle sp!");
921  return false;
922  }
923  if (not stripLinkAcc.isAvailable(*strip_cluster[4]) or
924  not stripLinkAcc.isAvailable(*strip_cluster[5])){
925  ATH_MSG_FATAL("no sctClusterLink for clusters associated to top sp!");
926  return false;
927  }
928 
929  std::pair<std::size_t, std::size_t> key_b = std::make_pair(strip_cluster[0]->index(), strip_cluster[1]->index());
930  std::pair<std::size_t, std::size_t> key_m = std::make_pair(strip_cluster[2]->index(), strip_cluster[3]->index());
931  std::pair<std::size_t, std::size_t> key_t = std::make_pair(strip_cluster[4]->index(), strip_cluster[5]->index());
932 
933  std::unique_ptr<InDet::SCT_SpacePoint>& ptr_b = data.v_StripSpacePointForSeed[key_b];
934  if (!ptr_b) {
935  ptr_b = std::make_unique<InDet::SCT_SpacePoint>(std::make_pair<IdentifierHash, IdentifierHash>(strip_cluster[0]->identifierHash(), strip_cluster[1]->identifierHash()),
936  Amg::Vector3D(seed->sp()[0]->x(), seed->sp()[0]->y(), seed->sp()[0]->z()),
937  std::make_pair<const Trk::PrepRawData*, const Trk::PrepRawData*>(*(stripLinkAcc(*strip_cluster[0])), *(stripLinkAcc(*strip_cluster[1]))));
938  }
939  std::unique_ptr<InDet::SCT_SpacePoint>& ptr_m = data.v_StripSpacePointForSeed[key_m];
940  if (!ptr_m) {
941  ptr_m = std::make_unique<InDet::SCT_SpacePoint>(std::make_pair<IdentifierHash, IdentifierHash>(strip_cluster[2]->identifierHash(), strip_cluster[3]->identifierHash()),
942  Amg::Vector3D(seed->sp()[1]->x(), seed->sp()[1]->y(), seed->sp()[1]->z()),
943  std::make_pair<const Trk::PrepRawData*, const Trk::PrepRawData*>(*(stripLinkAcc(*strip_cluster[2])), *(stripLinkAcc(*strip_cluster[3]))));
944  }
945  std::unique_ptr<InDet::SCT_SpacePoint>& ptr_t = data.v_StripSpacePointForSeed[key_t];
946  if (!ptr_t) {
947  ptr_t = std::make_unique<InDet::SCT_SpacePoint>(std::make_pair<IdentifierHash, IdentifierHash>(strip_cluster[4]->identifierHash(), strip_cluster[5]->identifierHash()),
948  Amg::Vector3D(seed->sp()[2]->x(), seed->sp()[2]->y(), seed->sp()[2]->z()),
949  std::make_pair<const Trk::PrepRawData*, const Trk::PrepRawData*>(*(stripLinkAcc(*strip_cluster[4])), *(stripLinkAcc(*strip_cluster[5]))));
950  }
951 
952  spacePoints = {
953  data.v_StripSpacePointForSeed[key_b].get(),
954  data.v_StripSpacePointForSeed[key_m].get(),
955  data.v_StripSpacePointForSeed[key_t].get()
956  };
957 
958  }
959 
960  for (unsigned int index = 0; index<3; index++) {
961  float r[15];
962  r[0] = seed->sp()[index]->x();
963  r[1] = seed->sp()[index]->y();
964  r[2] = seed->sp()[index]->z();
965  stripInform(data, spacePoints[index], r);
966  stripSpacePointsForSeeds[index] = new ITk::SiSpacePointForSeed(spacePoints[index], r);
967  stripSpacePointsForSeeds[index]->setQuality(-seed->seedQuality());
968  }
969 
970  data.i_ITkSeeds.emplace_back(stripSpacePointsForSeeds[0], stripSpacePointsForSeeds[1],
971  stripSpacePointsForSeeds[2], seed->z());
972  data.i_ITkSeeds.back().setQuality(-seed->seedQuality());
973  }
974 
975  return true;
976  }

◆ dump()

MsgStream & ActsTrk::SiSpacePointsSeedMaker::dump ( InDet::SiSpacePointsSeedMakerEventData data,
MsgStream &  out 
) const
overridevirtual

Definition at line 749 of file SiSpacePointsSeedMaker.cxx.

751  {
752  if (data.nprint)
753  return dumpEvent(data, out);
754  return dumpConditions(data, out);
755  }

◆ dumpConditions()

MsgStream & ActsTrk::SiSpacePointsSeedMaker::dumpConditions ( InDet::SiSpacePointsSeedMakerEventData data,
MsgStream &  out 
) const
private

Definition at line 762 of file SiSpacePointsSeedMaker.cxx.

763  {
764  std::string s2, s3, s4, s5;
765 
766  int n = 42-m_actsSpacepointsPixel.key().size();
767  s2.append(n,' ');
768  s2.append("|");
769  n = 42-m_actsSpacepointsStrip.key().size();
770  s3.append(n,' ');
771  s3.append("|");
772  n = 42-m_actsSpacepointsOverlap.key().size();
773  s4.append(n,' ');
774  s4.append("|");
775  n = 42-m_beamSpotKey.key().size();
776  s5.append(n,' ');
777  s5.append("|");
778 
779  out<<"|---------------------------------------------------------------------|"
780  <<endmsg;
781  out<<"| Pixel space points | "<<m_actsSpacepointsPixel.key() <<s2
782  <<endmsg;
783  out<<"| Strip space points | "<<m_actsSpacepointsStrip.key()<<s3
784  <<endmsg;
785  out<<"| Overlap space points | "<<m_actsSpacepointsOverlap.key()<<s4
786  <<endmsg;
787  out<<"| BeamConditionsService | "<<m_beamSpotKey.key()<<s5
788  <<endmsg;
789  out<<"| usePixel | "
790  <<std::setw(12)<<m_pixel
791  <<" |"<<endmsg;
792  out<<"| useStrip | "
793  <<std::setw(12)<<m_strip
794  <<" |"<<endmsg;
795  out<<"| useStripOverlap | "
796  <<std::setw(12)<<m_useOverlap
797  <<" |"<<endmsg;
798  out<<"|---------------------------------------------------------------------|"
799  <<endmsg;
800  out<<"| Beam X center | "
801  <<std::setw(12)<<std::setprecision(5)<<data.xbeam[0]
802  <<" |"<<endmsg;
803  out<<"| Beam Y center | "
804  <<std::setw(12)<<std::setprecision(5)<<data.ybeam[0]
805  <<" |"<<endmsg;
806  out<<"| Beam Z center | "
807  <<std::setw(12)<<std::setprecision(5)<<data.zbeam[0]
808  <<" |"<<endmsg;
809  out<<"| Beam X-axis direction | "
810  <<std::setw(12)<<std::setprecision(5)<<data.xbeam[1]
811  <<std::setw(12)<<std::setprecision(5)<<data.xbeam[2]
812  <<std::setw(12)<<std::setprecision(5)<<data.xbeam[3]
813  <<" |"<<endmsg;
814  out<<"| Beam Y-axis direction | "
815  <<std::setw(12)<<std::setprecision(5)<<data.ybeam[1]
816  <<std::setw(12)<<std::setprecision(5)<<data.ybeam[2]
817  <<std::setw(12)<<std::setprecision(5)<<data.ybeam[3]
818  <<" |"<<endmsg;
819  out<<"| Beam Z-axis direction | "
820  <<std::setw(12)<<std::setprecision(5)<<data.zbeam[1]
821  <<std::setw(12)<<std::setprecision(5)<<data.zbeam[2]
822  <<std::setw(12)<<std::setprecision(5)<<data.zbeam[3]
823  <<" |"<<endmsg;
824  out<<"|---------------------------------------------------------------------|"
825  <<endmsg;
826  return out;
827 
828  }

◆ dumpEvent()

MsgStream & ActsTrk::SiSpacePointsSeedMaker::dumpEvent ( InDet::SiSpacePointsSeedMakerEventData data,
MsgStream &  out 
)
staticprivate

Definition at line 834 of file SiSpacePointsSeedMaker.cxx.

836  {
837  out<<"|---------------------------------------------------------------------|"
838  <<endmsg;
839  out<<"| ns | "
840  <<std::setw(12)<<data.ns
841  <<" |"<<endmsg;
842  out<<"| nsaz | "
843  <<std::setw(12)<<data.nsaz
844  <<" |"<<endmsg;
845  out<<"| seeds | "
846  <<std::setw(12)<< data.nsazv
847  <<" |"<<endmsg;
848  out<<"|---------------------------------------------------------------------|"
849  <<endmsg;
850  return out;
851 
852  }

◆ find2Sp()

virtual void ActsTrk::SiSpacePointsSeedMaker::find2Sp ( InDet::SiSpacePointsSeedMakerEventData ,
const std::list< Trk::Vertex > &   
) const
inlineoverridevirtual

Definition at line 104 of file SiSpacePointsSeedMaker.h.

106  {
107  ATH_MSG_ERROR("Method `findfind2Sp` is not implemented.");
108  }

◆ find3Sp() [1/2]

virtual void ActsTrk::SiSpacePointsSeedMaker::find3Sp ( const EventContext &  ,
InDet::SiSpacePointsSeedMakerEventData ,
const std::list< Trk::Vertex > &  ,
const double *   
) const
inlineoverridevirtual

with three space points with or without vertex constraint with information about min and max Z of the vertex

Definition at line 113 of file SiSpacePointsSeedMaker.h.

117  {
118  ATH_MSG_ERROR("Method `find3Sp` is not implemented.");
119  }

◆ find3Sp() [2/2]

void ActsTrk::SiSpacePointsSeedMaker::find3Sp ( const EventContext &  ctx,
InDet::SiSpacePointsSeedMakerEventData data,
const std::list< Trk::Vertex > &  lv 
) const
overridevirtual

Definition at line 608 of file SiSpacePointsSeedMaker.cxx.

611  {
612  // Fast return if no sps are collected
613  if ( data.v_ActsSpacePointForSeed.empty() )
614  return;
615 
616  // select the ACTS seeding tool to call, if for PPP or SSS
617  bool isPixel = (m_fastTracking or data.iteration == 1) and m_pixel;
618 
619  // this is use for a fast retrieval of the space points later
620  std::vector<ITk::SiSpacePointForSeed*> sp_storage;
621 
622  // We can now run the Acts Seeding
623  std::unique_ptr< ActsTrk::SeedContainer > seedPtrs = std::make_unique< ActsTrk::SeedContainer >();
624  //cppcheck-suppress unreadVariable
625  std::string combinationType = isPixel ? "PPP" : "SSS";
626  ATH_MSG_DEBUG("Running Seed Finding (" << combinationType << ") ...");
627 
628  // Beam Spot Position
629  Acts::Vector3 beamPos( data.xbeam[0] * Acts::UnitConstants::mm,
630  data.ybeam[0] * Acts::UnitConstants::mm,
631  data.zbeam[0] * Acts::UnitConstants::mm);
632 
633  Acts::Vector3 bField( data.bField[0], data.bField[1], data.bField[2] );
634 
635  StatusCode sc;
636 
637  if (isPixel)
638  sc = m_seedsToolPixel->createSeeds( ctx,
639  data.v_ActsSpacePointForSeed,
640  beamPos,
641  bField,
642  *seedPtrs.get() );
643  else {
644  sc = m_seedsToolStrip->createSeeds( ctx,
645  data.v_ActsSpacePointForSeed,
646  beamPos,
647  bField,
648  *seedPtrs.get() );
649  }
650 
651  if (sc == StatusCode::FAILURE) {
652  ATH_MSG_ERROR("Error during seed production (" << combinationType << ")");
653  return;
654  }
655 
656  ATH_MSG_DEBUG(" \\__ Created " << seedPtrs->size() << " seeds");
657  data.nsazv = seedPtrs->size();
658 
659  // Store seeds to data
660  // We need now to convert the output to Athena object once again (i.e. ITk::SiSpacePointForSeed)
661  // The seeds will be stored in data.i_ITkSeeds (both PPP and SSS seeds)
662  if (m_doSeedConversion) {
663 
664  if (isPixel) {
665  if (not convertPixelSeed(ctx, data, *seedPtrs.get())) {
666  ATH_MSG_FATAL("Error in pixel seed conversion");
667  return;
668  }
669  } else {
670  if (not convertStripSeed(ctx, data, *seedPtrs.get())) {
671  ATH_MSG_FATAL("Error in strip seed conversion");
672  return;
673  }
674  }
675  }
676 
677  data.i_ITkSeed = data.i_ITkSeeds.begin();
678  data.nprint = 1;
679  dump(data, msg(MSG::DEBUG));
680  }

◆ findVSp()

virtual void ActsTrk::SiSpacePointsSeedMaker::findVSp ( const EventContext &  ,
InDet::SiSpacePointsSeedMakerEventData ,
const std::list< Trk::Vertex > &   
) const
inlineoverridevirtual

with variable number space points with or without vertex constraint Variable means (2,3,4,....) any number space points

Definition at line 124 of file SiSpacePointsSeedMaker.h.

127  {
128  ATH_MSG_ERROR("Method `findVSp` is not implemented.");
129  }

◆ getWriteNtupleBoolProperty()

bool ActsTrk::SiSpacePointsSeedMaker::getWriteNtupleBoolProperty ( ) const
overridevirtual

Definition at line 745 of file SiSpacePointsSeedMaker.cxx.

746  { return m_writeNtuple; }

◆ initialize()

StatusCode ActsTrk::SiSpacePointsSeedMaker::initialize ( )
overridevirtual

Definition at line 40 of file SiSpacePointsSeedMaker.cxx.

41  {
42  ATH_MSG_DEBUG( "Initializing " << name() << "..." );
43 
44  ATH_MSG_DEBUG( "Properties Summary:" );
45  ATH_MSG_DEBUG( " " << m_pixel );
46  ATH_MSG_DEBUG( " " << m_strip );
47  ATH_MSG_DEBUG( " " << m_useOverlap );
48  ATH_MSG_DEBUG( " " << m_writeNtuple );
49  ATH_MSG_DEBUG( " " << m_fastTracking );
50 
51  if (not m_pixel and not m_strip) {
52  ATH_MSG_ERROR("Activate seeding on at least one between Pixel and Strip space point collections!");
53  return StatusCode::FAILURE;
54  }
55 
59 
60  ATH_CHECK( m_seedsToolPixel.retrieve(EnableTool{m_pixel}) );
61  ATH_CHECK( m_seedsToolStrip.retrieve(EnableTool{m_strip}) );
62 
64 
67 
70 
71  // Validation
72  if (m_writeNtuple)
73  ATH_CHECK( InitTree() );
74 
75  return StatusCode::SUCCESS;
76  }

◆ InitTree()

StatusCode ActsTrk::SiSpacePointsSeedMaker::InitTree ( )
private

Definition at line 81 of file SiSpacePointsSeedMaker.cxx.

82  {
83  ATH_CHECK( service("THistSvc", m_thistSvc) );
84  std::string tree_name = std::string("SeedTree_") + name();
85  std::replace( tree_name.begin(), tree_name.end(), '.', '_' );
86 
87  m_outputTree = new TTree( tree_name.c_str() , "ActsSeedMakerValTool");
88 
89  m_outputTree->Branch("eventNumber", &m_eventNumber,"eventNumber/L");
90  m_outputTree->Branch("d0", &m_d0);
91  m_outputTree->Branch("z0", &m_z0);
92  m_outputTree->Branch("pt", &m_pt);
93  m_outputTree->Branch("eta", &m_eta);
94  m_outputTree->Branch("x1", &m_x1);
95  m_outputTree->Branch("x2", &m_x2);
96  m_outputTree->Branch("x3", &m_x3);
97  m_outputTree->Branch("y1", &m_y1);
98  m_outputTree->Branch("y2", &m_y2);
99  m_outputTree->Branch("y3", &m_y3);
100  m_outputTree->Branch("z1", &m_z1);
101  m_outputTree->Branch("z2", &m_z2);
102  m_outputTree->Branch("z3", &m_z3);
103  m_outputTree->Branch("r1", &m_r1);
104  m_outputTree->Branch("r2", &m_r2);
105  m_outputTree->Branch("r3", &m_r3);
106  m_outputTree->Branch("quality", &m_quality);
107  m_outputTree->Branch("seedType", &m_type);
108  m_outputTree->Branch("givesTrack", &m_givesTrack);
109  m_outputTree->Branch("dzdr_b", &m_dzdr_b);
110  m_outputTree->Branch("dzdr_t", &m_dzdr_t);
111  m_outputTree->Branch("track_pt", &m_trackPt);
112  m_outputTree->Branch("track_eta", &m_trackEta);
113 
114  std::string full_tree_name = "/" + m_treeFolder + "/" + tree_name;
115  ATH_CHECK( m_thistSvc->regTree( full_tree_name.c_str(), m_outputTree ) );
116 
117  return StatusCode::SUCCESS;
118  }

◆ isUsed() [1/2]

bool ActsTrk::SiSpacePointsSeedMaker::isUsed ( const Trk::SpacePoint sp,
const Trk::PRDtoTrackMap prd_to_track_map 
) const
inlineprivate

Definition at line 266 of file SiSpacePointsSeedMaker.h.

268  {
269  const Trk::PrepRawData* d = sp->clusterList().first;
270  if (!d || !prd_to_track_map.isUsed(*d)) return false;
271 
272  d = sp->clusterList().second;
273  if (!d || prd_to_track_map.isUsed(*d)) return true;
274 
275  return false;
276  }

◆ isUsed() [2/2]

bool ActsTrk::SiSpacePointsSeedMaker::isUsed ( const xAOD::SpacePoint sp,
const Trk::PRDtoTrackMap prd_to_track_map 
) const
inlineprivate

Definition at line 279 of file SiSpacePointsSeedMaker.h.

280  {
281  static const SG::AuxElement::ConstAccessor< ElementLink< ::SpacePointCollection > > pixelLinkAcc("pixelSpacePointLink");
282  static const SG::AuxElement::ConstAccessor< ElementLink< ::SpacePointCollection > > stripLinkAcc("sctSpacePointLink");
283  static const SG::AuxElement::ConstAccessor< ElementLink< ::SpacePointOverlapCollection > > stripOverlapLinkacc("stripOverlapSpacePointLink");
284 
285  const Trk::SpacePoint *indetSp = nullptr;
286  if ( pixelLinkAcc.isAvailable(*sp) ) {
287  const ElementLink< ::SpacePointCollection > link = pixelLinkAcc( *sp );
288  indetSp = *link;
289  }
290  else if ( stripLinkAcc.isAvailable(*sp) ) {
291  const ElementLink< ::SpacePointCollection > link = stripLinkAcc( *sp );
292  indetSp = *link;
293  } else if ( stripOverlapLinkacc.isAvailable(*sp) ) {
294  const ElementLink< ::SpacePointOverlapCollection > link = stripOverlapLinkacc( *sp );
295  indetSp = *link;
296  } else {
297  return false;
298  }
299 
300  return isUsed(indetSp, prd_to_track_map);
301  }

◆ newEvent()

void ActsTrk::SiSpacePointsSeedMaker::newEvent ( const EventContext &  ctx,
InDet::SiSpacePointsSeedMakerEventData data,
int  iteration = -1 
) const
overridevirtual

Definition at line 536 of file SiSpacePointsSeedMaker.cxx.

539  {
540  // Store iteration into data for use in other methods
541  data.iteration = iteration;
542  if (iteration < 0)
543  data.iteration = 0;
544 
545  // At the beginning of each iteration
546  // clearing list of space points to be used for seeding
548  data.i_ITkSpacePointForSeed = data.l_ITkSpacePointForSeed.begin();
549  data.v_ActsSpacePointForSeed.clear();
550 
551 
552  // clearing list of produced seeds
554  data.i_ITkSeed = data.i_ITkSeeds.begin();
555 
556  // First iteration:
557  // -- event-specific configuration, i.e. beamspot and magnetic field
558  // -- for default case: producing SSS
559  // -- for fast tracking: producing PPP
560  // Second iteration:
561  // -- for default case: producing PPP
562  // -- no additional iteration is foreseen for fast tracking case
563 
564  bool isPixel = (m_fastTracking or data.iteration == 1) and m_pixel;
565  bool isStrip = not m_fastTracking and data.iteration == 0 and m_strip;
566 
567  // The Acts Seed tool requires beamspot information for the space points already here
568  if (data.iteration == 0)
569  buildBeamFrameWork(ctx, data);
570 
571  // initialising the number of space points as well
572  data.ns = 0;
573  data.nsaz = 0;
574  data.nsazv = 0;
575 
576  // Retrieve the Trk::PRDtoTrackMap
577  const Trk::PRDtoTrackMap *prd_to_track_map_cptr = nullptr;
578  if ( not m_prdToTrackMap.empty() ) {
580  if ( not prd_handle.isValid() ) {
581  ATH_MSG_ERROR("Failed to read PRD to track association map: " << m_prdToTrackMap.key());
582  }
583  prd_to_track_map_cptr = prd_handle.get();
584  }
585 
586  // Only retrieving the collections needed for the seed formation,
587  // depending on the tool configuration and iteration
588 
589  // Retrieve Pixels
590  if (isPixel and not retrievePixel(ctx, data, prd_to_track_map_cptr).isSuccess() ) {
591  ATH_MSG_ERROR("Error while retrieving Pixel space points with key " << m_actsSpacepointsPixel.key());
592  }
593 
594  // Retrieve Strips
595  if (isStrip and not retrieveStrip(ctx, data, prd_to_track_map_cptr).isSuccess() ) {
596  ATH_MSG_ERROR("Error while retrieving Strip space points with key " << m_actsSpacepointsStrip.key());
597  }
598 
599  // Retrieve Overlaps, will go into Strip collection
600  if ((isStrip and m_useOverlap) and not retrieveOverlap(ctx, data, prd_to_track_map_cptr).isSuccess() ) {
601  ATH_MSG_ERROR("Error while retrieving Strip Overlap space points with key " << m_actsSpacepointsOverlap.key());
602  }
603 
604  data.initialized = true;
605  }

◆ newRegion() [1/2]

void ActsTrk::SiSpacePointsSeedMaker::newRegion ( const EventContext &  ctx,
InDet::SiSpacePointsSeedMakerEventData data,
const std::vector< IdentifierHash > &  vPixel,
const std::vector< IdentifierHash > &  vStrip 
) const
overridevirtual

Definition at line 484 of file SiSpacePointsSeedMaker.cxx.

488  {
489  ATH_MSG_DEBUG("Calling " << name() << "::newRegion");
490  if (!m_pixel && !m_strip)
491  return;
492 
494  data.i_ITkSpacePointForSeed = data.l_ITkSpacePointForSeed.begin();
495  data.v_ActsSpacePointForSeed.clear();
496 
498  data.i_ITkSeed = data.i_ITkSeeds.begin();
499 
500  buildBeamFrameWork(ctx, data);
501 
502  data.ns = 0;
503  data.nsaz = 0;
504  data.nsazv = 0;
505 
506  const Trk::PRDtoTrackMap *prd_to_track_map_cptr = nullptr;
507  if ( not m_prdToTrackMap.empty() ) {
509  if ( not prd_handle.isValid() ) {
510  ATH_MSG_ERROR("Failed to read PRD to track association map: " << m_prdToTrackMap.key());
511  }
512  prd_to_track_map_cptr = prd_handle.get();
513  }
514  if (prd_to_track_map_cptr != nullptr) {
515  ATH_MSG_DEBUG("Retrieved prd map with name " << m_prdToTrackMap.key());
516  }
517 
518  if ( not retrievePixel(ctx, data, vPixel, prd_to_track_map_cptr).isSuccess() ) {
519  ATH_MSG_ERROR("Error while retrieving Pixel space points with key " << m_actsSpacepointsPixel.key());
520  }
521 
522  if ( not retrieveStrip(ctx, data, vStrip, prd_to_track_map_cptr).isSuccess() ) {
523  ATH_MSG_ERROR("Error while retrieving Strip space points with key " << m_actsSpacepointsStrip.key());
524  }
525 
526  if ( m_useOverlap and not retrieveOverlap(ctx, data, prd_to_track_map_cptr).isSuccess() ) {
527  ATH_MSG_ERROR("Error while retrieving Strip Overlap space points with key " << m_actsSpacepointsOverlap.key());
528  }
529 
530  data.initialized = true;
531  }

◆ newRegion() [2/2]

virtual void ActsTrk::SiSpacePointsSeedMaker::newRegion ( const EventContext &  ,
InDet::SiSpacePointsSeedMakerEventData ,
const std::vector< IdentifierHash > &  ,
const std::vector< IdentifierHash > &  ,
const IRoiDescriptor  
) const
inlineoverridevirtual

Definition at line 94 of file SiSpacePointsSeedMaker.h.

99  {
100  ATH_MSG_ERROR("Method `newRegion` is not implemented.");
101  }

◆ newSpacePoint()

void ActsTrk::SiSpacePointsSeedMaker::newSpacePoint ( InDet::SiSpacePointsSeedMakerEventData data,
const xAOD::SpacePoint *const sp 
) const
private

Definition at line 121 of file SiSpacePointsSeedMaker.cxx.

123  {
124  if (m_fastTracking and skipSpacePoint(sp->x()-data.xbeam[0], sp->y()-data.ybeam[0], sp->z()-data.zbeam[0]))
125  return;
126 
127  data.v_ActsSpacePointForSeed.emplace_back(sp);
128  data.ns++;
129  data.nsaz++;
130  }

◆ next()

const InDet::SiSpacePointsSeed * ActsTrk::SiSpacePointsSeedMaker::next ( const EventContext &  ctx,
InDet::SiSpacePointsSeedMakerEventData data 
) const
overridevirtual

then return this next seed candidate

Definition at line 683 of file SiSpacePointsSeedMaker.cxx.

685  {
686 
687  do {
688  if (data.i_ITkSeed == data.i_ITkSeeds.end())
689  return nullptr;
690 
691  // iterate until we find a valid seed satisfying certain quality cuts in set3
692  } while (!(*data.i_ITkSeed++).set3(data.seedOutput, 1./(1000. * data.K)));
693 
695  return &data.seedOutput;
696 
697  }

◆ pixInform()

void ActsTrk::SiSpacePointsSeedMaker::pixInform ( const Trk::SpacePoint *const sp,
float *  r 
)
staticprivate

Definition at line 145 of file SiSpacePointsSeedMaker.cxx.

147  {
148  const InDet::SiCluster *cl = static_cast<const InDet::SiCluster *>(sp->clusterList().first);
149  const InDetDD::SiDetectorElement *de = cl->detectorElement();
150  const Amg::Transform3D &Tp = de->surface().transform();
151  r[3] = static_cast<float>(Tp(0, 2));
152  r[4] = static_cast<float>(Tp(1, 2));
153  r[5] = static_cast<float>(Tp(2, 2));
154  }

◆ retrieveOverlap() [1/2]

StatusCode ActsTrk::SiSpacePointsSeedMaker::retrieveOverlap ( const EventContext &  ctx,
InDet::SiSpacePointsSeedMakerEventData data,
const std::vector< IdentifierHash > &  ids,
const Trk::PRDtoTrackMap prd_to_track_map_cptr 
) const
private

Definition at line 367 of file SiSpacePointsSeedMaker.cxx.

371  {
372  if (ids.empty()) return StatusCode::SUCCESS;
373 
374  ATH_MSG_DEBUG("Retrieving strip overlap space point collection " << m_actsSpacepointsOverlap.key());
376  if (not inputSpacePointContainer.isValid()){
377  ATH_MSG_FATAL("xAOD::SpacePointContainer with key " << m_actsSpacepointsOverlap.key() << " is not available...");
378  return StatusCode::FAILURE;
379  }
380  const xAOD::SpacePointContainer *inputCollection = inputSpacePointContainer.cptr();
381 
382  ATH_MSG_DEBUG("Retrieving SiDetectorElementCollection with key `" << m_stripDetEleCollKey.key() << "`");
384  ATH_CHECK(detEleHandle.isValid());
385  const InDetDD::SiDetectorElementCollection* detElements = detEleHandle.cptr();
386 
389  [] (const xAOD::SpacePoint& coll) -> IdentifierHash
390  { return coll.elementIdList()[0]; },
391  detElements->size());
392 
393  for (const IdentifierHash id : ids) {
394  if (not accessor.isIdentifierPresent(id)) {
395  continue;
396  }
397 
398  const auto& ranges = accessor.rangesForIdentifierDirect(id);
399  for (auto [firstElement, lastElement] : ranges) {
400  for (; firstElement != lastElement; ++firstElement) {
401  const xAOD::SpacePoint *sp = *firstElement;
402  if (prd_to_track_map_cptr != nullptr and isUsed(sp, *prd_to_track_map_cptr)) continue;
403  newSpacePoint(data, sp);
404  }
405  }
406  }
407 
408  return StatusCode::SUCCESS;
409  }

◆ retrieveOverlap() [2/2]

StatusCode ActsTrk::SiSpacePointsSeedMaker::retrieveOverlap ( const EventContext &  ctx,
InDet::SiSpacePointsSeedMakerEventData data,
const Trk::PRDtoTrackMap prd_to_track_map_cptr 
) const
private

Definition at line 343 of file SiSpacePointsSeedMaker.cxx.

346  {
347  // get the xAOD::SpacePointContainer and loop on entries to check which space point
348  // you want to use for seeding
349  ATH_MSG_DEBUG("Retrieving strip overlap space point collection " << m_actsSpacepointsOverlap.key());
351  if (!inputSpacePointContainer.isValid()){
352  ATH_MSG_FATAL("xAOD::SpacePointContainer with key " << m_actsSpacepointsOverlap.key() << " is not available...");
353  return StatusCode::FAILURE;
354  }
355  const xAOD::SpacePointContainer* inputSpacePointCollection = inputSpacePointContainer.cptr();
356  // TODO: here you need to write some lines to implement the
357  // check on the used PDRs in previous tracking passes
358  for (const xAOD::SpacePoint * sp : *inputSpacePointCollection) {
359  if (prd_to_track_map_cptr != nullptr and isUsed(sp, *prd_to_track_map_cptr)) continue;
360  newSpacePoint(data, sp);
361  }
362 
363  return StatusCode::SUCCESS;
364  }

◆ retrievePixel() [1/2]

StatusCode ActsTrk::SiSpacePointsSeedMaker::retrievePixel ( const EventContext &  ctx,
InDet::SiSpacePointsSeedMakerEventData data,
const std::vector< IdentifierHash > &  ids,
const Trk::PRDtoTrackMap prd_to_track_map_cptr = nullptr 
) const
private

Definition at line 227 of file SiSpacePointsSeedMaker.cxx.

231  {
232  if (ids.empty()) return StatusCode::SUCCESS;
233 
234  ATH_MSG_DEBUG("Retrieving pixel space point collection " << m_actsSpacepointsPixel.key());
236  if (not inputSpacePointContainer.isValid()){
237  ATH_MSG_FATAL("xAOD::SpacePointContainer with key " << m_actsSpacepointsPixel.key() << " is not available...");
238  return StatusCode::FAILURE;
239  }
240  const xAOD::SpacePointContainer *inputCollection = inputSpacePointContainer.cptr();
241 
242  ATH_MSG_DEBUG("Retrieving SiDetectorElementCollection with key `" << m_pixelDetEleCollKey.key() << "`");
244  ATH_CHECK(detEleHandle.isValid());
245  const InDetDD::SiDetectorElementCollection* detElements = detEleHandle.cptr();
246 
249  [] (const xAOD::SpacePoint& coll) -> IdentifierHash
250  { return coll.elementIdList()[0]; },
251  detElements->size());
252 
253  for (const IdentifierHash id : ids) {
254  if (not accessor.isIdentifierPresent(id)) {
255  continue;
256  }
257 
258  const auto& ranges = accessor.rangesForIdentifierDirect(id);
259  for (auto [firstElement, lastElement] : ranges) {
260  for (; firstElement != lastElement; ++firstElement) {
261  const xAOD::SpacePoint *sp = *firstElement;
262  if (prd_to_track_map_cptr != nullptr and isUsed(sp, *prd_to_track_map_cptr)) continue;
263  newSpacePoint(data, sp);
264  }
265  }
266  }
267 
268  return StatusCode::SUCCESS;
269  }

◆ retrievePixel() [2/2]

StatusCode ActsTrk::SiSpacePointsSeedMaker::retrievePixel ( const EventContext &  ctx,
InDet::SiSpacePointsSeedMakerEventData data,
const Trk::PRDtoTrackMap prd_to_track_map_cptr 
) const
private

Definition at line 203 of file SiSpacePointsSeedMaker.cxx.

206  {
207  // get the xAOD::SpacePointContainer and loop on entries to check which space point
208  // you want to use for seeding
209  ATH_MSG_DEBUG("Retrieving pixel space point collection " << m_actsSpacepointsPixel.key());
211  if (not inputSpacePointContainer.isValid()){
212  ATH_MSG_FATAL("xAOD::SpacePointContainer with key " << m_actsSpacepointsPixel.key() << " is not available...");
213  return StatusCode::FAILURE;
214  }
215  const xAOD::SpacePointContainer* inputSpacePointCollection = inputSpacePointContainer.cptr();
216  // TODO: here you need to write some lines to implement the
217  // check on the used PDRs in previous tracking passes
218  for (const xAOD::SpacePoint * sp : *inputSpacePointCollection) {
219  if (prd_to_track_map_cptr != nullptr and isUsed(sp, *prd_to_track_map_cptr)) continue;
220  newSpacePoint(data, sp);
221  }
222 
223  return StatusCode::SUCCESS;
224  }

◆ retrieveStrip() [1/2]

StatusCode ActsTrk::SiSpacePointsSeedMaker::retrieveStrip ( const EventContext &  ctx,
InDet::SiSpacePointsSeedMakerEventData data,
const std::vector< IdentifierHash > &  ids,
const Trk::PRDtoTrackMap prd_to_track_map_cptr = nullptr 
) const
private

Definition at line 296 of file SiSpacePointsSeedMaker.cxx.

301  {
302  if (ids.empty()) return StatusCode::SUCCESS;
303 
304  ATH_MSG_DEBUG("Retrieving strip space point collection " << m_actsSpacepointsStrip.key());
306  if (not inputSpacePointContainer.isValid()){
307  ATH_MSG_FATAL("xAOD::SpacePointContainer with key " << m_actsSpacepointsStrip.key() << " is not available...");
308  return StatusCode::FAILURE;
309  }
310  const xAOD::SpacePointContainer *inputCollection = inputSpacePointContainer.cptr();
311 
312  ATH_MSG_DEBUG("Retrieving SiDetectorElementCollection with key `" << m_stripDetEleCollKey.key() << "`");
314  ATH_CHECK(detEleHandle.isValid());
315  const InDetDD::SiDetectorElementCollection* detElements = detEleHandle.cptr();
316 
319  [] (const xAOD::SpacePoint& coll) -> IdentifierHash
320  { return coll.elementIdList()[0]; },
321  detElements->size());
322 
323  for (const IdentifierHash id : ids) {
324  if (not accessor.isIdentifierPresent(id)) {
325  continue;
326  }
327 
328  const auto& ranges = accessor.rangesForIdentifierDirect(id);
329  for (auto [firstElement, lastElement] : ranges) {
330  for (; firstElement != lastElement; ++firstElement) {
331  const xAOD::SpacePoint *sp = *firstElement;
332  if (prd_to_track_map_cptr != nullptr and isUsed(sp, *prd_to_track_map_cptr)) continue;
333  newSpacePoint(data, sp);
334  }
335  }
336  }
337 
338  return StatusCode::SUCCESS;
339  }

◆ retrieveStrip() [2/2]

StatusCode ActsTrk::SiSpacePointsSeedMaker::retrieveStrip ( const EventContext &  ctx,
InDet::SiSpacePointsSeedMakerEventData data,
const Trk::PRDtoTrackMap prd_to_track_map_cptr 
) const
private

Definition at line 272 of file SiSpacePointsSeedMaker.cxx.

275  {
276  // get the xAOD::SpacePointContainer and loop on entries to check which space point
277  // you want to use for seeding
278  ATH_MSG_DEBUG("Retrieving strip space point collection " << m_actsSpacepointsStrip.key());
280  if (!inputSpacePointContainer.isValid()){
281  ATH_MSG_FATAL("xAOD::SpacePointContainer with key " << m_actsSpacepointsStrip.key() << " is not available...");
282  return StatusCode::FAILURE;
283  }
284  const xAOD::SpacePointContainer* inputSpacePointCollection = inputSpacePointContainer.cptr();
285  // TODO: here you need to write some lines to implement the
286  // check on the used PDRs in previous tracking passes
287  for (const xAOD::SpacePoint * sp : *inputSpacePointCollection) {
288  if (prd_to_track_map_cptr != nullptr and isUsed(sp, *prd_to_track_map_cptr)) continue;
289  newSpacePoint(data, sp);
290  }
291 
292  return StatusCode::SUCCESS;
293  }

◆ skipSpacePoint()

bool ActsTrk::SiSpacePointsSeedMaker::skipSpacePoint ( float  x,
float  y,
float  z 
) const
private

Definition at line 132 of file SiSpacePointsSeedMaker.cxx.

132  {
133  float R = std::hypotf(x,y);
134  // At small R, we remove space points beyond |z|=200
135  if (std::abs(z) > 200. && R < 50.)
136  return true;
137  // We also remove space points beyond eta=4. if their z is larger
138  // than the max seed z0 (150.)
139  float cotTheta = 27.2899; // (4.0 eta) --> 27.2899 = 1/tan(2*arctan(exp(-4)))
140  if (std::abs(z) - 150. > cotTheta * R)
141  return true;
142  return false;
143  }

◆ stripInform()

void ActsTrk::SiSpacePointsSeedMaker::stripInform ( InDet::SiSpacePointsSeedMakerEventData data,
const Trk::SpacePoint *const sp,
float *  r 
)
staticprivate

Definition at line 157 of file SiSpacePointsSeedMaker.cxx.

160  {
161  const InDet::SiCluster *c0 = static_cast<const InDet::SiCluster *>(sp->clusterList().first);
162  const InDet::SiCluster *c1 = static_cast<const InDet::SiCluster *>(sp->clusterList().second);
163  const InDetDD::SiDetectorElement *d0 = c0->detectorElement();
164  const InDetDD::SiDetectorElement *d1 = c1->detectorElement();
165 
166  Amg::Vector2D lc0 = c0->localPosition();
167  Amg::Vector2D lc1 = c1->localPosition();
168 
169  std::pair<Amg::Vector3D, Amg::Vector3D> e0 =
170  (d0->endsOfStrip(InDetDD::SiLocalPosition(lc0.y(), lc0.x(), 0.)));
171  std::pair<Amg::Vector3D, Amg::Vector3D> e1 =
172  (d1->endsOfStrip(InDetDD::SiLocalPosition(lc1.y(), lc1.x(), 0.)));
173 
174  Amg::Vector3D s0(.5 * (e0.first + e0.second));
175  Amg::Vector3D s1(.5 * (e1.first + e1.second));
176 
177  Amg::Vector3D b0(.5 * (e0.second - e0.first));
178  Amg::Vector3D b1(.5 * (e1.second - e1.first));
179  Amg::Vector3D d02(s0 - s1);
180 
181  // b0
182  r[3] = static_cast<float>(b0[0]);
183  r[4] = static_cast<float>(b0[1]);
184  r[5] = static_cast<float>(b0[2]);
185 
186  // b1
187  r[6] = static_cast<float>(b1[0]);
188  r[7] = static_cast<float>(b1[1]);
189  r[8] = static_cast<float>(b1[2]);
190 
191  // r0-r2
192  r[9] = static_cast<float>(d02[0]);
193  r[10] = static_cast<float>(d02[1]);
194  r[11] = static_cast<float>(d02[2]);
195 
196  // r0
197  r[12] = static_cast<float>(s0[0]) - data.xbeam[0];
198  r[13] = static_cast<float>(s0[1]) - data.ybeam[0];
199  r[14] = static_cast<float>(s0[2]) - data.zbeam[0];
200  }

◆ writeNtuple()

void ActsTrk::SiSpacePointsSeedMaker::writeNtuple ( const InDet::SiSpacePointsSeed seed,
const Trk::Track track,
int  seedType,
long  eventNumber 
) const
overridevirtual

Definition at line 700 of file SiSpacePointsSeedMaker.cxx.

704  {
705  if (not m_writeNtuple) return;
706 
707  std::lock_guard<std::mutex> lock(m_mutex);
708 
709  if(track != nullptr) {
710  m_trackPt = (track->trackParameters()->front()->pT())/1000.f;
711  m_trackEta = std::abs(track->trackParameters()->front()->eta());
712  }
713  else {
714  m_trackPt = -1.;
715  m_trackEta = -1.;
716  }
717  m_d0 = seed->d0();
718  m_z0 = seed->zVertex();
719  m_eta = seed->eta();
720  m_x1 = seed->x1();
721  m_x2 = seed->x2();
722  m_x3 = seed->x3();
723  m_y1 = seed->y1();
724  m_y2 = seed->y2();
725  m_y3 = seed->y3();
726  m_z1 = seed->z1();
727  m_z2 = seed->z2();
728  m_z3 = seed->z3();
729  m_r1 = seed->r1();
730  m_r2 = seed->r2();
731  m_r3 = seed->r3();
732  m_type = seedType;
733  m_dzdr_b = seed->dzdr_b();
734  m_dzdr_t = seed->dzdr_t();
735  m_pt = seed->pt();
736  m_givesTrack = !(track == nullptr);
737  m_eventNumber = eventNumber;
738 
739  // Ok: protected by mutex.
740  TTree* outputTree ATLAS_THREAD_SAFE = m_outputTree;
741  outputTree->Fill();
742  }

Member Data Documentation

◆ ATLAS_THREAD_SAFE [1/26]

std::string m_treeName ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = ""
mutableprivate

Definition at line 232 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [2/26]

std::string m_treeFolder ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = "/valNtuples/"
mutableprivate

Definition at line 233 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [3/26]

float m_d0 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 235 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [4/26]

float m_z0 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 236 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [5/26]

float m_pt ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 237 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [6/26]

float m_eta ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 238 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [7/26]

double m_x1 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 239 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [8/26]

double m_x2 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 240 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [9/26]

double m_x3 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 241 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [10/26]

double m_y1 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 242 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [11/26]

double m_y2 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 243 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [12/26]

double m_y3 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 244 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [13/26]

double m_z1 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 245 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [14/26]

double m_z2 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 246 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [15/26]

double m_z3 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 247 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [16/26]

double m_r1 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 248 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [17/26]

double m_r2 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 249 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [18/26]

double m_r3 ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 250 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [19/26]

float m_quality ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 251 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [20/26]

int m_type ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 252 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [21/26]

double m_dzdr_t ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 253 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [22/26]

double m_dzdr_b ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 254 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [23/26]

bool m_givesTrack ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = false
mutableprivate

Definition at line 255 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [24/26]

float m_trackPt ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 256 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [25/26]

float m_trackEta ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 257 of file SiSpacePointsSeedMaker.h.

◆ ATLAS_THREAD_SAFE [26/26]

long m_eventNumber ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE = 0
mutableprivate

Definition at line 258 of file SiSpacePointsSeedMaker.h.

◆ m_actsSpacepointsOverlap

SG::ReadHandleKey< xAOD::SpacePointContainer > ActsTrk::SiSpacePointsSeedMaker::m_actsSpacepointsOverlap {this, "ActsSpacePointsOverlapName", "", "Strip overlap space points container"}
private

Definition at line 205 of file SiSpacePointsSeedMaker.h.

◆ m_actsSpacepointsPixel

SG::ReadHandleKey< xAOD::SpacePointContainer > ActsTrk::SiSpacePointsSeedMaker::m_actsSpacepointsPixel {this, "ActsSpacePointsPixelName", "", "Pixel space points container"}
private

Definition at line 203 of file SiSpacePointsSeedMaker.h.

◆ m_actsSpacepointsStrip

SG::ReadHandleKey< xAOD::SpacePointContainer > ActsTrk::SiSpacePointsSeedMaker::m_actsSpacepointsStrip {this, "ActsSpacePointsStripName", "", "Strip space points container"}
private

Definition at line 204 of file SiSpacePointsSeedMaker.h.

◆ m_beamSpotKey

SG::ReadCondHandleKey< InDet::BeamSpotData > ActsTrk::SiSpacePointsSeedMaker::m_beamSpotKey {this, "BeamSpotKey", "BeamSpotData", "SG key for beam spot"}
private

Definition at line 207 of file SiSpacePointsSeedMaker.h.

◆ m_doSeedConversion

Gaudi::Property< bool > ActsTrk::SiSpacePointsSeedMaker::m_doSeedConversion {this, "doSeedConversion", true, "Convert ActsTrk::Seed into ITk::SiSpacePointsProSeed"}
private

Definition at line 220 of file SiSpacePointsSeedMaker.h.

◆ m_fastTracking

Gaudi::Property< bool > ActsTrk::SiSpacePointsSeedMaker::m_fastTracking {this, "useFastTracking", false}
private

Definition at line 219 of file SiSpacePointsSeedMaker.h.

◆ m_fieldCondObjInputKey

SG::ReadCondHandleKey< AtlasFieldCacheCondObj > ActsTrk::SiSpacePointsSeedMaker::m_fieldCondObjInputKey
private
Initial value:
{this, "AtlasFieldCacheCondObj", "fieldCondObj",
"Name of the Magnetic Field conditions object key"}

Definition at line 208 of file SiSpacePointsSeedMaker.h.

◆ m_mutex

std::mutex ActsTrk::SiSpacePointsSeedMaker::m_mutex
mutableprivate

Definition at line 227 of file SiSpacePointsSeedMaker.h.

◆ m_outputTree

TTree* ActsTrk::SiSpacePointsSeedMaker::m_outputTree = nullptr
private

Definition at line 230 of file SiSpacePointsSeedMaker.h.

◆ m_pixel

Gaudi::Property< bool > ActsTrk::SiSpacePointsSeedMaker::m_pixel {this, "usePixel", true}
private

Definition at line 216 of file SiSpacePointsSeedMaker.h.

◆ m_pixelDetEleCollKey

SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > ActsTrk::SiSpacePointsSeedMaker::m_pixelDetEleCollKey
private
Initial value:
{this, "PixelDetectorElements", "ITkPixelDetectorElementCollection",
"Key of input SiDetectorElementCollection"}

Definition at line 211 of file SiSpacePointsSeedMaker.h.

◆ m_prdToTrackMap

SG::ReadHandleKey< Trk::PRDtoTrackMap > ActsTrk::SiSpacePointsSeedMaker::m_prdToTrackMap {this, "PRDtoTrackMap", "", "option PRD-to-track association"}
private

Definition at line 201 of file SiSpacePointsSeedMaker.h.

◆ m_seedsToolPixel

ToolHandle< ActsTrk::ISeedingTool > ActsTrk::SiSpacePointsSeedMaker::m_seedsToolPixel {this, "SeedToolPixel", "","Seed Tool for Pixel detector"}
private

Definition at line 198 of file SiSpacePointsSeedMaker.h.

◆ m_seedsToolStrip

ToolHandle< ActsTrk::ISeedingTool > ActsTrk::SiSpacePointsSeedMaker::m_seedsToolStrip {this, "SeedToolStrip", "","Seed Tool for Strip detector"}
private

Definition at line 199 of file SiSpacePointsSeedMaker.h.

◆ m_strip

Gaudi::Property< bool > ActsTrk::SiSpacePointsSeedMaker::m_strip {this, "useStrip", true }
private

Definition at line 217 of file SiSpacePointsSeedMaker.h.

◆ m_stripDetEleCollKey

SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > ActsTrk::SiSpacePointsSeedMaker::m_stripDetEleCollKey
private
Initial value:
{this, "StripDetectorElements", "ITkStripDetectorElementCollection",
"Key of input SiDetectorElementCollection"}

Definition at line 213 of file SiSpacePointsSeedMaker.h.

◆ m_thistSvc

ITHistSvc* ActsTrk::SiSpacePointsSeedMaker::m_thistSvc = nullptr
private

Definition at line 229 of file SiSpacePointsSeedMaker.h.

◆ m_useClusters

Gaudi::Property< bool > ActsTrk::SiSpacePointsSeedMaker::m_useClusters {this, "useClustersForSeedConversion", false}
private

Definition at line 221 of file SiSpacePointsSeedMaker.h.

◆ m_useOverlap

Gaudi::Property< bool > ActsTrk::SiSpacePointsSeedMaker::m_useOverlap {this, "useOverlapSpCollection", true}
private

Definition at line 218 of file SiSpacePointsSeedMaker.h.

◆ m_writeNtuple

Gaudi::Property< bool > ActsTrk::SiSpacePointsSeedMaker::m_writeNtuple {this, "WriteNtuple", false}
private

Definition at line 225 of file SiSpacePointsSeedMaker.h.


The documentation for this class was generated from the following files:
Trk::SpacePoint::clusterList
const std::pair< const PrepRawData *, const PrepRawData * > & clusterList() const
return the pair of cluster pointers by reference
Definition: Tracking/TrkEvent/TrkSpacePoint/TrkSpacePoint/SpacePoint.h:127
replace
std::string replace(std::string s, const std::string &s2, const std::string &s3)
Definition: hcg.cxx:307
Trk::SpacePoint
Definition: Tracking/TrkEvent/TrkSpacePoint/TrkSpacePoint/SpacePoint.h:35
beamspotman.r
def r
Definition: beamspotman.py:676
xAOD::UncalibratedMeasurement_v1::identifierHash
DetectorIDHashType identifierHash() const
Returns the IdentifierHash of the measurement (corresponds to the detector element IdentifierHash)
trigbs_pickEvents.ranges
ranges
Definition: trigbs_pickEvents.py:60
data
char data[hepevt_bytes_allocation_ATLAS]
Definition: HepEvt.cxx:11
ActsTrk::SiSpacePointsSeedMaker::m_seedsToolPixel
ToolHandle< ActsTrk::ISeedingTool > m_seedsToolPixel
Definition: SiSpacePointsSeedMaker.h:198
ReadCellNoiseFromCoolCompare.s1
s1
Definition: ReadCellNoiseFromCoolCompare.py:378
python.CaloRecoConfig.f
f
Definition: CaloRecoConfig.py:127
ActsTrk::SiSpacePointsSeedMaker::m_useOverlap
Gaudi::Property< bool > m_useOverlap
Definition: SiSpacePointsSeedMaker.h:218
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
ATLASMagneticFieldWrapper
Definition: ATLASMagneticFieldWrapper.h:15
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
max
#define max(a, b)
Definition: cfImp.cxx:41
ActsTrk::SiSpacePointsSeedMaker::skipSpacePoint
bool skipSpacePoint(float x, float y, float z) const
Definition: SiSpacePointsSeedMaker.cxx:132
phi
Scalar phi() const
phi method
Definition: AmgMatrixBasePlugin.h:64
ContainerAccessor
Definition: ContainerAccessor.h:25
InDetDD::SiDetectorElementCollection
Definition: SiDetectorElementCollection.h:30
SG::ReadCondHandle
Definition: ReadCondHandle.h:44
ActsTrk::SiSpacePointsSeedMaker::stripInform
static void stripInform(InDet::SiSpacePointsSeedMakerEventData &data, const Trk::SpacePoint *const &sp, float *r)
Definition: SiSpacePointsSeedMaker.cxx:157
IDTPM::R
float R(const U &p)
Definition: TrackParametersHelper.h:101
AtlasFieldCacheCondObj
Definition: AtlasFieldCacheCondObj.h:19
SG::Accessor
Helper class to provide type-safe access to aux data.
Definition: Control/AthContainers/AthContainers/Accessor.h:66
ActsTrk::SiSpacePointsSeedMaker::m_mutex
std::mutex m_mutex
Definition: SiSpacePointsSeedMaker.h:227
InDet::SiSpacePointsSeedMakerEventData::clearPoolList
static void clearPoolList(std::list< T, SG::ArenaPoolSTLAllocator< T >> &poolList)
Definition: SiSpacePointsSeedMakerEventData.h:219
egammaEnergyPositionAllSamples::e1
double e1(const xAOD::CaloCluster &cluster)
return the uncorrected cluster energy in 1st sampling
Trk::PRDtoTrackMap
Definition: PRDtoTrackMap.h:17
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition: GeoPrimitives.h:48
SG::ReadHandle< Trk::PRDtoTrackMap >
index
Definition: index.py:1
ActsTrk::SiSpacePointsSeedMaker::m_doSeedConversion
Gaudi::Property< bool > m_doSeedConversion
Definition: SiSpacePointsSeedMaker.h:220
hist_file_dump.d
d
Definition: hist_file_dump.py:137
theta
Scalar theta() const
theta method
Definition: AmgMatrixBasePlugin.h:71
ActsTrk::SiSpacePointsSeedMaker::m_writeNtuple
Gaudi::Property< bool > m_writeNtuple
Definition: SiSpacePointsSeedMaker.h:225
extractSporadic.c1
c1
Definition: extractSporadic.py:134
ActsTrk::Seed
Acts::Seed< xAOD::SpacePoint > Seed
Definition: Seed.h:13
python.AthDsoLogger.out
out
Definition: AthDsoLogger.py:71
ActsTrk::SiSpacePointsSeedMaker::pixInform
static void pixInform(const Trk::SpacePoint *const &sp, float *r)
Definition: SiSpacePointsSeedMaker.cxx:145
InDetDD::SolidStateDetectorElementBase::surface
Trk::Surface & surface()
Element Surface.
SG::ReadCondHandle::isValid
bool isValid()
Definition: ReadCondHandle.h:205
ActsTrk::SiSpacePointsSeedMaker::m_outputTree
TTree * m_outputTree
Definition: SiSpacePointsSeedMaker.h:230
MCP::ScaleSmearParam::s0
@ s0
dq_defect_virtual_defect_validation.d1
d1
Definition: dq_defect_virtual_defect_validation.py:79
xAOD::SpacePoint_v1
Definition: SpacePoint_v1.h:29
ActsTrk::SiSpacePointsSeedMaker::PPP
@ PPP
Definition: SiSpacePointsSeedMaker.h:47
ActsTrk::SiSpacePointsSeedMaker::m_actsSpacepointsStrip
SG::ReadHandleKey< xAOD::SpacePointContainer > m_actsSpacepointsStrip
Definition: SiSpacePointsSeedMaker.h:204
ReadCellNoiseFromCoolCompare.s4
s4
Definition: ReadCellNoiseFromCoolCompare.py:381
SG::ConstAccessor
Helper class to provide constant type-safe access to aux data.
Definition: ConstAccessor.h:54
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
drawFromPickle.cos
cos
Definition: drawFromPickle.py:36
ActsTrk::SiSpacePointsSeedMaker::convertPixelSeed
bool convertPixelSeed(const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const ActsTrk::SeedContainer &seedPtrs) const
Definition: SiSpacePointsSeedMaker.cxx:979
SG::VarHandleKey::key
const std::string & key() const
Return the StoreGate ID for the referenced object.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:141
ActsTrk::SiSpacePointsSeedMaker::m_pixel
Gaudi::Property< bool > m_pixel
Definition: SiSpacePointsSeedMaker.h:216
SG::VarHandleKey::empty
bool empty() const
Test if the key is blank.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:150
x
#define x
xAOD::SpacePoint_v1::z
float z() const
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
ATLASMagneticFieldWrapper::makeCache
MagneticFieldProvider::Cache makeCache(const Acts::MagneticFieldContext &mctx) const override
Definition: ATLASMagneticFieldWrapper.h:34
ActsTrk::SiSpacePointsSeedMaker::m_beamSpotKey
SG::ReadCondHandleKey< InDet::BeamSpotData > m_beamSpotKey
Definition: SiSpacePointsSeedMaker.h:207
ActsTrk::SiSpacePointsSeedMaker::m_strip
Gaudi::Property< bool > m_strip
Definition: SiSpacePointsSeedMaker.h:217
xAOD::SpacePoint_v1::elementIdList
const std::vector< DetectorIDHashType > & elementIdList() const
Returns the IdentifierHash of the spacepoint (corresponds to the detector element IdentifierHash)
InDetDD::SiLocalPosition
Definition: SiLocalPosition.h:31
ActsTrk::SiSpacePointsSeedMaker::m_prdToTrackMap
SG::ReadHandleKey< Trk::PRDtoTrackMap > m_prdToTrackMap
Definition: SiSpacePointsSeedMaker.h:201
SG::makeHandle
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
Definition: ReadCondHandle.h:269
m_type
TokenType m_type
the type
Definition: TProperty.cxx:44
hotSpotInTAG.c0
c0
Definition: hotSpotInTAG.py:192
PhysDESDM_SmpCaloId.inputCollection
inputCollection
Definition: PhysDESDM_SmpCaloId.py:95
ActsTrk::SiSpacePointsSeedMaker::m_fieldCondObjInputKey
SG::ReadCondHandleKey< AtlasFieldCacheCondObj > m_fieldCondObjInputKey
Definition: SiSpacePointsSeedMaker.h:208
Generate_dsid_ranseed.seed
seed
Definition: Generate_dsid_ranseed.py:10
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
ActsTrk::SiSpacePointsSeedMaker::retrieveStrip
StatusCode retrieveStrip(const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const Trk::PRDtoTrackMap *prd_to_track_map_cptr) const
Definition: SiSpacePointsSeedMaker.cxx:272
ActsTrk::SiSpacePointsSeedMaker::m_fastTracking
Gaudi::Property< bool > m_fastTracking
Definition: SiSpacePointsSeedMaker.h:219
z
#define z
beamspotman.n
n
Definition: beamspotman.py:731
ActsTrk::SiSpacePointsSeedMaker::m_thistSvc
ITHistSvc * m_thistSvc
Definition: SiSpacePointsSeedMaker.h:229
endmsg
#define endmsg
Definition: AnalysisConfig_Ntuple.cxx:63
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
SG::ReadHandle::get
const_pointer_type get() const
Dereference the pointer, but don't cache anything.
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
ActsTrk::SiSpacePointsSeedMaker::newSpacePoint
void newSpacePoint(InDet::SiSpacePointsSeedMakerEventData &data, const xAOD::SpacePoint *const &sp) const
Definition: SiSpacePointsSeedMaker.cxx:121
ActsTrk::SiSpacePointsSeedMaker::m_seedsToolStrip
ToolHandle< ActsTrk::ISeedingTool > m_seedsToolStrip
Definition: SiSpacePointsSeedMaker.h:199
Amg::Transform3D
Eigen::Affine3d Transform3D
Definition: GeoPrimitives.h:46
TRT::Track::d0
@ d0
Definition: InnerDetector/InDetCalibEvent/TRT_CalibData/TRT_CalibData/TrackInfo.h:62
ActsTrk::SiSpacePointsSeedMaker::buildBeamFrameWork
void buildBeamFrameWork(const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data) const
Definition: SiSpacePointsSeedMaker.cxx:412
xAOD::StripCluster_v1
Definition: StripCluster_v1.h:17
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
drawFromPickle.tan
tan
Definition: drawFromPickle.py:36
xAOD::eventNumber
eventNumber
Definition: EventInfo_v1.cxx:124
SG::VarHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:103
DataVector
Derived DataVector<T>.
Definition: DataVector.h:581
Trk::PRDtoTrackMap::isUsed
bool isUsed(const PrepRawData &prd) const
does this PRD belong to at least one track?
SG::ReadHandle::isValid
virtual bool isValid() override final
Can the handle be successfully dereferenced?
ActsTrk::SiSpacePointsSeedMaker::m_actsSpacepointsPixel
SG::ReadHandleKey< xAOD::SpacePointContainer > m_actsSpacepointsPixel
Definition: SiSpacePointsSeedMaker.h:203
Trk::PrepRawData
Definition: PrepRawData.h:62
ActsTrk::SiSpacePointsSeedMaker::m_useClusters
Gaudi::Property< bool > m_useClusters
Definition: SiSpacePointsSeedMaker.h:221
ActsTrk::SiSpacePointsSeedMaker::retrieveOverlap
StatusCode retrieveOverlap(const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const Trk::PRDtoTrackMap *prd_to_track_map_cptr) const
Definition: SiSpacePointsSeedMaker.cxx:343
ActsTrk::SiSpacePointsSeedMaker::dumpConditions
MsgStream & dumpConditions(InDet::SiSpacePointsSeedMakerEventData &data, MsgStream &out) const
Definition: SiSpacePointsSeedMaker.cxx:762
dumpTgcDigiThreshold.isStrip
list isStrip
Definition: dumpTgcDigiThreshold.py:33
ReadCellNoiseFromCoolCompare.s3
s3
Definition: ReadCellNoiseFromCoolCompare.py:380
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:195
python.subdetectors.mmg.ids
ids
Definition: mmg.py:8
InDetDD::SiDetectorElement
Definition: SiDetectorElement.h:109
SG::CondHandleKey::initialize
StatusCode initialize(bool used=true)
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
xAOD::SpacePoint_v1::y
float y() const
xAOD::JetAttributeAccessor::accessor
const AccessorWrapper< T > * accessor(xAOD::JetAttribute::AttributeID id)
Returns an attribute accessor corresponding to an AttributeID.
Definition: JetAccessorMap.h:26
ActsTrk::SiSpacePointsSeedMaker::InitTree
StatusCode InitTree()
Definition: SiSpacePointsSeedMaker.cxx:81
python.SystemOfUnits.mm
int mm
Definition: SystemOfUnits.py:83
DeMoScan.index
string index
Definition: DeMoScan.py:362
xAOD::PixelCluster_v1
Definition: PixelCluster_v1.h:17
y
#define y
ATLASMagneticFieldWrapper::getField
Acts::Result< Acts::Vector3 > getField(const Acts::Vector3 &position, Acts::MagneticFieldProvider::Cache &gcache) const override
Definition: ATLASMagneticFieldWrapper.h:39
DEBUG
#define DEBUG
Definition: page_access.h:11
ReadCellNoiseFromCoolCompare.s2
s2
Definition: ReadCellNoiseFromCoolCompare.py:379
ActsTrk::SiSpacePointsSeedMaker::isUsed
bool isUsed(const Trk::SpacePoint *, const Trk::PRDtoTrackMap &prd_to_track_map) const
Definition: SiSpacePointsSeedMaker.h:266
xAOD::SpacePoint_v1::x
float x() const
TRT::Track::cotTheta
@ cotTheta
Definition: InnerDetector/InDetCalibEvent/TRT_CalibData/TRT_CalibData/TrackInfo.h:65
ActsTrk::SiSpacePointsSeedMaker::m_stripDetEleCollKey
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_stripDetEleCollKey
Definition: SiSpacePointsSeedMaker.h:213
ActsTrk::SiSpacePointsSeedMaker::dump
virtual MsgStream & dump(InDet::SiSpacePointsSeedMakerEventData &data, MsgStream &out) const override
Definition: SiSpacePointsSeedMaker.cxx:749
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
egammaEnergyPositionAllSamples::e0
double e0(const xAOD::CaloCluster &cluster)
return the uncorrected cluster energy in pre-sampler
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
IdentifierHash
Definition: IdentifierHash.h:38
ActsTrk::SiSpacePointsSeedMaker::SSS
@ SSS
Definition: SiSpacePointsSeedMaker.h:47
ActsTrk::SiSpacePointsSeedMaker::dumpEvent
static MsgStream & dumpEvent(InDet::SiSpacePointsSeedMakerEventData &data, MsgStream &out)
Definition: SiSpacePointsSeedMaker.cxx:834
ActsTrk::SiSpacePointsSeedMaker::m_pixelDetEleCollKey
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_pixelDetEleCollKey
Definition: SiSpacePointsSeedMaker.h:211
Trk::Surface::transform
const Amg::Transform3D & transform() const
Returns HepGeom::Transform3D by reference.
dq_make_web_display.cl
cl
print [x.__class__ for x in toList(dqregion.getSubRegions()) ]
Definition: dq_make_web_display.py:26
ActsTrk::SiSpacePointsSeedMaker::ATLAS_THREAD_SAFE
std::string m_treeName ATLAS_THREAD_SAFE
Definition: SiSpacePointsSeedMaker.h:232
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
TileDCSDataPlotter.tx
tx
Definition: TileDCSDataPlotter.py:878
ActsTrk::SiSpacePointsSeedMaker::convertStripSeed
bool convertStripSeed(const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const ActsTrk::SeedContainer &seedPtrs) const
Definition: SiSpacePointsSeedMaker.cxx:855
python.AutoConfigFlags.msg
msg
Definition: AutoConfigFlags.py:7
InDet::SiCluster
Definition: InnerDetector/InDetRecEvent/InDetPrepRawData/InDetPrepRawData/SiCluster.h:40
ActsTrk::SiSpacePointsSeedMaker::retrievePixel
StatusCode retrievePixel(const EventContext &ctx, InDet::SiSpacePointsSeedMakerEventData &data, const Trk::PRDtoTrackMap *prd_to_track_map_cptr) const
Definition: SiSpacePointsSeedMaker.cxx:203
ActsTrk::SiSpacePointsSeedMaker::m_actsSpacepointsOverlap
SG::ReadHandleKey< xAOD::SpacePointContainer > m_actsSpacepointsOverlap
Definition: SiSpacePointsSeedMaker.h:205
ITk::SiSpacePointForSeed
Definition: ITkSiSpacePointForSeed.h:33
SG::ReadCondHandle::cptr
const_pointer_type cptr()
Definition: ReadCondHandle.h:67