Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
| usage:tracking_algorithm [2019/08/07 18:14] – [High-fidelity linking and gap closure] pseudomoaner | usage:tracking_algorithm [2019/08/19 15:30] (current) – [Appendix: Normalisation of correlated displacement spaces] pseudomoaner | ||
|---|---|---|---|
| Line 8: | Line 8: | ||
| ===== A note on notation ===== | ===== A note on notation ===== | ||
| + | Throughout this page, the term `feature' | ||
| ===== The challenge of tracking ===== | ===== The challenge of tracking ===== | ||
| Line 36: | Line 37: | ||
| < | < | ||
| - | FAST adopts a two pronged approach to tracking (<imgref Fig2>). The first prong is to make all features directly comparable by shifting and rescaling $\mathbf{f}$ to generate the **normalised feature space** $\hat{\mathbf{f}}_t$. The corresponding | + | FAST adopts a two pronged approach to tracking (<imgref Fig2>). The first prong is to make all features directly comparable by shifting and rescaling $\mathbf{f}$ to generate the **normalised feature space** $\hat{\mathbf{f}}_t$. The corresponding |
| The second prong is to adaptively vary the detection threshold to account for variations in system density and feature usefulness. To assist in this second task, the concept of feature **reliability** is introduced. This is a joint measure of the noise associated with each feature and the range of values it can take, and represents the usefulness of each feature for distinguishing different link options in the normalised displacement space. Reliability can be combined across features to give a single **trackability** score for each timepoint. This is a user-directed heuristic measure of dataset quality which can be used for quality control and automated purging of low-quality sections of tracking datasets. | The second prong is to adaptively vary the detection threshold to account for variations in system density and feature usefulness. To assist in this second task, the concept of feature **reliability** is introduced. This is a joint measure of the noise associated with each feature and the range of values it can take, and represents the usefulness of each feature for distinguishing different link options in the normalised displacement space. Reliability can be combined across features to give a single **trackability** score for each timepoint. This is a user-directed heuristic measure of dataset quality which can be used for quality control and automated purging of low-quality sections of tracking datasets. | ||
| Line 42: | Line 43: | ||
| At the core of the FAST tracking algorithm is a machine learning protocol that automatically determines the necessary dataset statistics. A training set of object links is first created using a high stringency, classical tracking algorithm. This training set is then used to estimate the reliability of each feature and the trackability of the dataset, as well as the values of $\mathbf{\mu}_t$ and $\mathbf{\Sigma}_t$. These statistics are then used to generate $\Delta \hat{\mathbf{f}}_t$ and to calculate the adaptive threshold for each timepoint. | At the core of the FAST tracking algorithm is a machine learning protocol that automatically determines the necessary dataset statistics. A training set of object links is first created using a high stringency, classical tracking algorithm. This training set is then used to estimate the reliability of each feature and the trackability of the dataset, as well as the values of $\mathbf{\mu}_t$ and $\mathbf{\Sigma}_t$. These statistics are then used to generate $\Delta \hat{\mathbf{f}}_t$ and to calculate the adaptive threshold for each timepoint. | ||
| - | For simplicity, I will here limit the description of the tracking algorithm to the case that $\mathbf{\Sigma}_t$ is diagonal, //i.e.// that all features are independent from each other. Extension of the algorithm to the case where correlations exist between features is fairly simple, and is provided in the final section. This is the version of the algorithm employed by the full version of FAST. However, as we will see, the assumption of feature independence makes the role of each mathematical operation easier to understand. | + | For simplicity, I will here limit the description of the tracking algorithm to the case that $\mathbf{\Sigma}_t$ is diagonal, //i.e.// that all features are independent from each other. Extension of the algorithm to the case where correlations exist between features is fairly simple, and is provided in the [[usage: |
| ===== Collection of the training dataset ===== | ===== Collection of the training dataset ===== | ||
| Line 100: | Line 101: | ||
| ==== The problem of link ambiguity ==== | ==== The problem of link ambiguity ==== | ||
| - | < | + | < |
| In FAST, $\beta_t$ is adaptively chosen to account for the problem of **link ambiguity**. As an informal introduction to this problem, consider the system in <imgref Fig3>a. Two objects are moving through a normalised feature space between frame $t$ and $t+1$ - our task, as usual, is to assign links between the two frames. The best guess we can possibly make based on the information available to us is to link the nearest neighbours in this feature space. However, in reality, this assignment is incorrect. A good tracking algorithm should therefore be able to detect instances where such ambiguous assignments might occur, and suppress linking in these cases. (Note that these ambiguous links are distinct from the false links caused by mis-segmentations etc. as discussed in [[usage: | In FAST, $\beta_t$ is adaptively chosen to account for the problem of **link ambiguity**. As an informal introduction to this problem, consider the system in <imgref Fig3>a. Two objects are moving through a normalised feature space between frame $t$ and $t+1$ - our task, as usual, is to assign links between the two frames. The best guess we can possibly make based on the information available to us is to link the nearest neighbours in this feature space. However, in reality, this assignment is incorrect. A good tracking algorithm should therefore be able to detect instances where such ambiguous assignments might occur, and suppress linking in these cases. (Note that these ambiguous links are distinct from the false links caused by mis-segmentations etc. as discussed in [[usage: | ||
| Line 114: | Line 115: | ||
| Reliability is a scale-invariant and dimensionless statistic, allowing it to be directly compared between different features. Note that division by $\sigma_{t, | Reliability is a scale-invariant and dimensionless statistic, allowing it to be directly compared between different features. Note that division by $\sigma_{t, | ||
| - | As a loose conceptualisation, | + | As a loose conceptualisation, |
| As increasing numbers of features are added, the feature space is partitioned into more and more regions of ambiguity. To illustrate this effect, <imgref Fig3>b shows the normalised $x$-$y$ feature space $\hat{\mathbf{f}}$ derived from the feature space shown in <imgref Fig1>. The initially square domain has been stretched into a rectangle by the lower variability of movement in the $x$-direction than in the $y$-direction, | As increasing numbers of features are added, the feature space is partitioned into more and more regions of ambiguity. To illustrate this effect, <imgref Fig3>b shows the normalised $x$-$y$ feature space $\hat{\mathbf{f}}$ derived from the feature space shown in <imgref Fig1>. The initially square domain has been stretched into a rectangle by the lower variability of movement in the $x$-direction than in the $y$-direction, | ||
| Line 140: | Line 141: | ||
| where $\Gamma()$ indicates the gamma function. To assign $\beta_t$, the user defines a target ambiguous assignment probability $p$. This is then transformed to $\beta_t$ through the above equation for each timepoint. Note that $\beta_t$ is calculated according to the metric of the normalised feature space, meaning it is not reliant upon the ad-hoc definition of `regions of ambiguity' | where $\Gamma()$ indicates the gamma function. To assign $\beta_t$, the user defines a target ambiguous assignment probability $p$. This is then transformed to $\beta_t$ through the above equation for each timepoint. Note that $\beta_t$ is calculated according to the metric of the normalised feature space, meaning it is not reliant upon the ad-hoc definition of `regions of ambiguity' | ||
| - | Defining $\beta_t$ in this way allows us to automatically change the stringency of the tracking algorithm according to the properties of the dataset. When a system is at low density or the degree of movement is small, ambiguous links will occur fairly rarely and link assignment need not be very stringent. At the other extreme, with high levels of system noise or high system density, ambiguous links will be common. Links should therefore only be assigned when the evidence for object identity between frames is extremely strong, //i.e.// $\beta_t$ should be made extremely | + | Defining $\beta_t$ in this way allows us to automatically change the stringency of the tracking algorithm according to the properties of the dataset. When a system is at low density or the degree of movement is small, ambiguous links will occur fairly rarely and link assignment need not be very stringent. At the other extreme, with high levels of system noise or high system density, ambiguous links will be common. Links should therefore only be assigned when the evidence for object identity between frames is extremely strong, //i.e.// $\beta_t$ should be made extremely |
| ===== High-fidelity linking and gap closure ===== | ===== High-fidelity linking and gap closure ===== | ||
| Line 147: | Line 148: | ||
| \begin{equation} | \begin{equation} | ||
| - | \hat{Q}_{i, | + | \hat{Q}_{i, |
| \end{equation} | \end{equation} | ||
| Line 158: | Line 159: | ||
| ===== Division tracking ===== | ===== Division tracking ===== | ||
| - | The tracking algorithm described in the previous sections can easily be adapted to permit detection of cellular divisions. Divisions are events that are associated with large but predictable jumps in feature space from mother to daughter cells. For example, in the case of the division of \textit{P. aeruginosa}, division typically causes area and length to halve, while the position of daughter cells can be inferred from mother cell length and orientation. | + | The tracking algorithm described in the previous sections can easily be adapted to permit detection of cellular divisions. Divisions are events that are associated with large but predictable jumps in feature space from mother to daughter cells. For example, in the case of the division of //P. aeruginosa//, division typically causes area and length to halve, while the position of daughter cells can be inferred from mother cell length and orientation. |
| - | To initialise the division tracking algorithm following the feature tracking algorithm, separate versions of $\bm{f}$ are constructed from the feature vectors associated with the beginning and ends of \mccorrect{those tracks constructed in section} \ref{sec: | + | To initialise the division tracking algorithm following the feature tracking algorithm, separate versions of $\mathbf{f}$ are constructed from the feature vectors associated with the beginning and ends of those tracks constructed in the [[usage: |
| + | |||
| + | ===== Appendix: Normalisation of correlated displacement spaces ===== | ||
| + | |||
| + | From the equation at the end of the [[usage: | ||
| + | |||
| + | \begin{equation} | ||
| + | \mathbf{f}_{t+1} = \mathbf{f}_{t} + \mathbf{w}_{t}, | ||
| + | \end{equation} | ||
| + | |||
| + | where $\mathbf{w}_t$ indicates a random vector drawn from the distribution $\mathcal{N}(\mathbf{\mu}_t, | ||
| + | |||
| + | $\mathbf{\mu}_t$ can be calculated from the training feature displacement set $\mathbf{f}_{t, | ||
| + | |||
| + | \begin{equation} | ||
| + | \boldsymbol{\Sigma}_t = \frac{1}{n_t-1} \sum_{i=1}^{n_t} (\Delta \mathbf{f}_{t, | ||
| + | \end{equation} | ||
| + | |||
| + | |||
| + | for each link in the training dataset, $i$ to $n_t$. | ||
| + | |||
| + | To generate the normalised feature space $\hat{\mathbf{f}}_t$, | ||
| + | |||
| + | \begin{equation} | ||
| + | \mathbf{\Sigma} = \mathbf{U}\mathbf{\Lambda}\mathbf{U}^{-1}. | ||
| + | \end{equation} | ||
| + | |||
| + | Noting that $\mathbf{\Lambda} = \mathbf{\Lambda}^{\frac{1}{2}}\mathbf{I}\mathbf{\Lambda}^{\frac{1}{2}}$ and that $\mathbf{U}^{-1} = \mathbf{U}^\intercal$, | ||
| + | |||
| + | \begin{equation} | ||
| + | \mathbf{B} = \mathbf{\Lambda}^{\frac{1}{2}}\mathbf{U}^\intercal. | ||
| + | \end{equation} | ||
| + | |||
| + | The normalised feature space is then given as: | ||
| + | |||
| + | \begin{equation} | ||
| + | \hat{\mathbf{f}}_{t} = \mathbf{B}_t\mathbf{f}_{t}, | ||
| + | \end{equation} | ||
| + | |||
| + | \begin{equation} | ||
| + | \hat{\mathbf{f}}_{t+1} = \mathbf{B}_t(\mathbf{f}_{t + 1} - \mathbf{\mu}_t). | ||
| + | \end{equation} | ||
| + | |||
| + | Feature reliability is not easy to define in this new space, as $\mathbf{B}_t$ will not in general preserve the orientation of the feature axes. This contrasts to the case when $\mathbf{\Sigma}_t$ was diagonal, where $\mathbf{B}_t$ scaled the feature space parallel to each feature axis. However, the volume of the space can still be defined as the (hyper)volume of the $\Phi$-parallelotope corresponding to the transformed feature domain, //i.e.// the parallelotope with corners at positions $\mathbf{p}_t = \mathbf{B}_t\mathbf{E}_t$ where $\mathbf{E}_t$ is the matrix with diagonal elements that are the extent $e_{t, | ||
| + | |||
| + | \begin{equation} | ||
| + | d_t = \frac{n_t}{-\det(\mathbf{p}_t)}. | ||
| + | \end{equation} | ||
| + | |||
| + | The trackability $k_t$ and ambiguous link assignment probability $p$ are then calculated as for the uncorrelated case. | ||