public class PruneCloseTracks<T> extends Object
Detects if tracks are too close together and discards some of the close ones. Tracks are projected into a smaller grid (specified by scale) and if more than one lands on the same grid element it is pruned. An ambiguity resolver is used to decide which track to keep if there's a conflict. If the resolver says they are equivalent then featureID is used. Results should be consistent independent of order in tracks list. This is designed to work with different types of track data structures.
Nested Class Summary
Nested Classes Modifier and Type Class Description
protected static class
static interfaceInterface which allows multiple track data structures be passed in
Modifier and Type Method Description
(int imgWidth, int imgHeight)Initializes data structures for the specified input image size
List<T> tracks, List<T> dropTracks)(Processes existing tracks and adds tracks to drop list if they are too close to other tracks and considered less desirable
(int radius)Convenience function for creating a variant for PointTrack
initpublic void init(int imgWidth, int imgHeight)Initializes data structures for the specified input image size
processProcesses existing tracks and adds tracks to drop list if they are too close to other tracks and considered less desirable
tracks- (Input) List of tracks. Not modified.
dropTracks- (Output) List of tracks that need to be dropped by the tracker
prunePointTrackConvenience function for creating a variant for PointTrack