Closed CAKGOD closed 3 years ago
Same here. Facing problems with installation on ubuntu20.04 and ros noetic
Forcing cmake to use c++ 14 did build the package for me, with some warnings. Add this to CMakeLists.txt for LeGO-LOAM
set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
Same here, PCL lib is having problem find Eigen:Index some how?
Forcing cmake to use c++ 14 did build the package for me, with some warnings. Add this to CMakeLists.txt for LeGO-LOAM
set(CMAKE_CXX_STANDARD 14) set(CMAKE_CXX_STANDARD_REQUIRED ON)
This does not work for me
Fix here worked for me: https://github.com/ethz-asl/lidar_align/issues/16
a temporary fix that worked for us: In /usr/include/flann/util/serialization.h at the top change the corresponding lines to:
#include "lz4.h"
#include "lz4hc.h"
Same here, PCL lib is having problem find Eigen:Index some how?
Have you been able to fix the issue @LucasWEIchen?
What about you @CAKGOD?
May be you can modify file /usr/include/pcl-1.10/pcl/filters/voxel_grid.h
line 340 and line 669 to solve it.
Just use int
to substitute Eigen::Index
. It works for me.
old:
for (Eigen::Index ni = 0; ni < relative_coordinates.cols (); ni++)
new:
for (int ni = 0; ni < relative_coordinates.cols (); ni++)
The solution provided by @notplus worked for me, although the change mast be done in a couple of places.
Thanks!
if you don't want to use int
to substitute Eigen::Index
, Specify a lower version of PCL, for exmaple, I use pcl-1.9 for instead, I add set(PCL_DIR "/usr/local/share/pcl-1.9/PCLConfig.cmake")
to the CMakeLists.txt
@shikeqin123 For me, installing PCL 1.9 parallel to 1.11 and adding set(PCL_DIR "/usr/local/share/pcl-1.9/PCLConfig.cmake")
to the CMakeLists.txt still results in Eigen::Index
errors because it is still using PCL 1.11 in pcl_ros (Maybe additional reconfiguration is required?)
However, the int
substitution proposed by @notplus works for me
An error occured when I buid the LeGO-LOAM on ubuntu 20.04. The error info is shown below.
/usr/include/pcl-1.10/pcl/filters/voxel_grid.h: In member function ‘std::vector<int> pcl::VoxelGrid<PointT>::getNeighborCentroidIndices(const PointT&, const MatrixXi&) const’: /usr/include/pcl-1.10/pcl/filters/voxel_grid.h:340:21: error: ‘Index’ is not a member of ‘Eigen’ 340 | for (Eigen::Index ni = 0; ni < relative_coordinates.cols (); ni++) | ^~~~~ /usr/include/pcl-1.10/pcl/filters/voxel_grid.h:340:21: note: suggested alternatives: In file included from /usr/include/opencv4/opencv2/flann.hpp:48, from /usr/include/opencv4/opencv2/opencv.hpp:65, from /home/cakgod/lego_loam/src/LeGO-LOAM/LeGO-LOAM/include/utility.h:14, from /home/cakgod/lego_loam/src/LeGO-LOAM/LeGO-LOAM/src/transformFusion.cpp:33: /usr/include/opencv4/opencv2/flann/flann_base.hpp:104:7: note: ‘cvflann::Index’
Some softwares on this system are shown below.Can you tell me how to solve this problem? Thanks~