1 #ifndef GRIDSLAMPROCESSOR_H 2 #define GRIDSLAMPROCESSOR_H 85 typedef std::deque<GridSlamProcessor::TNode*>
TNodeDeque;
95 inline operator double()
const {
return weight;}
145 void init(
unsigned int size,
double xmin,
double ymin,
double xmax,
double ymax,
double delta,
147 void setMatchingParameters(
double urange,
double range,
double sigma,
int kernsize,
double lopt,
double aopt,
148 int iterations,
double likelihoodSigma=1,
double likelihoodGain=1,
unsigned int likelihoodSkip=0);
204 MEMBER_PARAM_SET_GET(m_matcher,
unsigned int, optRecursiveIterations,
protected,
public,
public);
244 PARAM_SET_GET(
double, minimumScore,
protected,
public,
public);
268 PARAM_SET_GET(
double, resampleThreshold,
protected,
public,
public);
279 PARAM_GET(
double, xmin,
protected,
public);
280 PARAM_GET(
double, ymin,
protected,
public);
281 PARAM_GET(
double, xmax,
protected,
public);
282 PARAM_GET(
double, ymax,
protected,
public);
284 PARAM_GET(
double, delta,
protected,
public);
294 PARAM_SET_GET(
double, linearThresholdDistance,
protected,
public,
public);
297 PARAM_SET_GET(
double, angularThresholdDistance,
protected,
public,
public);
300 PARAM_SET_GET(
double, obsSigmaGain,
protected,
public,
public);
314 inline void scanMatch(
const double *plainReading);
319 inline bool resample(
const double* plainReading,
int adaptParticles,
330 typedef std::multimap<const GridSlamProcessor::TNode*, GridSlamProcessor::TNode*>
TNodeMultimap;
333 #include "gridslamprocessor.hxx" const char *const *argv double delta
PARAM_GET(double, neff, protected, public)
std::ofstream & outputStream()
std::vector< double > m_weights
const ParticleVector & getParticles() const
virtual void onScanmatchUpdate()
const RangeReading * reading
std::vector< GridSlamProcessor::TNode * > TNodeVector
std::vector< unsigned int > m_indexes
std::ostream & infoStream()
void setMatchingParameters(double urange, double range, double sigma, int kernsize, double lopt, double aopt, int iterations, double likelihoodSigma=1, double likelihoodGain=1, unsigned int likelihoodSkip=0)
OrientedPoint previousPose
void integrateScanSequence(TNode *node)
unsigned int visitCounter
bool processScan(const RangeReading &reading, int adaptParticles=0)
STRUCT_PARAM_SET_GET(m_motionModel, double, srr, protected, public, public)
bool resample(const double *plainReading, int adaptParticles, const RangeReading *rr=0)
std::vector< Particle > ParticleVector
virtual ~GridSlamProcessor()
virtual void onOdometryUpdate()
TNode(const OrientedPoint &pose, double weight, TNode *parent=0, unsigned int childs=0)
std::deque< GridSlamProcessor::TNode * > TNodeDeque
std::multimap< const GridSlamProcessor::TNode *, GridSlamProcessor::TNode * > TNodeMultimap
ParticleVector m_particles
const std::vector< unsigned int > & getIndexes() const
void setUpdateDistances(double linear, double angular, double resampleThreshold)
void setSensorMap(const SensorMap &smap)
void processTruePos(const OdometryReading &odometry)
GridSlamProcessor * clone() const
OrientedPoint m_lastPartPose
std::ofstream m_outputStream
void scanMatch(const double *plainReading)
virtual void onResampleUpdate()
MotionModel m_motionModel
std::map< std::string, Sensor * > SensorMap
TNodeVector getTrajectories() const
PARAM_SET_GET(double, minimumScore, protected, public, public)
std::ostream & m_infoStream
double propagateWeights()
void setUpdatePeriod(double p)
void init(unsigned int size, double xmin, double ymin, double xmax, double ymax, double delta, OrientedPoint initialPose=OrientedPoint(0, 0, 0))
void setMotionModelParameters(double srr, double srt, double str, double stt)
int getBestParticleIndex() const
void updateTreeWeights(bool weightsAlreadyNormalized=false)
orientedpoint< double, double > OrientedPoint
MEMBER_PARAM_SET_GET(m_matcher, double, laserMaxRange, protected, public, public)