struct mrpt::slam::CMetricMapBuilderICP::TConfigParams

Overview

Algorithm configuration params.

#include <mrpt/slam/CMetricMapBuilderICP.h>

struct TConfigParams: public mrpt::config::CLoadableOptions
{
    // fields

    bool matchAgainstTheGrid;
    double insertionLinDistance;
    double insertionAngDistance;
    double localizationLinDistance;
    double localizationAngDistance;
    double minICPgoodnessToAccept;
    mrpt::system::VerbosityLevel& verbosity_level;
    mrpt::maps::TSetOfMetricMapInitializers mapInitializers;

    // construction

    TConfigParams(mrpt::system::VerbosityLevel& parent_verbosity_level);
    TConfigParams(const TConfigParams& other);

    // methods

    TConfigParams& operator = (const TConfigParams& other);
    virtual void loadFromConfigFile(const mrpt::config::CConfigFileBase& source, const std::string& section);
    virtual void dumpToTextStream(std::ostream& out) const;
};

Inherited Members

public:
    // methods

    virtual void loadFromConfigFile(const mrpt::config::CConfigFileBase& source, const std::string& section) = 0;
    void loadFromConfigFileName(const std::string& config_file, const std::string& section);
    virtual void saveToConfigFile(mrpt::config::CConfigFileBase& target, const std::string& section) const;
    void saveToConfigFileName(const std::string& config_file, const std::string& section) const;
    void dumpToConsole() const;
    virtual void dumpToTextStream(std::ostream& out) const;

Fields

bool matchAgainstTheGrid

(default:false) Match against the occupancy grid or the points map? The former is quicker but less precise.

double insertionLinDistance

Minimum robot linear (m) displacement for a new observation to be inserted in the map.

double insertionAngDistance

Minimum robot angular (rad, deg when loaded from the .ini) displacement for a new observation to be inserted in the map.

double localizationLinDistance

Minimum robot linear (m) displacement for a new observation to be used to do ICP-based localization (otherwise, dead-reckon with odometry).

double localizationAngDistance

Minimum robot angular (rad, deg when loaded from the .ini) displacement for a new observation to be used to do ICP-based localization (otherwise, dead-reckon with odometry).

double minICPgoodnessToAccept

Minimum ICP goodness (0,1) to accept the resulting corrected position (default: 0.40)

mrpt::maps::TSetOfMetricMapInitializers mapInitializers

What maps to create (at least one points map and/or a grid map are needed).

For the expected format in the .ini file when loaded with loadFromConfigFile(), see documentation of TSetOfMetricMapInitializers.

Construction

TConfigParams(mrpt::system::VerbosityLevel& parent_verbosity_level)

Initializer.

Methods

virtual void loadFromConfigFile(const mrpt::config::CConfigFileBase& source, const std::string& section)

This method load the options from a “.ini”-like file or memory-stored string list.

Only those parameters found in the given “section” and having the same name that the variable are loaded. Those not found in the file will stay with their previous values (usually the default values loaded at initialization). An example of an “.ini” file:

[section]
resolution    = 0.10   // blah blah...
modeSelection = 1      // 0=blah, 1=blah,...

See also:

loadFromConfigFileName, saveToConfigFile

virtual void dumpToTextStream(std::ostream& out) const

This method should clearly display all the contents of the structure in textual form, sending it to a std::ostream.

The default implementation in this base class relies on saveToConfigFile() to generate a plain text representation of all the parameters.