Apollo 10.0
自动驾驶开放平台
apollo::localization::msf::pyramid_map::PyramidMapConfig类 参考

#include <pyramid_map_config.h>

类 apollo::localization::msf::pyramid_map::PyramidMapConfig 继承关系图:
apollo::localization::msf::pyramid_map::PyramidMapConfig 的协作图:

Public 成员函数

 PyramidMapConfig (const std::string &map_version)
 
 ~PyramidMapConfig ()
 
- Public 成员函数 继承自 apollo::localization::msf::pyramid_map::BaseMapConfig
 BaseMapConfig (const std::string &map_version="0.1")
 The constructor gives the default map settings.
 
virtual ~BaseMapConfig ()
 The deconstructor.
 
bool Save (const std::string &file_path)
 Save the map option to a XML file.
 
bool Load (const std::string &file_path)
 Load the map option from a XML file.
 
void SetMapVersion (const std::string &map_version)
 Set map_version.
 
void SetMapNodeSize (unsigned int size_x, unsigned int size_y)
 Set map_node_size.
 
void SetGroundHeightOffset (float map_ground_height_offset)
 Set map_ground_height_offset.
 
void SetIsCompression (bool map_is_compression)
 Set map_is_compression.
 
void ResizeMapRange ()
 Resize map range by range and resolutions.
 
void SetSingleResolutions (float resolution=0.125)
 Set single resolutions.
 
void SetMultiResolutions ()
 Set multi resolutions.
 
void SetNodeMd5Map (const std::map< std::string, std::string > &node_md5_map)
 Set node_md5_map.
 
void AddNodeMd5 (const std::string &node_path, const std::string &md5)
 Add a node md5 pair.
 
MapVersion GetMapVersion () const
 Get map version.
 

Public 属性

bool has_intensity_ = true
 
bool has_intensity_var_ = true
 
bool has_altitude_ = true
 
bool has_altitude_var_ = true
 
bool has_ground_altitude_ = true
 
bool has_count_ = true
 
bool has_ground_count_ = true
 
unsigned int resolution_num_ = 1
 
unsigned int resolution_ratio_ = 2
 
std::string coordinate_type_ = ""
 coordinate type.
 
float max_intensity_value_ = 0.0
 During the visualization (for example, Call the function get_image() of map node layer), the maximum intensity value in the image.
 
float max_intensity_var_value_ = 0.0
 During the visualization (for example, Call the function get_image() of map node layer), the maximum intensity value in the image.
 
- Public 属性 继承自 apollo::localization::msf::pyramid_map::BaseMapConfig
std::string map_version_ = ""
 The version of map.
 
std::vector< float > map_resolutions_
 The pixel resolutions in the map in meters.
 
unsigned int map_node_size_x_ = 0
 The map node size in pixels.
 
unsigned int map_node_size_y_ = 0
 The map node size in pixels.
 
Rect2D< double > map_range_
 The minimum and maximum UTM range in the map.
 
float map_ground_height_offset_ = 0.0f
 Velodyne's height to the ground.
 
bool map_is_compression_ = false
 Enable the compression.
 
std::string map_folder_path_ = ""
 The map folder path.
 
std::vector< std::string > map_datasets_
 The datasets that contributed to the map.
 
std::map< std::string, std::string > node_md5_map_
 The map structure to store map node file name and its md5.
 
std::string coordinate_type_ = ""
 

Protected 成员函数

virtual bool CreateXml (boost::property_tree::ptree *config) const
 Create the XML structure.
 
virtual bool LoadXml (const boost::property_tree::ptree &config)
 Load the map options from a XML structure.
 

详细描述

在文件 pyramid_map_config.h26 行定义.

构造及析构函数说明

◆ PyramidMapConfig()

apollo::localization::msf::pyramid_map::PyramidMapConfig::PyramidMapConfig ( const std::string &  map_version)
explicit

在文件 pyramid_map_config.cc25 行定义.

26 : BaseMapConfig(map_version) {}
BaseMapConfig(const std::string &map_version="0.1")
The constructor gives the default map settings.

◆ ~PyramidMapConfig()

apollo::localization::msf::pyramid_map::PyramidMapConfig::~PyramidMapConfig ( )

在文件 pyramid_map_config.cc28 行定义.

28{}

成员函数说明

◆ CreateXml()

bool apollo::localization::msf::pyramid_map::PyramidMapConfig::CreateXml ( boost::property_tree::ptree *  config) const
protectedvirtual

Create the XML structure.

重载 apollo::localization::msf::pyramid_map::BaseMapConfig .

在文件 pyramid_map_config.cc30 行定义.

30 {
31 bool success = BaseMapConfig::CreateXml(config);
32 if (success) {
33 config->put("map.map_config.has_intensity", has_intensity_);
34 config->put("map.map_config.has_intensity_var", has_intensity_var_);
35 config->put("map.map_config.has_altitude", has_altitude_);
36 config->put("map.map_config.has_altitude_var", has_altitude_var_);
37 config->put("map.map_config.has_ground_altitude", has_ground_altitude_);
38 config->put("map.map_config.has_count", has_count_);
39 config->put("map.map_config.has_ground_count", has_ground_count_);
40 config->put("map.map_config.resolution_num", resolution_num_);
41 config->put("map.map_config.resolution_ratio", resolution_ratio_);
42 config->put("map.map_config.coordinate_type", coordinate_type_);
43 config->put("map.map_runtime.max_intensity_value", max_intensity_value_);
44 config->put("map.map_runtime.max_intensity_var_value",
46 return true;
47 } else {
48 return false;
49 }
50}
virtual bool CreateXml(boost::property_tree::ptree *config) const
Create the XML structure.
float max_intensity_value_
During the visualization (for example, Call the function get_image() of map node layer),...
float max_intensity_var_value_
During the visualization (for example, Call the function get_image() of map node layer),...

◆ LoadXml()

bool apollo::localization::msf::pyramid_map::PyramidMapConfig::LoadXml ( const boost::property_tree::ptree &  config)
protectedvirtual

Load the map options from a XML structure.

重载 apollo::localization::msf::pyramid_map::BaseMapConfig .

在文件 pyramid_map_config.cc52 行定义.

52 {
53 bool success = BaseMapConfig::LoadXml(config);
54 if (success) {
55 auto has_intensity =
56 config.get_optional<bool>("map.map_config.has_intensity");
57 auto has_intensity_var =
58 config.get_optional<bool>("map.map_config.has_intensity_var");
59 auto has_altitude =
60 config.get_optional<bool>("map.map_config.has_altitude");
61 auto has_altitude_var =
62 config.get_optional<bool>("map.map_config.has_altitude_var");
63 auto has_ground_altitude =
64 config.get_optional<bool>("map.map_config.has_ground_altitude");
65 auto has_count = config.get_optional<bool>("map.map_config.has_count");
66 auto has_ground_count =
67 config.get_optional<bool>("map.map_config.has_ground_count");
68 auto resolution_num =
69 config.get_optional<unsigned int>("map.map_config.resolution_num");
70 auto resolution_ratio =
71 config.get_optional<unsigned int>("map.map_config.resolution_ratio");
72 auto coordinate_type =
73 config.get_optional<std::string>("map.map_config.coordinate_type");
74 auto max_intensity_value =
75 config.get_optional<float>("map.map_runtime.max_intensity_value");
76 auto max_intensity_var_value =
77 config.get_optional<float>("map.map_runtime.max_intensity_var_value");
78
79 if (has_intensity) {
80 has_intensity_ = *has_intensity;
81 }
82
83 if (has_intensity_var) {
84 has_intensity_var_ = *has_intensity_var;
85 }
86
87 if (has_altitude) {
88 has_altitude_ = *has_altitude;
89 }
90
91 if (has_altitude_var) {
92 has_altitude_var_ = *has_altitude_var;
93 }
94
95 if (has_ground_altitude) {
96 has_ground_altitude_ = *has_ground_altitude;
97 }
98
99 if (has_count) {
100 has_count_ = *has_count;
101 }
102
103 if (has_ground_count) {
104 has_ground_count_ = *has_ground_count;
105 }
106
107 if (resolution_num) {
108 resolution_num_ = *resolution_num;
109 }
110
111 if (resolution_ratio) {
112 resolution_ratio_ = *resolution_ratio;
113 }
114
115 if (coordinate_type) {
116 coordinate_type_ = *coordinate_type;
117 }
118
119 if (max_intensity_value) {
120 max_intensity_value_ = *max_intensity_value;
121 }
122
123 if (max_intensity_var_value) {
124 max_intensity_var_value_ = *max_intensity_var_value;
125 }
126
127 return true;
128 }
129
130 return false;
131}
virtual bool LoadXml(const boost::property_tree::ptree &config)
Load the map options from a XML structure.

类成员变量说明

◆ coordinate_type_

std::string apollo::localization::msf::pyramid_map::PyramidMapConfig::coordinate_type_ = ""

coordinate type.

在文件 pyramid_map_config.h41 行定义.

◆ has_altitude_

bool apollo::localization::msf::pyramid_map::PyramidMapConfig::has_altitude_ = true

在文件 pyramid_map_config.h33 行定义.

◆ has_altitude_var_

bool apollo::localization::msf::pyramid_map::PyramidMapConfig::has_altitude_var_ = true

在文件 pyramid_map_config.h34 行定义.

◆ has_count_

bool apollo::localization::msf::pyramid_map::PyramidMapConfig::has_count_ = true

在文件 pyramid_map_config.h36 行定义.

◆ has_ground_altitude_

bool apollo::localization::msf::pyramid_map::PyramidMapConfig::has_ground_altitude_ = true

在文件 pyramid_map_config.h35 行定义.

◆ has_ground_count_

bool apollo::localization::msf::pyramid_map::PyramidMapConfig::has_ground_count_ = true

在文件 pyramid_map_config.h37 行定义.

◆ has_intensity_

bool apollo::localization::msf::pyramid_map::PyramidMapConfig::has_intensity_ = true

在文件 pyramid_map_config.h31 行定义.

◆ has_intensity_var_

bool apollo::localization::msf::pyramid_map::PyramidMapConfig::has_intensity_var_ = true

在文件 pyramid_map_config.h32 行定义.

◆ max_intensity_value_

float apollo::localization::msf::pyramid_map::PyramidMapConfig::max_intensity_value_ = 0.0

During the visualization (for example, Call the function get_image() of map node layer), the maximum intensity value in the image.

在文件 pyramid_map_config.h44 行定义.

◆ max_intensity_var_value_

float apollo::localization::msf::pyramid_map::PyramidMapConfig::max_intensity_var_value_ = 0.0

During the visualization (for example, Call the function get_image() of map node layer), the maximum intensity value in the image.

在文件 pyramid_map_config.h48 行定义.

◆ resolution_num_

unsigned int apollo::localization::msf::pyramid_map::PyramidMapConfig::resolution_num_ = 1

在文件 pyramid_map_config.h38 行定义.

◆ resolution_ratio_

unsigned int apollo::localization::msf::pyramid_map::PyramidMapConfig::resolution_ratio_ = 2

在文件 pyramid_map_config.h39 行定义.


该类的文档由以下文件生成: