This commit is contained in:
MBulli
2018-03-12 23:24:55 +01:00
parent b76b07b485
commit 9f098887db
5 changed files with 30 additions and 29 deletions

View File

@@ -5,12 +5,13 @@
%As the density estimation poses only a single step in the whole process, its computation needs to be as fast as possible.
% not taking to much time from the frame
Consider a set of two-dimensional samples with associated weights, \eg{} presumably generated from a particle filter system.
Consider a set of two-dimensional samples with associated weights, \eg{} generated from a particle filter system.
The overall process for bivariate data is described in Algorithm~\ref{alg:boxKDE}.
Assuming that the given $N$ samples are stored in a sequential list, the first step is to create a grid representation.
In order to efficiently construct the grid and to allocate the required memory the extrema of the samples need to be known in advance.
These limits might be given by the application, for example, the position of a pedestrian within a building is limited by the physical dimensions of the building.
In order to efficiently construct the grid and to allocate the required memory, the extrema of the samples need to be known in advance.
These limits might be given by the application.
For example, the position of a pedestrian within a building is limited by the physical dimensions of the building.
Such knowledge should be integrated into the system to avoid a linear search over the sample set, naturally reducing the computation time.
\begin{algorithm}[t]
@@ -54,7 +55,7 @@ Given the extreme values of the samples and grid sizes $G_1$ and $G_2$ defined b
As the number of grid points directly affects both, computation time and accuracy, a suitable grid should be as coarse as possible, but at the same time narrow enough to produce an estimate sufficiently fast with an acceptable approximation error.
If the extreme values are known in advanced, the computation of the grid is $\landau{N}$, otherwise an additional $\landau{N}$ search is required.
The grid is stored as an linear array in memory, thus its space complexity is $\landau{G_1\cdot G_2}$.
The grid is stored as a linear array in memory, thus its space complexity is $\landau{G_1\cdot G_2}$.
Next, the binned data is filtered with a Gaussian using the box filter approximation.
The box filter's width is derived by \eqref{eq:boxidealwidth} from the standard deviation of the approximated Gaussian, which is in turn equal to the bandwidth of the KDE.
@@ -69,7 +70,7 @@ If multivariate data is processed, the algorithm is easily extended due to its s
Each filter pass is computed in $\landau{G}$ operations, however, an additional memory buffer is required \cite{dspGuide1997}.
While the integer-sized box filter requires fewest operations, it causes a larger approximation error due to rounding errors.
Depending on the required accuracy, the extended box filter algorithm can further improve the estimation results, with only a small additional overhead \cite{gwosdek2011theoretical}.
Depending on the required accuracy, the extended box filter algorithm can further improve the estimation results with only a small additional overhead \cite{gwosdek2011theoretical}.
Due to its simple indexing scheme, the recursive box filter can easily be computed in parallel using SIMD operations and parallel computation cores.
Finally, the most likely state can be obtained from the filtered data, \ie{} from the estimated discrete density, by searching filtered data for its maximum value.