Provides an Partial Index Table to be used for nearest neighbor search.
More...
#include <PartialIndexTable.hpp>
|
|
bool | operator< (const Dimension &a, const Dimension &b) |
| | Compares which of two dimensions is the best for the table.
|
| |
template<class T, class Cell = std::list<T>>
class rwlibs::pathplanners::prm::PartialIndexTable< T, Cell >
Provides an Partial Index Table to be used for nearest neighbor search.
This class is implemented as a helper for the PRMPlanner.
◆ PartialIndexTable()
Constructs Partial Index Table.
- Parameters
-
| bounds | [in] Bounds of the space to partially index |
| weights | [in] The weights for the WeightedEuclideanMetric used determining whether two nodes are neighbors |
| r | [in] The distance where two nodes are considered neighbors |
| dims | [in] The number of dimensions of the table. dims has to be within [1, dof] |
◆ addNode()
Adds a node to the table.
- Parameters
-
| node | [in] Node to add |
| q | [in] Configuration of node |
◆ removeNode()
| void removeNode |
( |
const T & |
node, |
|
|
const rw::math::Q & |
q |
|
) |
| |
|
inline |
Removes node from the table.
- Parameters
-
| node | [in] Node to remove |
| q | [in] Configuration associated with the node. Used to find the table entry containing the node. |
◆ searchNeighbors() [1/2]
| std::list<T> searchNeighbors |
( |
const rw::math::Q & |
q | ) |
const |
|
inline |
Searches for all potential neighbors.
The potential neighbor is those within the cell associated with q and all neighboring cells.
To find the true neighbors one has to run through the content of the list and make an exact match.
- Parameters
-
| q | [in] Configuration to search neighbors for |
◆ searchNeighbors() [2/2]
| void searchNeighbors |
( |
const rw::math::Q & |
q, |
|
|
Collection & |
result |
|
) |
| const |
|
inline |
Searches for all potential neighbors.
The potential neighbor is those within the cell associated with q and all neighboring cells.
To find the true neighbors one has to run through the content of the list and make an exact match.
- Parameters
-
| q | [in] Configuration to search neighbors for |
| result | [out] The neighbors of q |
The documentation for this class was generated from the following file: