Functions | Variables
apps/mp2p-icp-run/main.cpp File Reference
#include <mp2p_icp/ICP.h>
#include <mp2p_icp/icp_pipeline_from_yaml.h>
#include <mp2p_icp/load_xyz_file.h>
#include <mp2p_icp/metricmap.h>
#include <mp2p_icp_filters/FilterBase.h>
#include <mp2p_icp_filters/Generator.h>
#include <mrpt/3rdparty/tclap/CmdLine.h>
#include <mrpt/core/Clock.h>
#include <mrpt/img/CImage.h>
#include <mrpt/obs/CRawlog.h>
#include <mrpt/system/datetime.h>
#include <mrpt/system/filesystem.h>
#include <fstream>
Include dependency graph for apps/mp2p-icp-run/main.cpp:

Go to the source code of this file.

Functions

static TCLAP::ValueArg< std::string > argCfgNameFiltersGlobal ("", "entry-name-filters-global", "Overrides the map name in the YAML configuration file for global map " "filter.", false, "filters", "filters", cmd)
 
static TCLAP::ValueArg< std::string > argCfgNameFiltersLocal ("", "entry-name-filters-local", "Overrides the map name in the YAML configuration file for local map " "filter.", false, "filters", "filters", cmd)
 
static TCLAP::SwitchArg argGenerateDebugFiles ("d", "generate-debug-log", "Enforces generation of the .icplog debug log files for posterior " "visualization with mp2p-icp-log-viewer, overriding the " "`generateDebugFiles` value in the configuration YAML file.", cmd)
 
static TCLAP::ValueArg< std::string > argInitialGuess ("", "guess", "SE(3) transformation of local wrt global, to use as initial guess for the " "ICP algorithm. " "Format: \"[x y z yaw_deg pitch_deg roll_deg]\"", false, "[0 0 0 0 0 0]", "[0 0 0 0 0 0]", cmd)
 
static TCLAP::ValueArg< std::string > argInputGlobal ("", "input-global", "Global input point cloud/map. Same format than input-local. ", true, "pointcloud2.txt", "pointcloud2.txt", cmd)
 
static TCLAP::ValueArg< std::string > argInputLocal ("", "input-local", "Local input point cloud/map." "It is interpreted as a rawlog entry if using the " "format `<RAWLOG_FILE.rawlog>:<N>` to select the N-th entry in the " "rawlog; otherwise, if the file extension is `.mm` it is loaded as a " "serialized metric_map_t object; if it is a `.icplog` file, the local map " "from that icp log is taken as input; in any other case, the file is " "assumed to be a 3D pointcloud stored as a Nx3 ASCII matrix file.", true, "pointcloud1.txt", "pointcloud1.txt", cmd)
 
static TCLAP::ValueArg< std::string > argYamlConfigFile ("c", "config", "YAML config file describing the ICP pipeline. See docs:\n" " https://docs.mola-slam.org/latest/" "module-mp2p-icp.html#yaml-pipeline-definition-files", true, "icp-config.yaml", "icp-config.yaml", cmd)
 
static TCLAP::ValueArg< std::string > argYamlConfigFileFiltersGlobal ("", "config-filters-global", "YAML config file describing a filtering pipeline for global map." "If not provided, and the main --config yaml file contains a" "`filters` entry (can be overriden with --entry-name-filters-global), it " "will be used instead.", false, "filters-config.yaml", "filters-config.yaml", cmd)
 
static TCLAP::ValueArg< std::string > argYamlConfigFileFiltersLocal ("", "config-filters-local", "YAML config file describing a filtering pipeline for local map." "If not provided, and the main --config yaml file contains a " "`filters` entry (can be overriden with --entry-name-filters-local), it " "will be used instead.", false, "filters-config.yaml", "filters-config.yaml", cmd)
 
static TCLAP::ValueArg< std::string > argYamlConfigFileGenerators ("", "config-generators", "YAML config file describing the Generators. Can be also defined via an " "entry `generators` in the main `--config` yaml file. " "Can be used when processing a rawlog as input; if not present, a default " "Generator object will be used.", false, "generators-config.yaml", "generators-config.yaml", cmd)
 
static TCLAP::CmdLine cmd ("mp2p-icp-run")
 
static mp2p_icp::metric_map_t::Ptr load_input_pc (const std::string &filename, bool local)
 
static mrpt::obs::CRawlog::Ptr load_rawlog (const std::string &filename)
 
int main (int argc, char **argv)
 
static mp2p_icp::metric_map_t::Ptr pc_from_rawlog (const mrpt::obs::CRawlog &r, const size_t index)
 
void runIcp ()
 

Variables

static mp2p_icp_filters::GeneratorSet generators
 
static std::map< std::string, mrpt::obs::CRawlog::Ptr > rawlogsCache
 

Function Documentation

◆ argCfgNameFiltersGlobal()

static TCLAP::ValueArg<std::string> argCfgNameFiltersGlobal ( ""  ,
"entry-name-filters-global"  ,
"Overrides the map name in the YAML configuration file for global map " "filter."  ,
false  ,
"filters"  ,
"filters"  ,
cmd   
)
static

◆ argCfgNameFiltersLocal()

static TCLAP::ValueArg<std::string> argCfgNameFiltersLocal ( ""  ,
"entry-name-filters-local"  ,
"Overrides the map name in the YAML configuration file for local map " "filter."  ,
false  ,
"filters"  ,
"filters"  ,
cmd   
)
static

◆ argGenerateDebugFiles()

static TCLAP::SwitchArg argGenerateDebugFiles ( "d"  ,
"generate-debug-log"  ,
"Enforces generation of the .icplog debug log files for posterior " "visualization with mp2p-icp-log-  viewer,
overriding the " "`generateDebugFiles` value in the configuration YAML file."  ,
cmd   
)
static

◆ argInitialGuess()

static TCLAP::ValueArg<std::string> argInitialGuess ( ""  ,
"guess"  ,
"SE(3) transformation of local wrt  global,
to use as initial guess for the " "ICP algorithm. " "Format:\"\""  [x y z yaw_deg pitch_deg roll_deg],
false  ,
""  [0 0 0 0 0 0],
""  [0 0 0 0 0 0],
cmd   
)
static

◆ argInputGlobal()

static TCLAP::ValueArg<std::string> argInputGlobal ( ""  ,
"input-global"  ,
"Global input point cloud/map. Same format than input-local. "  ,
true  ,
"pointcloud2.txt"  ,
"pointcloud2.txt"  ,
cmd   
)
static

◆ argInputLocal()

static TCLAP::ValueArg<std::string> argInputLocal ( ""  ,
"input-local"  ,
"Local input point cloud/map." "It is interpreted as a rawlog entry if using the " "format `<RAWLOG_FILE.rawlog>:<N>` to select the N-th entry in the " "rawlog;  otherwise,
if the file extension is `.mm` it is loaded as a " "serialized metric_map_t object;if it is a `.icplog`  file,
the local map " "from that icp log is taken as input;in any other  case,
the file is " "assumed to be a 3D pointcloud stored as a Nx3 ASCII matrix file."  ,
true  ,
"pointcloud1.txt"  ,
"pointcloud1.txt"  ,
cmd   
)
static

◆ argYamlConfigFile()

static TCLAP::ValueArg<std::string> argYamlConfigFile ( "c"  ,
"config"  ,
"YAML config file describing the ICP pipeline. See docs:\n" " https://docs.mola-slam.org/latest/" "module-mp2p-icp.html#yaml-pipeline-definition-files"  ,
true  ,
"icp-config.yaml"  ,
"icp-config.yaml"  ,
cmd   
)
static

◆ argYamlConfigFileFiltersGlobal()

static TCLAP::ValueArg<std::string> argYamlConfigFileFiltersGlobal ( ""  ,
"config-filters-global"  ,
"YAML config file describing a filtering pipeline for global map." "If not  provided,
and the main --config yaml file contains a" "`filters`   entrycan be overriden with --entry-name-filters-global,
it " "will be used instead."  ,
false  ,
"filters-config.yaml"  ,
"filters-config.yaml"  ,
cmd   
)
static

◆ argYamlConfigFileFiltersLocal()

static TCLAP::ValueArg<std::string> argYamlConfigFileFiltersLocal ( ""  ,
"config-filters-local"  ,
"YAML config file describing a filtering pipeline for local map." "If not  provided,
and the main --config yaml file contains a " "`filters`   entrycan be overriden with --entry-name-filters-local,
it " "will be used instead."  ,
false  ,
"filters-config.yaml"  ,
"filters-config.yaml"  ,
cmd   
)
static

◆ argYamlConfigFileGenerators()

static TCLAP::ValueArg<std::string> argYamlConfigFileGenerators ( ""  ,
"config-generators ,
"YAML config file describing the Generators. Can be also defined via an " "entry `generators` in the main `--config` yaml file. " "Can be used when processing a rawlog as input; if not  present,
a default " "Generator object will be used."  ,
false  ,
"generators-config.yaml"  ,
"generators-config.yaml"  ,
cmd   
)
static

◆ cmd()

static TCLAP::CmdLine cmd ( "mp2p-icp-run )
static

◆ load_input_pc()

static mp2p_icp::metric_map_t::Ptr load_input_pc ( const std::string &  filename,
bool  local 
)
static

Definition at line 175 of file apps/mp2p-icp-run/main.cpp.

◆ load_rawlog()

static mrpt::obs::CRawlog::Ptr load_rawlog ( const std::string &  filename)
static

Definition at line 108 of file apps/mp2p-icp-run/main.cpp.

◆ main()

int main ( int  argc,
char **  argv 
)

Definition at line 322 of file apps/mp2p-icp-run/main.cpp.

◆ pc_from_rawlog()

static mp2p_icp::metric_map_t::Ptr pc_from_rawlog ( const mrpt::obs::CRawlog &  r,
const size_t  index 
)
static

Definition at line 132 of file apps/mp2p-icp-run/main.cpp.

◆ runIcp()

void runIcp ( )

Definition at line 223 of file apps/mp2p-icp-run/main.cpp.

Variable Documentation

◆ generators

mp2p_icp_filters::GeneratorSet generators
static

Definition at line 130 of file apps/mp2p-icp-run/main.cpp.

◆ rawlogsCache

std::map<std::string, mrpt::obs::CRawlog::Ptr> rawlogsCache
static

Definition at line 106 of file apps/mp2p-icp-run/main.cpp.



mrpt_local_obstacles
Author(s): Jose-Luis Blanco-Claraco
autogenerated on Mon Aug 14 2023 02:09:04