Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-06 08:18:25

0001 #ifndef TRACKRECO_MAKESOURCELINKS_H
0002 #define TRACKRECO_MAKESOURCELINKS_H
0003 
0004 #include <trackbase/TrkrDefs.h>
0005 #include <trackbase/ActsGeometry.h>
0006 #include <trackbase/ActsTrackFittingAlgorithm.h>
0007 #include <trackbase/alignmentTransformationContainer.h>
0008 #include <trackbase/ClusterErrorPara.h>
0009 
0010 #include <tpc/TpcClusterMover.h>
0011 
0012 /// Acts includes to create all necessary definitions
0013 #include <Acts/Utilities/BinnedArray.hpp>
0014 #include <Acts/Definitions/Algebra.hpp>
0015 
0016 #include <trackbase_historic/SvtxTrack.h>
0017 
0018 /// std (and the like) includes
0019 #include <cmath>
0020 #include <iostream>
0021 #include <memory>
0022 #include <utility>
0023 
0024 using SourceLink = ActsSourceLink;
0025 using SourceLinkVec = std::vector<Acts::SourceLink>;
0026 
0027 // forward declarations
0028 class SvtxTrack;
0029 class SvtxTrackState;
0030 class TrkrCluster;
0031 class TrkrClusterContainer;
0032 class TpcGlobalPositionWrapper;
0033 class TrackSeed;
0034 
0035 /**
0036    This class contains the code that generates Acts source links and makes the modified GeoContext
0037    that applies cluster crossing and distortion corrections in the alignment transformations.
0038    It is used by all of the Acts track fitting modules.
0039  */
0040 class MakeSourceLinks
0041 {
0042  public:
0043  MakeSourceLinks() = default;
0044 
0045  void initialize(PHG4TpcCylinderGeomContainer* cellgeo);
0046 
0047   void setVerbosity(int verbosity) {m_verbosity = verbosity;}
0048 
0049  void set_pp_mode(bool ispp) { m_pp_mode = ispp; }
0050 
0051   void ignoreLayer(int layer) { m_ignoreLayer.insert(layer); }
0052 
0053   SourceLinkVec getSourceLinks(
0054     TrackSeed* /*seed*/,
0055     ActsTrackFittingAlgorithm::MeasurementContainer& /*measurements*/,
0056     TrkrClusterContainer* /*clusters*/,
0057     ActsGeometry* /*geometry*/,
0058     const TpcGlobalPositionWrapper& /*globalpositionWrapper*/,
0059     alignmentTransformationContainer* /*transformMapTransient*/,
0060     std::set< Acts::GeometryIdentifier>& /*transient_id_set*/,
0061     short int /*crossing*/);
0062 
0063   void resetTransientTransformMap(
0064     alignmentTransformationContainer* /*transformMapTransient*/,
0065     std::set< Acts::GeometryIdentifier>& /*transient_id_set*/,
0066     ActsGeometry* /*tGeometry*/ );
0067 
0068   SourceLinkVec getSourceLinksClusterMover(
0069     TrackSeed* /*seed*/,
0070     ActsTrackFittingAlgorithm::MeasurementContainer& /*measurements*/,
0071     TrkrClusterContainer* /*clusters*/,
0072     ActsGeometry* /*geometry*/,
0073     const TpcGlobalPositionWrapper& /*globalpositionWrapper*/,
0074     short int crossing
0075     );
0076 
0077  private:
0078   int m_verbosity = 0;
0079   bool m_pp_mode = false;
0080   std::set<int> m_ignoreLayer;
0081 
0082   TpcClusterMover _clusterMover;
0083 
0084   ClusterErrorPara _ClusErrPara;
0085 
0086 
0087 };
0088 
0089 
0090 #endif