dgs.utils.track.Track¶
- class dgs.utils.track.Track(N: int, curr_frame: int, states: list[State] | None = None, tid: int = -1)[source]¶
A Track is a single (de-)queue containing multiple
State
’s, keeping the last N states.- Parameters:
N – The max length of this track.
states – A list of
State
objects, describing the initial values of this track. Default None.tid – The Track ID of this object. Default -1.
Methods
- age(curr_frame: int) int [source]¶
Get the age of this track (in frames).
The age does not account for frames where the track has been deleted.
- set_status(status: TrackStatus, tid: int = 0) None [source]¶
Set the status of this Track.