5.3.2.11. Struct kNN_data_t

5.3.2.11.1. Struct Documentation

struct kNN_data_t

Inner data structure required to compute associations between RoIs.

Public Members

float **distances

2D array of euclidean distances ( \([\texttt{\_max\_size}][\texttt{\_max\_size}]\)). \(y\) axis represents RoIs at \(t-1\) and \(x\) axis represents RoIs at \(t\). For instance, \(\texttt{distances}[i][j]\) represents the distance between \(RoI_{t-1}^i\) and \(RoI_{t}^j\). Note that sometime, for efficiency reasons, the implementation may choose to store squared euclidean distances instead of euclidean distances.

uint32_t **nearest

2D array of ranks ( \([\texttt{\_max\_size}][\texttt{\_max\_size}]\)). \(y\) axis represents RoIs at \(t-1\) and \(x\) axis represents RoIs at \(t\). For instance, \(\texttt{nearest}[i][j]\) represents the rank of \(RoI_{t-1}^i\) and \(RoI_{t}^j\). Rank = 1 means that \(i\) and \(j\) are the closest possible RoIs association, rank = 2 means that \(i\) and \(j\) are the second closest possible RoIs association, and so on. Rank = 0 means that \(i\) and \(j\) were not associated together (common reason is that they are too far from each others).

uint32_t *conflicts

1D array of conflicts ( \([\texttt{\_max\_size}]\)). A conflict happens when they are more than one \(RoI_{t-1}\) that is the closet to \(RoI_{t}^j\). \(\texttt{conflicts}[j]\) contains 0 if there is no conflict. \(\texttt{conflicts}[j]\) contains more than 0 if there are conflicts. For instance if \(RoI_{t-1}^{i1}\), \(RoI_{t-1}^{i2}\) and \(RoI_{t-1}^{i3}\) are all the closest to \(RoI_{t}^j\), then \(\texttt{conflicts}[j] = 2\). This buffer is allocated only if the FMDT_ENABLE_DEBUG macro is defined.

size_t _max_size

Maximum number of RoIs allocated in the previous fields.