Tekkotsu Homepage
Demos
Overview
Downloads
Dev. Resources
Reference
Credits

ShapeSensorModel Class Template Reference

#include <PFShapeLocalization.h>

Inheritance diagram for ShapeSensorModel:

List of all members.


Detailed Description

template<typename ParticleT>
class DualCoding::ShapeSensorModel< ParticleT >

this wraps the ParticleShapeEvaluator in a ParticleFilter::SensorModel so it can be used by the particle filter

The reason for separating ParticleShapeEvaluator and ShapeSensorModel? Partly so the fairly length evaluation code can go in the .cc file to avoid repeated recompilation, but also to allow inheritance (e.g. SLAMShapesParticleEvaluator) as a clean way to extend the evaluation code for particle sub-types. Ideally, I'd like to combine these classes.

Definition at line 69 of file PFShapeLocalization.h.


Public Types

typedef ParticleFilter
< ParticleT >
::SensorModel::index_t 
index_t
 convenience typedef
typedef ParticleFilter
< ParticleT >
::SensorModel::particle_collection 
particle_collection
 convenience typedef

Public Member Functions

 ShapeSensorModel (ShapeSpace &localShS, ShapeSpace &worldShS)
 constructor, the standard deviation on matches defaults to 60, but you can always reassign stdevSq directly
virtual void evaluate (particle_collection &particles, index_t &bestIndex)
 applies the ParticleShapeEvaluator across a collection of particles and tracks the best weight
ShapeSpacegetLocalShS () const
ShapeSpacegetWorldShS () const

Public Attributes

float stdevSq
 controls how much weight is given to "near-misses"

Protected Member Functions

float normpdf (float const distsq)

Protected Attributes

ShapeSpacelShS
 Local shape space.
ShapeSpacewShS
 World shape space.

Member Typedef Documentation

typedef ParticleFilter<ParticleT>::SensorModel::index_t index_t

convenience typedef

Definition at line 71 of file PFShapeLocalization.h.

typedef ParticleFilter<ParticleT>::SensorModel::particle_collection particle_collection

convenience typedef

Definition at line 72 of file PFShapeLocalization.h.


Constructor & Destructor Documentation

ShapeSensorModel ( ShapeSpace localShS,
ShapeSpace worldShS 
) [inline]

constructor, the standard deviation on matches defaults to 60, but you can always reassign stdevSq directly

Definition at line 75 of file PFShapeLocalization.h.


Member Function Documentation

virtual void evaluate ( particle_collection particles,
index_t bestIndex 
) [inline, virtual]

applies the ParticleShapeEvaluator across a collection of particles and tracks the best weight

Definition at line 83 of file PFShapeLocalization.h.

ShapeSpace& getLocalShS (  )  const [inline]

Definition at line 101 of file PFShapeLocalization.h.

ShapeSpace& getWorldShS (  )  const [inline]

Definition at line 102 of file PFShapeLocalization.h.

Referenced by PFShapeLocalization::displayParticles().

float normpdf ( float const   distsq  )  [inline, protected]

normalization isn't needed because the scale factor is constant across particles, and so doesn't matter for purposes of comparison between particles

Definition at line 111 of file PFShapeLocalization.h.

Referenced by ShapeSensorModel< LocalizationParticle >::evaluate().


Member Data Documentation

float stdevSq

controls how much weight is given to "near-misses"

Definition at line 80 of file PFShapeLocalization.h.

Referenced by ShapeSensorModel< LocalizationParticle >::evaluate(), and ShapeSensorModel< LocalizationParticle >::normpdf().

ShapeSpace& wShS [protected]

World shape space.

computes a (non-normalized) gaussian distribution

Definition at line 106 of file PFShapeLocalization.h.

Referenced by ShapeSensorModel< LocalizationParticle >::evaluate().


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

DualCoding 4.0
Generated Thu Nov 22 00:53:59 2007 by Doxygen 1.5.4