main Content

Trackertomht

multi-hypothesis, multi-sensor, multi-object tracker

Description

TrackertomhtSystem object™ is a multi-hypothesis tracker capable of processing detections of many targets from multiple sensors. The tracker initializes, confirms, predicts, corrects, and deletes tracks. Inputs to the tracker are detection reports generated by对象电视,,,,fusionRadarSensor,,,,一世rSensor,,,,orsonarSensor对象。这tracker estimates the state vector and state vector covariance matrix for each track. The tracker assigns detections based on a track-oriented, multi-hypothesis approach. Each detection is assigned to at least one track. If the detection cannot be assigned to any track, the tracker creates a track.

Any new track starts in atentativestate. If enough detections are assigned to a tentative track, its status changes toconfirmed。If the detection already has a known classification (theObjectClassIDfield of the returned track is nonzero), that track is confirmed immediately. When a track is confirmed, the multi-object tracker considers the track to represent a physical object. If detections are not assigned to the track within a specifiable number of updates, the track is deleted. For an overview of how the tracker functions, seeAlgorithms

To track objects using the multi-hypothesis tracker:

  1. Create theTrackertomht目的and set its properties.

  2. Call the object with arguments, as if it were a function.

To learn more about how System objects work, seeWhat Are System Objects?

Creation

Description

tracker= TrackerTomhtcreates aTrackertomhtSystem object with default property values.

例子

tracker= TrackerTomht((name,Valuesets properties for the multi-object tracker using one or more name-value pairs. For example,Trackertomht((“ filterInitializationfcn',,,,@initcvukf,'MaxNumTracks',100)creates a multi-object tracker that uses a constant-velocity, unscented Kalman filter and allows a maximum of 100 tracks. Enclose each property name in quotes.

Properties

expand all

Unless otherwise indicated, properties arenontunable,,,,which means you cannot change their values after calling the object. Objects lock when you call them, and thereleasefunction unlocks them.

If a property istunable,您可以随时更改其价值。

For more information on changing property values, see使用系统对象在MATLAB中的系统设计

Unique tracker identifier, specified as a nonnegative integer. This property is used as theSourceIndex在跟踪器输出中,并区分来自多跟踪器系统中不同跟踪器的跟踪。您必须将此属性指定为正整数,以将轨道输出作为轨道定影器的输入。

Example:1

Filter initialization function, specified as a function handle or as a character vector containing the name of a filter initialization function. The tracker uses a filter initialization function when creating new tracks.

Sensor Fusion and Tracking Toolbox™ supplies many initialization functions that you can use to specifyFilterInitializationFcn

Initialization Function Function Definition
一世nitcvabf Initialize constant-velocity alpha-beta filter
一世nitcaabf 初始化恒定加速α-beta滤波器
一世nitcvekf 初始化常数扩展的卡尔曼滤波器。
initcackf Initialize constant-acceleration cubature filter.
一世nitctckf 初始化恒定速率的立方体过滤器。
initcvckf 初始化恒定速度立方体过滤器。
一世nitcapf Initialize constant-acceleration particle filter.
一世nitctpf Initialize constant-turn-rate particle filter.
一世nitcvpf Initialize constant-velocity particle filter.
一世nitcvkf 初始化常数线性卡尔曼滤波器。
一世nitcvukf Initialize constant-velocity unscented Kalman filter.
initcaekf Initialize constant-acceleration extended Kalman filter.
一世nitcakf Initialize constant-acceleration linear Kalman filter.
一世nitcaukf 初始化恒定加速器的无气味卡尔曼滤波器。
一世nitctekf Initialize constant-turn-rate extended Kalman filter.
一世nitctukf Initialize constant-turn-rate unscented Kalman filter.
一世nitcvmscekf Initialize constant-velocity modified spherical coordinates extended Kalman filter.
一世nitrpekf Initialize constant-velocity range-parametrized extended Kalman filter.
一世nitapekf Initialize constant-velocity angle-parametrized extended Kalman filter.
一世nitekfimm Initialize tracking IMM filter.
一世nitsingerekf 初始化歌手加速度扩展Kalman滤波器。

You can also write your own initialization function. The function must have the following syntax:

filter = filterInitializationFcn(detection)
这一世nput to this function is a detection report like those created by对象电视。这output of this function must be a filter object:trackingKF,,,,trackingEKF,,,,trackingUKF,,,,trackingCKF,,,,trackingPF,,,,trackingMSCEKF,,,,trackingGSF,,,,trackingIMM,,,,ortrackingABF

To guide you in writing this function, you can examine the details of the supplied functions from within MATLAB®。For example:

type一世nitcvekf

Data Types:function_handle|char

maximum number of tracks that the tracker can maintain, specified as a positive integer.

Data Types:single|double

maximum number of sensors that can be connected to the tracker, specified as a positive integer.maxNumSensors必须大于或等于最大的value ofSensorIndex在用于更新跟踪器的所有检测中找到。SensorIndex一世s a property of an对象电视目的。这maxNumSensorsproperty determines how many sets ofObjectAttributesfields each output track can have.

Data Types:single|double

跟踪器可以作为输入(指定为正整数)的最大检测数量。

Data Types:single|double

Handle out-of-sequence measurement (OOSM), specified as'Terminate'or'Neglect'。Each detection has a timestamp associated with it,td,,,,and the tracker has it own timestamp,tt,在每个呼叫中​​进行更新。跟踪器认为测量是一个OOSMtd<tt

When the property is specified as

  • 'Terminate'-这tracker stops running when it encounters any out-of-sequence measurements.

  • 'Neglect'-这tracker neglects any out-of-sequence measurements and continue to run.

To simulate out-of-sequence detections, use对象电视Delay

可调:Yes

Parameters of the track state reference frame, specified as a structure or a structure array. The tracker passes itsStateParameters属性值StateParametersproperty of the generated tracks. You can use these parameters to define the reference frame in which the track is reported or other desirable attributes of the generated tracks.

For example, you can use the following structure to define a rectangular reference frame whose origin position is at[[10100]meters and whose origin velocity is [2 -2 0] meters per second with respect to the scenario frame.

Field Name Value
Frame "Rectangular"
Position [[10100]
Velocity [[2-2 0]

可调:Yes

Data Types:struct

在歧义性的情况下,轨道维持的最大假设数量,指定为正整数。较大的值会增加计算负载。

Example:10

Data Types:single|double

Set the maximum number of track branches (hypotheses) allowed for each track. Larger values increase the computational load.

Data Types:single|double

maximum number of scans maintained in the branch history, specified as a positive integer. The number of track history scans is typically from 2 through 6. Larger values increase the computational load.

Example:6

Data Types:single|double

Detection assignment threshold, specified as a positive scalar, an 1-by-3 vector of non-decreasing positive values, [C1,,,,C2,,,,C3], or an1-by-4 vector of non-decreasing positive values, [C1,,,,C2,,,,C3,,,,C4]. If specified as a scalar, the specified value,val,,,,will be expanded to [0.3,0.7,1,Inf]*val。If specified as [C1,,,,C2,,,,C3], it will be expanded as [C1,,,,C2,,,,C3,,,,Inf].

这thresholds control (1) the assignment of a detection to a track, (2) the creation of a new branch from a detection, and (3) the creation of a new branch from an unassigned track. The threshold values must satisfy:C1<=C2<=C3<=C4

  • C1defines a distance such that if a track has an assigned detection with lower distance thanC1,,,,the track is no longer considered unassigned and does not create an unassigned track branch.

  • C2defines a distance that if a detection has been assigned to a track with lower distance thanC2,,,,the detection is no longer considered unassigned and does not create a new track branch.

  • C3定义将检测分配到轨道的最大距离。

  • C4defines combinations of track and detection for which an accurate normalized cost calculation is performed. Initially, the tracker executes a coarse estimation for the normalized distance between all the tracks and detections. The tracker only calculates the accurate normalized distance for the combinations whose coarse normalized distance is less thanC4

  • Increase the value ofC3如果有检测应分配给轨道但没有分配。如果有检测到分配给轨道,则降低值不应分配给(太远)。

  • 增加值C1andC2帮助控制创建的轨道分支的数量。但是,这样做会减少每个轨道的分支数(假设)的数量。

  • Increase the value ofC4如果有跟踪和检测t的组合hat should be calculated for assignment but are not. Decrease it if cost calculation takes too much time.

笔记

If the value ofC4一世s finite, the state transition function and measurement function, specified in the tracking filter used in the tracker, must be able to take anm-by-n矩阵of states as input and outputn预测的国家和n分别测量。m是状态的大小。n,,,,the number of states, is an arbitrary nonnegative integer.

Data Types:single|double

m一世nimum score required to confirm a track, specified as a positive scalar. Any track with a score higher than this threshold is confirmed.

Example:12

Data Types:single|double

这maximum score drop before a track is deleted, specified as a scalar. Any track with a score that falls by more than this parameter from the maximum score is deleted. Deletion threshold is affected by the probability of false alarm.

Example:12

Data Types:single|double

Probability of detection, specified as a positive scalar between 0 and 1. This property is used to compute track score.

Example:0。5

Data Types:single|double

这probability of false alarm, specified as a scalar. This property is used to compute track score.

Example:1e-5

Data Types:single|double

这rate of new tracks per unit volume, specified as a positive scalar. The rate of new tracks is used in calculating the track score during track initialization.

Example:2。5

Data Types:single|double

传感器测量箱的体积,指定为正标量。例如,如果雷达产生4D测量,包括方位角,高程,范围和范围速率,则4-D体积由雷达角束宽度定义。在初始化和更新轨道时,使用音量来计算轨道分数。

Example:1。5

Data Types:single|double

m一世nimum probability required to keep a track, specified as a positive scalar less than one. Any track with lower probability is pruned. Typical values are 0.001 to 0.005.

Example:。003

Data Types:single|double

n-scan pruning method, specified as'None'or'假设'。In N-scan pruning, branches that belong to the same track are pruned (deleted) if, in the N-scans history, they contradict the most likely branch for the same track. The most-likely branch is defined in one of two ways:

  • 'None'– No N-scan pruning is performed.

  • '假设'- 选择的分支是最可能的假设。

Example:'假设'

Enable a cost matrix, specified asfalseortrue。Iftrue,您可以在调用对象时提供分配成本矩阵作为输入参数。

Data Types:逻辑

Enable the input of detectable branch IDs at each object update, specified asfalseortrue。Set this property totrue一世f you want to provide a list of detectable branch IDs. This list tells the tracker of all branches that the sensors are expected to detect and, optionally, the probability of detection for each branch.

Data Types:逻辑

Track output method, specified as“轨道”,,,,'假设',,,,or'Clusters'

  • “轨道”– Output the centroid of each track based on its track branches.

  • '假设'– Output branches that are in certain hypotheses. If you choose this option, list the hypotheses to output using theHypothesesToOutput财产。

  • 'Clusters'– Output the centroid of each cluster. Similar to“轨道”output, but includes all tracks within a cluster.

Data Types:char

Indices of hypotheses to output, specified as an array of positive integers. The indices must all be less than or equal to the maximum number of hypotheses provided by the tracker.

可调:Yes

Data Types:single|double

This property is read-only.

数量的跟踪维护的the tracker, returned as a nonnegative integer.

Data Types:double

This property is read-only.

number of confirmed tracks, returned as a nonnegative integer. If the确认field of an output track structure istrue,,,,the track is confirmed.

Data Types:double

Usage

To process detections and update tracks, call the tracker with arguments, as if it were a function (described here).

Description

confirmedTracks= tracker(detections,,,,t一世mereturns a list of confirmed tracks that are updated from a list of detections,detections,,,,at the update time,t一世me。Confirmed tracks are corrected and predicted to the update time.

confirmedTracks= tracker(detections,,,,t一世me,,,,Costmatrixalso specifies a cost matrix,Costmatrix

To enable this syntax, set thehascostmatrixInput财产为true

confirmedTracks= tracker(___,,,,可检测的灌木丛also specifies a list of expected detectable branches,可检测的灌木丛

To enable this syntax, set thehasdetectablebranchidsinput财产为true

[[confirmedTracks,,,,tentativeTracks,,,,allTracks] = tracker(___还返回暂定曲目的列表,tentativeTracks,,,,and a list of all tracks,allTracks

[[confirmedTracks,,,,tentativeTracks,,,,allTracks,,,,analysisInformation] = tracker(___also returns information,analysisInformation,,,,useful for track analysis.

Input Arguments

expand all

Detection list, specified as a cell array of对象电视对象。这Time每个的属性价值对象电视目的must be less than or equal to the current update time,t一世me,,,,and greater than the previous time value used to update the tracker. Also, theTime不同的差异对象电视对象一世n the cell array do not need to be equal.

Time of update, specified as a scalar. The tracker updates all tracks to this time. Units are in seconds.

t一世me必须大于或等于最大的Timeproperty value of the对象电视对象一世n the inputdetectionslist.t一世me必须增加的价值与每个更新交易吗cker.

Data Types:single|double

Cost matrix, specified as a real-valuedn-by-m矩阵,,,,wheren一世s the number of branches, andm一世s the number of current detections. The cost matrix rows must be in the same order as the list of branches. The columns must be in the same order as the list of detections. Obtain the correct order of the list of branches using thegetBranches目的function. Matrix columns correspond to the detections.

在对象的第一个更新或跟踪器没有以前的轨道时,指定成本矩阵的大小为[[0,,,,numDetections]。笔记that the cost must be calculated so that lower costs indicate a higher likelihood of assigning a detection to a track. To prevent certain detections from being assigned to certain tracks, set the appropriate cost matrix entry toInf

Dependencies

To enable this argument, set thehascostmatrixInput财产为true

Data Types:double|single

Detectable branch IDs, specified as a real-valuedm-b-1矢量orm-by-2 matrix. Detectable branches are branches that the sensors expect to detect. The first column of the matrix contains a list of branch IDs of tracks reported in thebranchid轨道输出参数的字段。第二列包含分支的检测概率。传感器可以报告检测概率,但如果未报告,则从DetectionProbability财产。

分支es whose identifiers are not included in可检测的灌木丛被认为是无法检测的。轨道删除逻辑并未将缺乏检测视为用于分支删除目的的“错过”。

Dependencies

要启用此输入参数,请设置HasDetectableBranchIDs财产为true

Data Types:single|double

Output Arguments

expand all

Confirmed tracks, returned as an array of目的Track对象一世n MATLAB, and returned as an array of structures in code generation. In code generation, the field names of the returned structure are same with the property names of目的Track

A track is confirmed if it satisfies the confirmation threshold specified in theConfirmationThreshold财产。In that case, the确认property of the object or field of the structure istrue

Data Types:struct|目的

Tentative tracks, returned as an array of目的Track对象一世n MATLAB, and returned as an array of structures in code generation. In code generation, the field names of the returned structure are same with the property names of目的Track

A track is tentative if it does not satisfy the confirmation threshold specified in theConfirmationThreshold财产。In that case, the确认property of the object or field of the structure isfalse

Data Types:struct|目的

所有曲目,返回为目的Track对象一世n MATLAB, and returned as an array of structures in code generation. In code generation, the field names of the returned structure are same with the property names of目的Track。All tracks consists of confirmed and tentative tracks.

Data Types:struct|目的

Additional information for analyzing track updates, returned as a structure. The fields of this structure are:

Field Description
OOSMDetectionIndices

Indices of out-of-sequence measurements

BranchIDSATSATSTEPBEGINNING

分支IDs when update began.

CostMatrix

Cost of assignment matrix.

作业

返回的作业assignTOMHT

UnassignedTracks

IDs of unassigned branches returned from the tracker

UnassignedDetections

Indices of unassigned detections in thedetections一世nput.

InitialBranchHistory

分支history after branching and before pruning.

InitialBranchScores

分支scores before pruning.

KeptBranchHistory

分支history after initial pruning.

KeptBranchScores

分支scores after initial pruning.

Clusters

逻辑阵列分支映射到集群。分支es belong in the same cluster if they share detections in their history or belong to the same track, either directly or through other branches. Such branches are incompatible.

TrackIncompatibility

分支一世ncompatibility matrix. The((一世,,,,jelement is true if the一世-th andj-th branches have shared detections in their history or belong to the same track.

GlobalHypotheses

Logical matrix mapping branches to global hypotheses. Compatible branches can belong in the same hypotheses.

GlobalHypScores Total score of global hypotheses.
PrunedBranches

Logical array of branches that thepruneTrackBranchesfunction determines to be pruned.

GlobalBranchProbabilities

Global probability of each branch existing in the global hypotheses.

分支esDeletedByPruning

由跟踪器删除的分支。

分支IDsAtStepEnd

更新结束时的分支ID。

Data Types:struct

Object Functions

要使用对象函数,请将系统对象指定为第一个输入参数。例如,释放名称的系统对象的系统资源obj,,,,use this syntax:

release(obj)

expand all

getTrackFilterProperties Obtain track filter properties
setTrackFilterProperties Set track filter properties
getBranches Lists track branches
predictTrackToTime Predict track state
一世nitializeTrack 初始化新曲目
deleteTrack Delete existing track
初始尺寸 初始化新曲目branch
deleteBranch Delete existing track branch
exportToSimulink 导出跟踪器或跟踪定影器到Simulink模型万博1manbetx
release 释放资源并允许更改System object属性值和输入特征
reset Reset internal states ofSystem object
一世sLocked Determine ifSystem object一世s in use
clone Create duplicateSystem object

Examples

collapse all

Create theTrackertomhtSystem object with a constant-velocity Kalman filter initialization function,一世nitcvkf

tracker = trackerTOMHT(“ filterInitializationfcn',@initcvkf,。。。“确认示波”,,,,20,,,,。。。'DeletionThreshold',-7,。。。'MaxNumHypotheses',,,,10);

Update the tracker with two detections having nonzeroObjectClassID。检测立即创建欺诈firmed tracks.

detections = {objectDetection(1,[10;0],'SensorIndex',,,,1,,,,。。。'ObjectClassID',,,,5,,,,“ objectattributes',,,,{struct('ID',,,,1)});。。。对象电视((1,,,,[[0;10],'SensorIndex',,,,1,,,,。。。'ObjectClassID',,,,2,,,,“ objectattributes',,,,{struct('ID',,,,2)})}; time = 2; tracks = tracker(detections,time);

Find and display the positions and velocities.

positionSelector = [1 0 0 0; 0 0 1 0]; velocitySelector = [0 1 0 0; 0 0 0 1]; positions = getTrackPositions(tracks,positionSelector)
positions =2×210。00000010。0000
velocities = getTrackVelocities(tracks,velocitySelector)
velocities =2×20 0 0 0

Algorithms

expand all

References

[[1] Werthmann, J. R.. "Step-by-Step Description of a Computationally Efficient Version of Multiple Hypothesis Tracking." InInternational Society for Optics and Photonics,,,,Vol. 1698, pp. 228-301, 1992.

[[2] Blackman, S., and R. Popoli.Design and Analysis of Modern Tracking Systems.Artech House Radar图书馆,波士顿,1999年。

Extended Capabilities

版本历史记录

在R2018B中引入