larics / cartographer_superbuild Goto Github PK
View Code? Open in Web Editor NEWLicense: Apache License 2.0
License: Apache License 2.0
First of all !
Thanks for your share!
I made it successfully.
However,when i run cartographer_paper_deutsches_museum.bag using offline_node,
it print out said "W0802 13:53:34.000000 8483 ordered_multi_queue.cc:155] Queue waiting for data: (0, echoes) "
and the result file .pbstream is so small which is just about 90 bytes.It seemed to be wrong?
Could you help me to run this bag?
Maybe there is some mistakes during my code.
I just modify the code just as below:
DEFINE_string(configuration_directory, "/home/mm/cartographer_superbuild/cartographer_ros/cartographer_ros/configuration_files",
"First directory in which configuration files are searched, "
"second is always the Cartographer installation to allow "
"including files from there.");
DEFINE_string(
configuration_basenames, "backpack_2d.lua",
"Comma-separated list of basenames, i.e. not containing any "
"directory prefix, of the configuration files for each trajectory. "
"The first configuration file will be used for node options. "
"If less configuration files are specified than trajectories, the "
"first file will be used the remaining trajectories.");
DEFINE_string(
bag_filenames, "/home/mm/Downloads/cartographer_paper_deutsches_museum.bag",
"Comma-separated list of bags to process. One bag per trajectory. "
"Any combination of simultaneous and sequential bags is supported.");
DEFINE_string(urdf_filenames, "/home/mm/cartographer_superbuild/cartographer_ros/cartographer_ros/urdf/backpack_2d.urdf",
"Comma-separated list of one or more URDF files that contain "
"static links for the sensor configuration(s).");
DEFINE_bool(use_bag_transforms, true,
"Whether to read, use and republish transforms from bags.");
DEFINE_string(load_state_filename, "",
"If non-empty, filename of a .pbstream file to load, containing "
"a saved SLAM state.");
DEFINE_bool(load_frozen_state, true,
"Load the saved state as frozen (non-optimized) trajectories.");
DEFINE_bool(keep_running, false,
"Keep running the offline node after all messages from the bag "
"have been processed.");
DEFINE_double(skip_seconds, 0,
"Optional amount of seconds to skip from the beginning "
"(i.e. when the earliest bag starts.). ");
Hello,
Thank you very much for providing the cmake support of cartographer. I have compiled them and run it in terminal successfully. However, cartographer node didn't subscribe sensor data when I run it in clion.
For the code
boost::function<void(const sensor_msgs::LaserScan::ConstPtr&)>( [this, trajectory_id, topic](const sensor_msgs::LaserScan::ConstPtr& msg) { map_builder_bridge_.sensor_bridge(trajectory_id) ->HandleLaserScanMessage(topic, msg); })));
there is an error says,
Class 'boost::function<void(const sensor_msgs::LaserScan_<std::allocator<void>>::ConstPtr &)>' doesn't have a constructor 'function(void (*)(const sensor_msgs::LaserScan_<std::allocator<void>>::ConstPtr &))'
Other sensor callback meet the same error. However, I can pass the build but when I run the program, the cartographer node is always waiting, receive no data.
/home/xuqw/CLionProjects/carto/cartographer_superbuild/cmake-build-relwithdebinfo/devel/lib/cartographer_ros/cartographer_node -configuration_directory /home/xuqw/CLionProjects/carto/cartographer_superbuild/cartographer_ros/cartographer_ros/configuration_files -configuration_basename backpack_2d.lua [ INFO] [1501243771.055225301]: I0728 20:09:31.000000 757 configuration_file_resolver.cc:40] Found '/home/xuqw/CLionProjects/carto/cartographer_superbuild/cartographer_ros/cartographer_ros/configuration_files/backpack_2d.lua' for 'backpack_2d.lua'. [ INFO] [1501243771.055693767]: I0728 20:09:31.000000 757 configuration_file_resolver.cc:40] Found '/home/xuqw/CLionProjects/carto/cartographer_superbuild/cartographer/configuration_files/map_builder.lua' for 'map_builder.lua'. [ INFO] [1501243771.055759021]: I0728 20:09:31.000000 757 configuration_file_resolver.cc:40] Found '/home/xuqw/CLionProjects/carto/cartographer_superbuild/cartographer/configuration_files/map_builder.lua' for 'map_builder.lua'. [ INFO] [1501243771.055855055]: I0728 20:09:31.000000 757 configuration_file_resolver.cc:40] Found '/home/xuqw/CLionProjects/carto/cartographer_superbuild/cartographer/configuration_files/sparse_pose_graph.lua' for 'sparse_pose_graph.lua'. [ INFO] [1501243771.055914091]: I0728 20:09:31.000000 757 configuration_file_resolver.cc:40] Found '/home/xuqw/CLionProjects/carto/cartographer_superbuild/cartographer/configuration_files/sparse_pose_graph.lua' for 'sparse_pose_graph.lua'. [ INFO] [1501243771.056145692]: I0728 20:09:31.000000 757 configuration_file_resolver.cc:40] Found '/home/xuqw/CLionProjects/carto/cartographer_superbuild/cartographer/configuration_files/trajectory_builder.lua' for 'trajectory_builder.lua'. [ INFO] [1501243771.056202782]: I0728 20:09:31.000000 757 configuration_file_resolver.cc:40] Found '/home/xuqw/CLionProjects/carto/cartographer_superbuild/cartographer/configuration_files/trajectory_builder.lua' for 'trajectory_builder.lua'. [ INFO] [1501243771.056289882]: I0728 20:09:31.000000 757 configuration_file_resolver.cc:40] Found '/home/xuqw/CLionProjects/carto/cartographer_superbuild/cartographer/configuration_files/trajectory_builder_2d.lua' for 'trajectory_builder_2d.lua'. [ INFO] [1501243771.056343157]: I0728 20:09:31.000000 757 configuration_file_resolver.cc:40] Found '/home/xuqw/CLionProjects/carto/cartographer_superbuild/cartographer/configuration_files/trajectory_builder_2d.lua' for 'trajectory_builder_2d.lua'. [ INFO] [1501243771.056490949]: I0728 20:09:31.000000 757 configuration_file_resolver.cc:40] Found '/home/xuqw/CLionProjects/carto/cartographer_superbuild/cartographer/configuration_files/trajectory_builder_3d.lua' for 'trajectory_builder_3d.lua'. [ INFO] [1501243771.056554242]: I0728 20:09:31.000000 757 configuration_file_resolver.cc:40] Found '/home/xuqw/CLionProjects/carto/cartographer_superbuild/cartographer/configuration_files/trajectory_builder_3d.lua' for 'trajectory_builder_3d.lua'. [ INFO] [1501243771.073532229]: I0728 20:09:31.000000 757 submaps.cc:188] Added submap 1 [ INFO] [1501243771.073686230]: I0728 20:09:31.000000 757 map_builder_bridge.cc:58] Added trajectory with ID '0'.
I have no idea on it. Could you give a hand? I will be very appreciated.
Hi,
I was trying to build the code in CLion. However, it gives me the following errors:
/opt/clion-2018.3.2/bin/cmake/linux/bin/cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo -G "CodeBlocks - Unix Makefiles" /home/wd-ai/catkin_ws_debug/src/cartographer_superbuild
-- Build type: RelWithDebInfo
-- Boost version: 1.58.0
-- Found the following Boost libraries:
-- iostreams
-- regex
-- Found installed version of Eigen: /usr/local/share/eigen3/cmake
-- Found required Ceres dependency: Eigen version 3.3.5 in /usr/local/include/eigen3
-- Found required Ceres dependency: glog
-- Found required Ceres dependency: gflags
-- Found Ceres version: 2.0.0 installed in: /usr/local with components: [EigenSparse, SparseLinearAlgebraLibrary, LAPACK, SuiteSparse, CXSparse, SchurSpecializations]
-- Using CATKIN_DEVEL_PREFIX: /home/wd-ai/catkin_ws_debug/src/cartographer_superbuild/cmake-build-relwithdebinfo/devel
-- Using CMAKE_PREFIX_PATH: /home/wd-ai/catkin_ws/devel;/opt/ros/kinetic
-- This workspace overlays: /home/wd-ai/catkin_ws/devel;/opt/ros/kinetic
-- Using PYTHON_EXECUTABLE: /usr/bin/python
-- Using Debian Python package layout
-- Using empy: /usr/bin/empy
-- Using CATKIN_ENABLE_TESTING: ON
-- Call enable_testing()
-- Using CATKIN_TEST_RESULTS_DIR: /home/wd-ai/catkin_ws_debug/src/cartographer_superbuild/cmake-build-relwithdebinfo/test_results
-- Using Python nosetests: /usr/bin/nosetests-2.7
-- catkin 0.7.14
-- Using these message generators: gencpp;geneus;genlisp;gennodejs;genpy
-- cartographer_ros_msgs: 15 messages, 6 services
-- Boost version: 1.58.0
-- Found the following Boost libraries:
-- system
-- iostreams
-- regex
-- Eigen found (include: /usr/local/include/eigen3, version: 3.3.5)
-- Boost version: 1.58.0
-- Found the following Boost libraries:
-- system
-- filesystem
-- thread
-- date_time
-- iostreams
-- serialization
-- chrono
-- atomic
-- regex
-- looking for PCL_COMMON
-- Build type: RelWithDebInfo
-- Using CATKIN_DEVEL_PREFIX: /home/wd-ai/catkin_ws_debug/src/cartographer_superbuild/cmake-build-relwithdebinfo/devel
-- Using CMAKE_PREFIX_PATH: /home/wd-ai/catkin_ws/devel;/opt/ros/kinetic
-- This workspace overlays: /home/wd-ai/catkin_ws/devel;/opt/ros/kinetic
-- Using PYTHON_EXECUTABLE: /usr/bin/python
-- Using Debian Python package layout
-- Using empy: /usr/bin/empy
-- Using CATKIN_ENABLE_TESTING: ON
-- Call enable_testing()
-- Using CATKIN_TEST_RESULTS_DIR: /home/wd-ai/catkin_ws_debug/src/cartographer_superbuild/cmake-build-relwithdebinfo/test_results
-- Using Python nosetests: /usr/bin/nosetests-2.7
-- catkin 0.7.14
-- Using these message generators: gencpp;geneus;genlisp;gennodejs;genpy
-- Boost version: 1.58.0
-- Found the following Boost libraries:
-- system
-- iostreams
-- regex
-- Build type: RelWithDebInfo
-- Using CATKIN_DEVEL_PREFIX: /home/wd-ai/catkin_ws_debug/src/cartographer_superbuild/cmake-build-relwithdebinfo/devel
-- Using CMAKE_PREFIX_PATH: /home/wd-ai/catkin_ws/devel;/opt/ros/kinetic
-- This workspace overlays: /home/wd-ai/catkin_ws/devel;/opt/ros/kinetic
-- Using PYTHON_EXECUTABLE: /usr/bin/python
-- Using Debian Python package layout
-- Using empy: /usr/bin/empy
-- Using CATKIN_ENABLE_TESTING: ON
-- Call enable_testing()
-- Using CATKIN_TEST_RESULTS_DIR: /home/wd-ai/catkin_ws_debug/src/cartographer_superbuild/cmake-build-relwithdebinfo/test_results
-- Using Python nosetests: /usr/bin/nosetests-2.7
-- catkin 0.7.14
CMake Error at cmake-build-relwithdebinfo/devel/share/cartographer_ros/cmake/cartographer_rosConfig.cmake:148 (message):
Project 'cartographer_rviz' tried to find library '-lpthread'. The library
is neither a target nor built/installed properly. Did you compile project
'cartographer_ros'? Did you find_package() it before the subdirectory
containing its code is included?
Call Stack (most recent call first):
/opt/ros/kinetic/share/catkin/cmake/catkinConfig.cmake:76 (find_package)
cartographer_ros/cartographer_rviz/CMakeLists.txt:39 (find_package)
-- Configuring incomplete, errors occurred!
See also "/home/wd-ai/catkin_ws_debug/src/cartographer_superbuild/cmake-build-relwithdebinfo/CMakeFiles/CMakeOutput.log".
See also "/home/wd-ai/catkin_ws_debug/src/cartographer_superbuild/cmake-build-relwithdebinfo/CMakeFiles/CMakeError.log".
[Finished]
The build works in the command line but not in CLion. Can you help me?
Thank you!
Hello, if I want to place other ros package under cartographer_superbuild, how do I do it? I tried adding add_subdirectory to CMakeLists.txt, but it doesn’t seem to work
Hi,
I was trying to debug the code in CLion. However, it gives me a lot of warning messages:
[ INFO] [1602409271.778359122]: I1011 17:41:11.000000 31371 configuration_file_resolver.cc:41] Found '/home/yuan/test3/cartographer_superbuild/cartographer_ros/cartographer_ros/configuration_files/backpack_2d.lua' for 'backpack_2d.lua'.
[ INFO] [1602409271.778863151]: I1011 17:41:11.000000 31371 configuration_file_resolver.cc:41] Found '/home/yuan/test3/cartographer_superbuild/cartographer/configuration_files/map_builder.lua' for 'map_builder.lua'.
[ INFO] [1602409271.778906037]: I1011 17:41:11.000000 31371 configuration_file_resolver.cc:41] Found '/home/yuan/test3/cartographer_superbuild/cartographer/configuration_files/map_builder.lua' for 'map_builder.lua'.
[ INFO] [1602409271.778939008]: I1011 17:41:11.000000 31371 configuration_file_resolver.cc:41] Found '/home/yuan/test3/cartographer_superbuild/cartographer/configuration_files/pose_graph.lua' for 'pose_graph.lua'.
[ INFO] [1602409271.778956540]: I1011 17:41:11.000000 31371 configuration_file_resolver.cc:41] Found '/home/yuan/test3/cartographer_superbuild/cartographer/configuration_files/pose_graph.lua' for 'pose_graph.lua'.
[ INFO] [1602409271.779041807]: I1011 17:41:11.000000 31371 configuration_file_resolver.cc:41] Found '/home/yuan/test3/cartographer_superbuild/cartographer/configuration_files/trajectory_builder.lua' for 'trajectory_builder.lua'.
[ INFO] [1602409271.779093004]: I1011 17:41:11.000000 31371 configuration_file_resolver.cc:41] Found '/home/yuan/test3/cartographer_superbuild/cartographer/configuration_files/trajectory_builder.lua' for 'trajectory_builder.lua'.
[ INFO] [1602409271.779124441]: I1011 17:41:11.000000 31371 configuration_file_resolver.cc:41] Found '/home/yuan/test3/cartographer_superbuild/cartographer/configuration_files/trajectory_builder_2d.lua' for 'trajectory_builder_2d.lua'.
[ INFO] [1602409271.779141409]: I1011 17:41:11.000000 31371 configuration_file_resolver.cc:41] Found '/home/yuan/test3/cartographer_superbuild/cartographer/configuration_files/trajectory_builder_2d.lua' for 'trajectory_builder_2d.lua'.
[ INFO] [1602409271.779223140]: I1011 17:41:11.000000 31371 configuration_file_resolver.cc:41] Found '/home/yuan/test3/cartographer_superbuild/cartographer/configuration_files/trajectory_builder_3d.lua' for 'trajectory_builder_3d.lua'.
[ INFO] [1602409271.779278916]: I1011 17:41:11.000000 31371 configuration_file_resolver.cc:41] Found '/home/yuan/test3/cartographer_superbuild/cartographer/configuration_files/trajectory_builder_3d.lua' for 'trajectory_builder_3d.lua'.
[ INFO] [1602409271.783340706]: I1011 17:41:11.000000 31371 map_builder_bridge.cc:136] Added trajectory with ID '0'.
[ WARN] [1602409274.787163816]: W1011 17:41:14.000000 31371 node.cc:857] Expected topic "echoes" (trajectory 0) (resolved topic "/echoes") but no publisher is currently active.
[ WARN] [1602409274.787323572]: W1011 17:41:14.000000 31371 node.cc:857] Expected topic "imu" (trajectory 0) (resolved topic "/imu") but no publisher is currently active.
[ WARN] [1602409274.787405828]: W1011 17:41:14.000000 31371 node.cc:866] Currently available topics are: /constraint_list,/submap_list,/scan_matched_points2,/rosout,/tf,/rosout_agg,/trajectory_node_list,/landmark_poses_list,
[ WARN] [1602409286.879025720]: W1011 17:41:26.000000 31371 tf_bridge.cc:52] "base_link" passed to lookupTransform argument target_frame does not exist.
[ WARN] [1602409287.080094124]: W1011 17:41:27.000000 31371 tf_bridge.cc:52] "base_link" passed to lookupTransform argument target_frame does not exist.
[ WARN] [1602409287.282269438]: W1011 17:41:27.000000 31371 tf_bridge.cc:52] "base_link" passed to lookupTransform argument target_frame does not exist.
[ WARN] [1602409287.484532516]: W1011 17:41:27.000000 31371 tf_bridge.cc:52] "base_link" passed to lookupTransform argument target_frame does not exist.
[ WARN] [1602409287.686650920]: W1011 17:41:27.000000 31371 tf_bridge.cc:52] "base_link" passed to lookupTransform argument target_frame does not exist.
[ WARN] [1602409287.889005220]: W1011 17:41:27.000000 31371 tf_bridge.cc:52] "base_link" passed to lookupTransform argument target_frame does not exist.
[ WARN] [1602409288.090032656]: W1011 17:41:28.000000 31371 tf_bridge.cc:52] "base_link" passed to lookupTransform argument target_frame does not exist.
I cannot get any output because of those warnings. Can you help me?
Thank you!
/home/su/Carto_in_one/cartographer_superbuild/cartographer/cartographer/cloud/map_builder_server_options.h:22: error: cartographer/cloud/proto/map_builder_server_options.pb.h: No such file or directory
22 | #include "cartographer/cloud/proto/map_builder_server_options.pb.h"
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
There is no such file "map_builder_server_options.pb.h" under this folder
Hey Larics,
I followed your tips. However,when I reach the tip "cmake ../", the terminal showed
CMake Error in cartographer/CMakeLists.txt:
Target "cartographer" INTERFACE_INCLUDE_DIRECTORIES property contains path:
"/home/peng/carto/cartographer_superbuild/cartographer/"
which is prefixed in the source directory.
After that I can still make -j4,and run rviz launch .
But in the Clion, there is a problem that clion can't find the cartographer header files.
I can't google this problem. Have you ever met this problem?
F0918 15:03:33.563668 9225 offline_node.cc:80] Check failed: !FLAGS_configuration_directory.empty() -configuration_directory is missing.
F0918 15:03:33.000000 9225 offline_node.cc:80] Check failed: !FLAGS_configuration_directory.empty() -configuration_directory is missing.
*** Check failure stack trace: ***
@ 0x7fa18c1ef0cd google::LogMessage::Fail()
@ 0x7fa18c1f0f33 google::LogMessage::SendToLog()
@ 0x7fa18c1eec28 google::LogMessage::Flush()
@ 0x7fa18c1f1999 google::LogMessageFatal::~LogMessageFatal()
@ 0x558d2b70e1e8 (unknown)
@ 0x558d2b70655a (unknown)
@ 0x7fa189e18b97 __libc_start_main
@ 0x558d2b70b4ea (unknown)
Aborted (core dumped)
May be i am doing the execution wrong?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.