ACTS
Experiment-independent tracking
Loading...
Searching...
No Matches
Acts::SeedDeduplicator Class Reference

Flags seeds whose measurements one accepted track already holds. More...

#include <Acts/TrackFinding/SeedDeduplicator.hpp>

Classes

struct  Config
 Configuration of the duplicate threshold. More...

Public Types

using MeasurementKey = std::uint32_t
 Type of the dense measurement key.
using Score = std::uint32_t
 Type of a summed weight.
using Weight = std::uint8_t
 Type of the weight of a key.

Public Member Functions

 SeedDeduplicator (const Config &config)
 Constructor.
void addTrack (std::span< const MeasurementKey > measKeys)
 Accept a track.
bool isDuplicate (std::span< const MeasurementKey > measKeys) const
 Check if one accepted track holds enough of the seed keys.
std::size_t nTracks () const
void reset (std::size_t nMeasKeys)
 Remove all tracks and set the key range.
void setWeight (MeasurementKey measKey, Weight weight)
 Set the weight of a key.
Weight weight (MeasurementKey measKey) const

Detailed Description

Flags seeds whose measurements one accepted track already holds.

Measurements are dense keys in [0, nMeasKeys). The caller chooses which keys a seed contributes. The keys are plain indices and not SourceLinks, because a SourceLink has no hash and no equality comparison.

Each key has a weight, 1 by default. The weight can for example be the number of measured local coordinates, so that a pixel measurement counts 2 and a strip measurement counts 1. A seed with the summed weight seedScore is a duplicate if one track holds keys of the summed weight

min(seedScore, max(1, minScore, seedScore - maxMissingScore)).

The scores of different tracks do not add up. Seeds can be queried in any order.

Constructor & Destructor Documentation

◆ SeedDeduplicator()

Acts::SeedDeduplicator::SeedDeduplicator ( const Config & config)
explicit

Constructor.

Parameters
configThe threshold configuration

Member Function Documentation

◆ addTrack()

void Acts::SeedDeduplicator::addTrack ( std::span< const MeasurementKey > measKeys)

Accept a track.

Parameters
measKeysThe keys of the measurements on the track

◆ isDuplicate()

bool Acts::SeedDeduplicator::isDuplicate ( std::span< const MeasurementKey > measKeys) const

Check if one accepted track holds enough of the seed keys.

Parameters
measKeysThe keys of the seed, each key at most once
Returns
True if the seed is a duplicate

◆ nTracks()

std::size_t Acts::SeedDeduplicator::nTracks ( ) const
Returns
The number of accepted tracks

◆ reset()

void Acts::SeedDeduplicator::reset ( std::size_t nMeasKeys)

Remove all tracks and set the key range.

Every weight becomes 1.

Parameters
nMeasKeysThe number of measurement keys, every key must be below this number

◆ setWeight()

void Acts::SeedDeduplicator::setWeight ( MeasurementKey measKey,
Weight weight )

Set the weight of a key.

Parameters
measKeyThe measurement key
weightThe weight of the key

◆ weight()

Weight Acts::SeedDeduplicator::weight ( MeasurementKey measKey) const
Parameters
measKeyThe measurement key
Returns
The weight of the key