#include <GridIndexLookup.h>
Public Member Functions | |
| void | ComputeOffsets (LocalizedLaserScan *pScan, kt_double angleCenter, kt_double angleOffset, kt_double angleResolution) |
| const List< kt_double > & | GetAngles () const |
| const LookupArray * | GetLookupArray (kt_int32u index) const |
| GridIndexLookup (Grid< T > *pGrid) | |
| virtual | ~GridIndexLookup () |
Private Member Functions | |
| void | ComputeOffsets (kt_int32u angleIndex, kt_double angle, const Pose2List &rLocalPoints) |
| void | DestroyArrays () |
| void | SetSize (kt_int32u size) |
Private Attributes | |
| List< kt_double > | m_Angles |
| kt_int32u | m_Capacity |
| Grid< T > * | m_pGrid |
| LookupArray ** | m_ppLookupArray |
| kt_int32u | m_Size |
Create lookup tables for point readings at varying angles in grid. For each angle, grid indexes are calculated for each point reading. This is to speed up finding best angle/position for a localized laser scan
Used heavily in mapper and localizer.
In the localizer, this is a huge speed up for calculating possible positions. For each particle, a probability is calculated. The laser scan is the same, but all grid indexes at all possible angles are calculated. So when calculating the particle probability at a specific angle, the index table is used to look up probabilities in the probability grid.
Definition at line 136 of file GridIndexLookup.h.
|
inline |
Construct a GridIndexLookup with a grid
| pGrid | grid pointer |
Definition at line 143 of file GridIndexLookup.h.
|
inlinevirtual |
Destructor
Definition at line 154 of file GridIndexLookup.h.
|
inline |
Computes lookup table of the points of the given scan for the given angular space
| pScan | scan |
| angleCenter | angle at center |
| angleOffset | computes lookup arrays for the angles within this offset around angleCenter |
| angleResolution | how fine a granularity to compute lookup arrays in the angular space |
Definition at line 188 of file GridIndexLookup.h.
|
inlineprivate |
Computes lookup value of points for given angle
| angleIndex | angle index |
| angle | angle |
| rLocalPoints | points in local coordinates |
Definition at line 231 of file GridIndexLookup.h.
|
inlineprivate |
Delete the arrays
Definition at line 301 of file GridIndexLookup.h.
|
inline |
|
inline |
Gets the lookup array for a particular angle index
| index | angle index |
Definition at line 165 of file GridIndexLookup.h.
|
inlineprivate |
Sets size of lookup table (resize if not big enough)
| size | new size |
Definition at line 274 of file GridIndexLookup.h.
|
private |
Definition at line 321 of file GridIndexLookup.h.
|
private |
Definition at line 315 of file GridIndexLookup.h.
|
private |
Definition at line 313 of file GridIndexLookup.h.
|
private |
Definition at line 318 of file GridIndexLookup.h.
|
private |
Definition at line 316 of file GridIndexLookup.h.