学习slam中遇到的各种问题整理(ubuntu16.0.4)

一.出现

运行时出错,提示:

point cloud size = 0
terminate called after throwing an instance of 'pcl::IOException'
  what():  : [pcl::PCDWriter::writeASCII] Input point cloud has no data!
已放弃 (核心已转储)
学习slam中遇到的各种问题整理(ubuntu16.0.4)

解决方法:学习slam中遇到的各种问题整理(ubuntu16.0.4)不要进入到bin文件下执行二进制文件,这样会不包含图片的路径.

二.ubuntu /  boot空间不足

注意:感谢博文https://blog.****.net/sinat_20059415/article/details/80211487   我只是记载了我成功的方法,该博文有三种方法,有兴趣的可以去试试其他方法

LVM installs and encrypted installs use a separate /boot partition. The partition by default is capable of holding only four or five kernels, and can fill to capacity quickly. To prevent your /boot partition from getting full, you need to configure automatic removal of old kernels, or manually remove old kernels regularly.

Changing the kernel providing packages on your system requires commands with root access, so please read RootSudo.

如下图所示,标红处在我进行kernel清除之前都是installed的状态,都占着/boot的空间,导致新的kernel版本安装不了。

学习slam中遇到的各种问题整理(ubuntu16.0.4)

PS:

1.查看自己kernel所处版本命令

[email protected]:~$ uname -r
4.13.0-39-generic

 

2.查看历史kernel安装命令

dpkg --get-selections|grep linux

 

3.卸载某个kernel版本

sudo apt-get remove linux-image-4.13.0-32(版本号见上面历史kernel获取)

 

三.can not find libvtkproj4.so

https://blog.****.net/****330/article/details/84999576 主要参照篇博客

在根目录下搜索是否有这个文件,查看版本号是否一样

学习slam中遇到的各种问题整理(ubuntu16.0.4)

遇到只有proj4.so 没有其他的两个文件,然后从新安装

sudo apt-get install libvtk5-dev

也有说在cmakelist.txt文件中加指令的,不过对于我的问题不太奏效,这个和博主一致,没起作用

    //在add_executable之前加上
     
    list(REMOVE_ITEM PCL_LIBRARIES "vtkproj4")
     
    //如果你使用PCL, 或者是用 VTK目录,也可以加上下面这个
     
    list(REMOVE_ITEM VTK_LIBRARIES "vtkproj4")