EmrysFilter 0.1.0
State estimation utilities in C++23 using Eigen
Loading...
Searching...
No Matches
Emrys::RbPointMassFilterUpdate< Scalar, Allocator > Class Template Reference

What a Rao-Blackwellized point-mass filter's update did, per live cell and in total. More...

#include <EmrysFilter/Filters/RbPointMassFilter.h>

Public Types

using ArrayType = Eigen::Map<Eigen::Array<Scalar, Eigen::Dynamic, 1> const>
 a per-cell array
using allocator_type = Allocator
 where the cells and per-cell arrays come from

Public Member Functions

 RbPointMassFilterUpdate (Allocator const &allocator={})
 An empty result whose cells and arrays come from allocator.
std::span< Eigen::Index const > cells () const
ArrayType logLikelihoods () const
ArrayType nis () const
Eigen::Index innovationSize () const
allocator_type get_allocator () const
Scalar logLikelihood () const

Public Attributes

bool accepted = false
 whether any cell accepted the measurement

Detailed Description

template<typename Scalar = double, typename Allocator = DefaultAllocator>
class Emrys::RbPointMassFilterUpdate< Scalar, Allocator >

What a Rao-Blackwellized point-mass filter's update did, per live cell and in total.

The arrays have one entry per cell that was alive when the update began, in the order of cells(). A cell whose update the policy rejected has log-likelihood \( -\infty \) and NIS NaN, and has been removed from the state.

The result owns its cells and arrays, in storage from Allocator. An update into a result (RbPointMassFilter::update(measurement, result)) refills that storage, so a result kept across steps allocates nothing once it has held as many cells (see Allocation).

Member Function Documentation

◆ cells()

template<typename Scalar = double, typename Allocator = DefaultAllocator>
std::span< Eigen::Index const > Emrys::RbPointMassFilterUpdate< Scalar, Allocator >::cells ( ) const
inlinenodiscard
Returns
the flat index of each cell updated

◆ get_allocator()

template<typename Scalar = double, typename Allocator = DefaultAllocator>
allocator_type Emrys::RbPointMassFilterUpdate< Scalar, Allocator >::get_allocator ( ) const
inlinenodiscard
Returns
the allocator the cells and per-cell arrays come from

◆ innovationSize()

template<typename Scalar = double, typename Allocator = DefaultAllocator>
Eigen::Index Emrys::RbPointMassFilterUpdate< Scalar, Allocator >::innovationSize ( ) const
inlinenodiscard
Returns
the difference dimension of the innovation

◆ logLikelihood()

template<typename Scalar = double, typename Allocator = DefaultAllocator>
Scalar Emrys::RbPointMassFilterUpdate< Scalar, Allocator >::logLikelihood ( ) const
inlinenodiscard
Returns
\( \log p(z) = \log \sum_c P(c) \, p(z \mid c) \)

◆ logLikelihoods()

template<typename Scalar = double, typename Allocator = DefaultAllocator>
ArrayType Emrys::RbPointMassFilterUpdate< Scalar, Allocator >::logLikelihoods ( ) const
inlinenodiscard
Returns
\( \log p(z \mid c) \) per cell

◆ nis()

template<typename Scalar = double, typename Allocator = DefaultAllocator>
ArrayType Emrys::RbPointMassFilterUpdate< Scalar, Allocator >::nis ( ) const
inlinenodiscard
Returns
each cell's NIS; with mixture noise, its most probable branch's, and with a hybrid per cell, its most probable mode's after the update

The documentation for this class was generated from the following file: