pub struct Tracklet<T: DetectionBox> {
pub id: Uuid,
pub filter: ConstantVelocityXYAHModel2<f32>,
pub count: i32,
pub created: u64,
pub last_updated: u64,
pub last_box: T,
}Expand description
Internal state for one tracked object.
Not part of the public API contract; exposed as pub for test and benchmark
access only. The canonical public view of a tracklet is TrackInfo
(returned by Tracker::update) or ActiveTrackInfo (returned by
Tracker::get_active_tracks).
Fields§
§id: UuidGlobally unique identifier, assigned at tracklet creation and preserved
until the tracklet is deleted. Surfaced via TrackInfo::uuid.
filter: ConstantVelocityXYAHModel2<f32>Kalman filter modeling the tracklet’s position and velocity in XYAH
space ([x_center, y_center, aspect, height] + their derivatives).
count: i32Number of frames this tracklet has been matched to a detection. Starts
at 1 on the frame of creation. Surfaced via TrackInfo::count.
created: u64Timestamp passed to Tracker::update on the frame this tracklet was
created. Surfaced via TrackInfo::created.
last_updated: u64Timestamp passed to Tracker::update on the most recent frame this
tracklet was matched to a detection. Tracklets are deleted when
timestamp - last_updated > track_extra_lifespan.
last_box: TThe raw detection box from the most recent match. Surfaced via
ActiveTrackInfo::last_box. Not Kalman-smoothed.
Implementations§
Source§impl<T: DetectionBox> Tracklet<T>
impl<T: DetectionBox> Tracklet<T>
Sourcepub fn get_predicted_location(&self) -> [f32; 4]
pub fn get_predicted_location(&self) -> [f32; 4]
Return the current Kalman-predicted bounding box in XYXY format.
Projects the filter’s 8-D XYAH mean into 4-D measurement space and
converts back to [xmin, ymin, xmax, ymax]. This is the value
surfaced in TrackInfo::tracked_location.
Trait Implementations§
Auto Trait Implementations§
impl<T> Freeze for Tracklet<T>where
T: Freeze,
impl<T> RefUnwindSafe for Tracklet<T>where
T: RefUnwindSafe,
impl<T> Send for Tracklet<T>where
T: Send,
impl<T> Sync for Tracklet<T>where
T: Sync,
impl<T> Unpin for Tracklet<T>where
T: Unpin,
impl<T> UnsafeUnpin for Tracklet<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for Tracklet<T>where
T: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.