BagFromImage安装与使用

2015.11.02
一.
安装BagFromImages,之前在安装的时候在cmake .. 步骤出错,现在解决,估计是 工作空间 和 环境变量 的的问题,可能是开启终端时没有配置,在运行git clone https://github.com/raulmur/BagFromImages.git BagFromImages步骤前,
1.首先执行cd ~/catkin_ws 进入catkin_ws目录;
注:前提是已经创建了catkin 工作空间,如果没有,可以参考:http://wiki.ros.org/cn/ROS/Tutorials/InstallingandConfiguringROSEnvironment
2.source devel/setup.bash sourcez这个文件可以将当前工作空间设置在ROS工作环境的最顶层;
注:然后可以通过echo $ROS_PACKAGE_PATH查看确认当前工作空间,结果应该为/home/zhangxiwu/catkin_ws/src:/opt/ros/hydro/share:/opt/ros/hydro/stacks
3.执行cd src 进入ros工作空间,即/home/zhangxiwu/catkin_ws/src
4.执行git clone...
......
执行cmake ..
执行make
没有报错。
以下是运行的记录:
[email protected]:~$ source devel/setup.bash
bash: devel/setup.bash: 没有那个文件或目录
[email protected]:~$ cd ~/catkin_ws
[email protected]:~/catkin_ws$ echo $ROS_PACKAGE_PATH
/opt/ros/hydro/share:/opt/ros/hydro/stacks
[email protected]:~/catkin_ws$ source devel/setup.bash
[email protected]:~/catkin_ws$ echo $ROS_PACKAGE_PATH
/home/zhangxiwu/catkin_ws/src:/opt/ros/hydro/share:/opt/ros/hydro/stacks
[email protected]:~/catkin_ws$ cd src
[email protected]:~/catkin_ws/src$ git clone https://github.com/raulmur/BagFromImages.git BagFromImages
Cloning into ‘BagFromImages‘...
remote: Counting objects: 24, done.
remote: Compressing objects: 100% (16/16), done.
remote: Total 24 (delta 6), reused 24 (delta 6), pack-reused 0
Unpacking objects: 100% (24/24), done.
[email protected]:~/catkin_ws/src$ cd BagFromImages
[email protected]:~/catkin_ws/src/BagFromImages$ mkdir buils
[email protected]:~/catkin_ws/src/BagFromImages$ mkdir build
[email protected]:~/catkin_ws/src/BagFromImages$ cd build
[email protected]:~/catkin_ws/src/BagFromImages/build$ cmake ..
-- Found PythonInterp: /usr/bin/python (found version "2.7.3")
-- The C compiler identification is GNU
-- The CXX compiler identification is GNU
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
[rosbuild] Building package BagFromImages
[rosbuild] Cached build flags older than manifests; calling rospack to get flags
-- Using CATKIN_DEVEL_PREFIX: /home/zhangxiwu/catkin_ws/src/BagFromImages/build/devel
-- Using CMAKE_PREFIX_PATH: /home/zhangxiwu/catkin_ws/devel;/opt/ros/hydro
-- This workspace overlays: /home/zhangxiwu/catkin_ws/devel;/opt/ros/hydro
-- Using PYTHON_EXECUTABLE: /usr/bin/python
-- Python version: 2.7
-- Using Debian Python package layout
-- Using CATKIN_ENABLE_TESTING: ON
-- Skip enable_testing() for dry packages
-- Using CATKIN_TEST_RESULTS_DIR: /home/zhangxiwu/catkin_ws/src/BagFromImages/build/test_results
-- Looking for include files CMAKE_HAVE_PTHREAD_H
-- Looking for include files CMAKE_HAVE_PTHREAD_H - found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Found gtest sources under ‘/usr/src/gtest‘: gtests will be built
-- catkin 0.5.90
-- Using these message generators: gencpp;genlisp;genpy
[rosbuild] Including /opt/ros/hydro/share/roslisp/rosbuild/roslisp.cmake
[rosbuild] Including /opt/ros/hydro/share/roscpp/rosbuild/roscpp.cmake
[rosbuild] Including /opt/ros/hydro/share/rospy/rosbuild/rospy.cmake
-- Configuring done
-- Generating done
-- Build files have been written to: /home/zhangxiwu/catkin_ws/src/BagFromImages/build
[email protected]:~/catkin_ws/src/BagFromImages/build$ make
Scanning dependencies of target rospack_genmsg_libexe
[ 0%] Built target rospack_genmsg_libexe
Scanning dependencies of target rosbuild_precompile
[ 0%] Built target rosbuild_precompile
Scanning dependencies of target BagFromImages
[ 50%] Building CXX object CMakeFiles/BagFromImages.dir/main.cc.o
[100%] Building CXX object CMakeFiles/BagFromImages.dir/Thirdparty/DLib/FileFunctions.cpp.o
Linking CXX executable ../bin/BagFromImages
[100%] Built target BagFromImages
[email protected]:~/catkin_ws/src/BagFromImages/build$

二. 此时BagFromImages工具应该在ROS的工作空间下面了?

2015.11.03

一. BagFromImages终于可以正确运行了
步骤:
开启终端执行:
1. roscore 启动roscore服务;
在新的终端执行:
1. export ROS_PACKAGE_PATH=$ROS_PACKAGE_PATH:/home/zhangxiwu/BagFromImages 添加环境变量;
2. cd BagFromImages 进入BagFromImages文件夹;
3. rosrun BagFromImages BagFromImages test .jpg 30 test1 注意最后的一个文件名不要和之前的文件夹名重复,要不然还是会出现(核心已转储)的错误;

总结: 待生成的图像的存放在BagFromImages文件夹内;
之前出错应该是文件夹设置的太复杂了,导致出现(核心已转储)的错误,
还有,用的就是在主文件夹下面BagFromImages,
以后安装文件工具应该也安装在主文件夹下面;

时间: 2024-11-05 18:29:19

BagFromImage安装与使用的相关文章

安装Windows7系统时,提示:缺少所需的CD/DVD驱动器设备驱动程序

      测试机型:HP probook 430 g3       系统:Windows 7 Pro x64 现在笔记本电脑主板集成的USB口大多为3.0版本,而且一些厂商为了追求PC的轻薄,不再集成光驱,所以我们在安装系统时,一般只能通过U盘或U口外接光驱. 而当我们因为需要(安装OEM系统),在通过刻录软件(如UltraISO)将系统写入U盘或光盘的方式安装系统时,此时问题就可能悄悄出现了:因为Win7官方原版系统没有集成USB3.0驱动,所以可能的报错如下: 点击"浏览"或通过

Windows8.1-KB2999226-x64安装提示 此更新不适用你的计算机

如题 Windows8.1-KB2999226-x64.msu  双击安装 安装提示 此更新不适用你的计算机 . 解决方案: 放在D:\update\目录下 windows键+X  选择  命令提示符(管理员)  一定要是管理员 打开cmd 分别执行下面两句.红色部分就是自己的更新程序了.其他安装同理 例如Windows8.1-KB2919442-x64.msu 等 1    expand –F:* D:\update\Windows8.1-KB2999226-x64.msu D:\update

pip安装提示PermissionError: [WinError 5]错误问题解决

 问题现象 新安装python3.6版本后使用pip安装第三方模块失败,报错信息如下: C:\Users\linyfeng>pip install lxml Collecting lxml Downloading http://pypi.doubanio.com/packages/fb/41/b8d5c869d01fcb77c72d7d226a847a3946034ef19c244ac12920b71cd036/lxml-3.8.0-cp36-cp36m-win32.whl (2.9MB) 10

windows安装TortoiseGit详细使用教程【基础篇】

环境:win8.1 64bit 安装准备: 首先你得安装windows下的git msysgit1.9.5 安装版本控制器客户端tortoisegit  tortoisegit1.8.12.0 [32和64别下载错,不习惯英文的朋友,也可以下个语言包] 一.安装图解: 先安装GIT[一路默认即可] 安装好git以后,右键,会发现菜单多了几项关于GIT的选项 2.安装tortoisegit[一路默认即可] 安装好以后,右键,会发现菜单多了几项关于tortoisegit的选项 到此,安装算完成了,相

在Win10 Anaconda中安装Tensorflow

有需要的朋友可以参考一下 1.安装Anaconda 下载:https://www.continuum.io/downloads,我用的是Python 3.5 下载完以后,安装. 安装完以后,打开Anaconda Prompt,输入清华的仓库镜像,更新包更快: conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/ conda config --set show_channel_url

Linux下WebSphereV8.5.5.0 安装详细过程

Linux下WebSphereV8.5.5.0 安装详细过程 自WAS8以后安装包不再区别OS,一份介质可以安装到多个平台.只针对Installation Manager 进行了操作系统的区分 ,Websphere产品介质必须通过专门的工具Install Managere安装.进入IBM的官网http://www.ibm.com/us/en/进行下载.在云盘http://yun.baidu.com/share/linkshareid=2515770728&uk=4252782771 中是Linu

Python学习1-Python和Pycharm的下载与安装

本文主要介绍Python的下载安装和Python编辑器Pycharm的下载与安装. 一.Python的下载与安装 1.下载 到Python官网上下载Python的安装文件,进入网站后显示如下图: 网速访问慢的话可直接在这里下载:python-2.7.11.amd64 在Downloads中有对应的支持的平台,这里我们是在Windows平台下运行,所以点击Windows,出现如下: 在这里显示了Python更新的所有版本,其中最上面两行分别是Python2.X和Python3.X对应的最后更新版本

oracle安装故障:完美解决xhost +报错: unable to open display “”

oracle安装 先切换到root用户,执行xhost + 然后再切换到oracle用户,执行export DISPLAY=:0.0 出现乱码执行export LANG=US_en 在这里给大家介绍下两种情况的常见问题: 一种是本地运行的命令,另一种则是远程ssh命令安装. DISPLAY科普 DISPLAY变量是用来设置将图形显示到何处.比如CENTOS,你用图形界面登录进去,DISPLAY自动设置为DISPLAY=:0.0表示显式到本地监视器,那么通过终端工具(例如:xshell)进去,运行

centos7下使用yum安装mysql

CentOS7的yum源中默认好像是没有mysql的.为了解决这个问题,我们要先下载mysql的repo源. 1. 下载mysql的repo源 $ wget http://repo.mysql.com/mysql-community-release-el7-5.noarch.rpm 2. 安装mysql-community-release-el7-5.noarch.rpm包 $ sudo rpm -ivh mysql-community-release-el7-5.noarch.rpm 安装这个