10#include <cdc/topology/ISuperLayer.h>
11#include <tracking/trackingUtilities/numerics/ESign.h>
22 namespace TrackingUtilities {
29 namespace TrackFindingCDC {
38 static void addCandidateFromHits(
const std::vector<const TrackingUtilities::CDCWireHit*>& foundAxialWireHits,
39 const std::vector<const TrackingUtilities::CDCWireHit*>& allAxialWireHits,
40 std::vector<TrackingUtilities::CDCTrack>& axialTracks,
41 bool withPostprocessing =
true);
45 const std::vector<const TrackingUtilities::CDCWireHit*>& allAxialWireHits);
70 const std::vector<const TrackingUtilities::CDCWireHit*>& allAxialWireHits,
71 double minimalDistance = 0.2);
115 double minimal_probability_for_good_fit = 0.4);
118 static void deleteShortTracks(std::vector<TrackingUtilities::CDCTrack>& axialTracks,
double minimal_size = 5);
122 static std::vector<CDC::ISuperLayer>
getSLayerHoles(
const std::array<int, CDC::ISuperLayerUtil::c_N>&
Class representing a three dimensional reconstructed hit.
Class representing a sequence of three dimensional reconstructed hits.
Particle trajectory as it is seen in xy projection represented as a circle.
Class representing a hit wire in the central drift chamber.
A two dimensional vector which is equipped with functions for correct handling of orientation relate...
signed short ISuperLayer
The type of the layer and superlayer ids.
Abstract base class for different kinds of events.
Utility structure gathering heuristic functions used during the axial track finding.
static void normalizeTrack(TrackingUtilities::CDCTrack &track)
Refit and resort the track. Unmask all hits.
static void deleteShortTracks(std::vector< TrackingUtilities::CDCTrack > &axialTracks, double minimal_size=5)
Remove tracks that are shorter than the given number of hits.
static void updateRecoHit3D(const TrackingUtilities::CDCTrajectory2D &trajectory2D, TrackingUtilities::CDCRecoHit3D &hit)
update given CDCRecoHit3D with given trajectory
static void addCandidateFromHits(const std::vector< const TrackingUtilities::CDCWireHit * > &foundAxialWireHits, const std::vector< const TrackingUtilities::CDCWireHit * > &allAxialWireHits, std::vector< TrackingUtilities::CDCTrack > &axialTracks, bool withPostprocessing=true)
Create CDCTrack using CDCWireHit hits and store it in the list. Then call the postprocessing on it.
static void deleteTracksWithLowFitProbability(std::vector< TrackingUtilities::CDCTrack > &axialTracks, double minimal_probability_for_good_fit=0.4)
Check an (improper) p-values of the tracks. If they are below the given value, delete the track from ...
static TrackingUtilities::ESign getMajorArmSign(const TrackingUtilities::CDCTrack &track, const TrackingUtilities::Vector2D ¢er)
Calculate whether the majority of hits is to the right or to the left relative to the line from origi...
static void removeHitsAfterSuperLayerBreak(TrackingUtilities::CDCTrack &track)
Searches for a break in the super layer chain and remove all hits that come after that.
static int getArmSignVote(const TrackingUtilities::CDCTrack &track, const TrackingUtilities::Vector2D ¢er)
Calculate the sum of right and left votes for the hits relative to the center.
static std::vector< CDC::ISuperLayer > getSLayerHoles(const std::array< int, CDC::ISuperLayerUtil::c_N > &nHitsBySLayer)
Helper function getting the empty axial!
static std::vector< TrackingUtilities::CDCRecoHit3D > splitBack2BackTrack(TrackingUtilities::CDCTrack &track)
Tries to split back-to-back tracks into two different tracks.
static void assignNewHitsToTrack(TrackingUtilities::CDCTrack &track, const std::vector< const TrackingUtilities::CDCWireHit * > &allAxialWireHits, double minimalDistance=0.2)
Assign new hits to the track basing on the distance from the hit to the track.
static bool postprocessTrack(TrackingUtilities::CDCTrack &track, const std::vector< const TrackingUtilities::CDCWireHit * > &allAxialWireHits)
Perform all track postprocessing - return whether the track is considered good after the postprocessi...
static void deleteHitsFarAwayFromTrajectory(TrackingUtilities::CDCTrack &track, double maximumDistance=0.2)
Postprocessing: Delete axial hits that do not "match" to the given track.
static TrackingUtilities::ESign getArmSign(const TrackingUtilities::CDCRecoHit3D &hit, const TrackingUtilities::Vector2D ¢er)
Calculate whether the hits is to the right or to the left relative to the line from origin to the giv...
static bool isBack2BackTrack(TrackingUtilities::CDCTrack &track)
Checks whether the track has hits on both arms as seen from the origin.
static CDC::ISuperLayer getLastOccupiedISuperLayer(const std::array< int, CDC::ISuperLayerUtil::c_N > &nHitsBySLayer)
Helper function to extract the last filled entry in the array of super layers ( = the final superlaye...
static bool checkTrackQuality(const TrackingUtilities::CDCTrack &track)
Check track quality – currently based on number of hits only.
static CDC::ISuperLayer getFirstOccupiedISuperLayer(const std::array< int, CDC::ISuperLayerUtil::c_N > &nHitsBySLayer)
Helper function to extract the first filled entry in the array of super layers ( = the start superlay...