首页 > 其他分享 >ORB-SLAM3 Core Dumped errors

ORB-SLAM3 Core Dumped errors

时间:2024-08-11 21:49:10浏览次数:11  
标签:Core catkin bridge image SLAM3 ws ros ORB cv

1

mode was set to :stereo. core dumped

ros cv_bidge using opencv may confilct with you own,so reintall cv_bridge

2

-Camera 1 parameters (Pinhole): [ 718.856 718.856 607.193 185.216 ]
 68995 Segmentation fault      (core dumped) 
# 	-Loaded misc parameters
----------------------------------
SLAM settings: 
	-Camera 1 parameters (Pinhole): [ 357.985 389.225 358.557 229.835 ]
段错误 (核心已转储)

the config yaml may be wrong. you can change to the official yaml,like KITTI00-02.yaml,and it will run.

3

terminate called after throwing an instance of ‘cv::Exception’what(): OpenCV(3.4.16) 
/home/seu/wsh/study/ch5/opencv-3.4.16/modules/imgproc/src/median_blur.dispatch.cpp:283: error: (-215:Assertion failed) !_src0.empty() in function ‘medianBlur’

yaml path erro

4

(ORB-SLAM3: Current Frame:3598): Gtk-ERROR **: 19:51:33.694: GTK+ 2.x symbols detected. Using GTK+ 2.x and GTK+ 3 in the same process is not supported
sudo apt remove libgtk3*

remove gtk3 , rebuild opencv and orbslam .run the demo again

5

Core dumped

ros opencv version confilct with orbslam version. changge the opencv version(you build frome source) or remove cvbridge and build it from source

To install cv_bridge from source, you will need to follow these steps:

  1. Setup ROS Workspace:
    Create a new ROS workspace if you haven't already done so. Here's how you can create a new workspace:

    mkdir -p ~/catkin_ws/src
    cd ~/catkin_ws/
    catkin_make
    source devel/setup.bash
    
  2. Clone cv_bridge Repository:
    Clone the cv_bridge repository into the src folder of your ROS workspace:

    cd ~/catkin_ws/src
    git clone https://github.com/ros-perception/vision_opencv.git
    

    The vision_opencv repository contains the cv_bridge package along with other related packages.

  3. Configure and Build:
    Configure and build the cv_bridge package and its dependencies within your workspace:

    cd ~/catkin_ws
    catkin_make
    
  4. Source Setup:
    Source the setup files to set up your environment:

    source devel/setup.bash
    
  5. Test Installation:
    Test the installation by running a simple node that uses cv_bridge. For example, you can write a small ROS node that subscribes to a camera topic and displays the image using cv_bridge.

Detailed Steps:

Step 1: Create a ROS Workspace

If you haven't created a ROS workspace yet, you can do so by following these commands:

mkdir -p ~/catkin_ws/src
cd ~/catkin_ws/
catkin_make
source devel/setup.bash

Step 2: Clone the Repository

Clone the vision_opencv repository, which contains cv_bridge:

cd ~/catkin_ws/src
git clone https://github.com/ros-perception/vision_opencv.git

Step 3: Build the Workspace

Build the vision_opencv packages and their dependencies:

cd ~/catkin_ws
catkin_make

Step 4: Set Up Environment

Set up the environment by sourcing the setup files:

source devel/setup.bash

Step 5: Test Installation

To test the installation, you can write a simple ROS node that subscribes to a camera topic and displays the image using cv_bridge. Here's an example of how you can do this:

#include "ros/ros.h"
#include "sensor_msgs/Image.h"
#include "cv_bridge/cv_bridge.h"
#include <opencv2/highgui/highgui.hpp>

void imageCallback(const sensor_msgs::ImageConstPtr& msg)
{
  try
  {
    cv::Mat image = cv_bridge::toCvShare(msg, "bgr8")->image;
    cv::imshow("Image window", image);
    cv::waitKey(30);
  }
  catch (cv_bridge::Exception& e)
  {
    ROS_ERROR("Could not convert from '%s' to 'bgr8'.", msg->encoding.c_str());
  }
}

int main(int argc, char** argv)
{
  ros::init(argc, argv, "image_listener");
  ros::NodeHandle nh;

  ros::Subscriber sub = nh.subscribe("/camera/image_raw", 1, imageCallback);

  ros::spin();

  return 0;
}

Compile the node and run it:

cd ~/catkin_ws/src
mkdir my_image_subscriber
cd my_image_subscriber
catkin_create_pkg my_image_subscriber rospy std_msgs cv_bridge
cd src
touch image_subscriber.cpp
vim image_subscriber.cpp

Copy the above code into image_subscriber.cpp and save the file. Then, build the package and run the node:

cd ~/catkin_ws
catkin_make
source devel/setup.bash
rosrun my_image_subscriber image_subscriber

Make sure to replace /camera/image_raw with the appropriate topic name for your camera.

If everything is set up correctly, you should see the images displayed in a window when you run the node.

If you encounter any issues during the build or while testing the installation, feel free to ask for further assistance!

6

-Loaded misc parameters
----------------------------------
SLAM settings: 
	-Camera 1 parameters (Pinhole): [ 357.985 389.225 358.557 229.835 ]
段错误 (核心已转储)

if you reach this and core dump, the config yaml may be wrong. you can change to the official yaml,like KITTI00-02.yaml,and it will run.

标签:Core,catkin,bridge,image,SLAM3,ws,ros,ORB,cv
From: https://www.cnblogs.com/happy-root/p/18353952

相关文章

  • 在IIS上部署ASP.NET Core Web API
    在IIS上部署ASP.NETCoreWebAPI和BlazorWasm详细教程  前言前段时间我们完成了七天.NET8操作SQLite入门到实战的开发系列教程,有不少同学留言问如何将项目发布部署到IIS上面运行。本篇文章我们就一起来讲讲在IIS上部署ASP.NETCoreWebAPI和BlazorWasm。前提条件......
  • 通过示例了解 .NET Core 中的依赖注入
    依赖注入(DI)是一种用于实现IoC(控制反转)的设计模式,可以更好地解耦应用程序内的依赖关系并更轻松地管理它们。.NETCore内置了对依赖注入的支持,提供了一种有效管理依赖关系的强大方法。一.什么是依赖注入?依赖注入是一种技术,其中一个对象提供另一个对象的依赖项。“依赖......
  • iOS的CoreImage框架技术详解
    CoreImage提供图像处理、人脸识别、图像增强、图像滤镜、图像转场。它操作的数据来自CoreGraphics、CoreVideo、ImageIO,使用CPU或GPU进行渲染。CoreImage对底层实现进行封装,为上层提供简单易用的API。一、CoreImage框架CoreImage框架分为:渲染层、处理层、API层。其中,渲染......
  • [rCore学习笔记 024]多道程序与协作式调度
    写在前面本随笔是非常菜的菜鸡写的。如有问题请及时提出。可以联系:[email protected]:https://github.com/WindDevil(目前啥也没有本节重点主要是对 任务 的概念进行进一步扩展和延伸:形成任务运行状态:任务从开始到结束执行过程中所处的不同运行状态:未初始化、准备......
  • Kubernetes:使用 K3s 为 CoreDNS 提供独立的 resolv.conf
     PodDNS解析的默认设置是CoreDNS使用worker节点底层操作系统的设置。如果您的KubernetesVM已加入多个网络或searchdomains,这可能会导致意外结果以及性能问题。如果您正在使用K3s,则可以为Kubelet提供一个独立的resolv.conf文件,该文件将由CoreDNS使用,并且不会与操......
  • .net core web 启动过程(1)
    1.要了解启动过程,先介绍 IHostingStartup和IStartup接口///<summary>///Representsplatformspecificconfigurationthatwillbeappliedtoa<seecref="IWebHostBuilder"/>whenbuildingan<seecref="IWebHost"/>.///</summary......
  • .net core web 启动过程(2)
    在.netcoreweb启动过程(1)中介绍了IHostStartup的执行过程,该文章主要介绍IStartup的执行过程。最常用的配置Startup方式,通过调用webHostBuilder扩展方法UseStartup<T>来指定。varhost=newHostBuilder().ConfigureWebHost(webHostBuilder=>{......
  • Nuget 管理器》》 error: NU1101: 找不到包 ViewFaceCore
    error:NU1101:找不到包ViewFaceCore错误解释:NU1101错误表示NuGet无法找到名为ViewFaceCore的包。这通常意味着包不存在于指定的源中,或者包名称拼写错误。解决方法:检查包名称:确保ViewFaceCore是正确的包名,没有拼写错误。检查源:确保你的NuGet配置包含了......
  • com.baomidou.mybatisplus.core.exceptions.MybatisPlusException: can not find lamb
    异常提示:com.baomidou.mybatisplus.core.exceptions.MybatisPlusException:cannotfindlambdacacheforthisentity 使用mockito框架做单元测试:mybatisplus使用Lambda表达式做条件查询、条件更新时会遇到mybatis拿不到缓存问题:错误1:com.baomidou.mybatisplus......
  • asp.net core 6 发布docker
    一、在项目当中创建dockerfile文件设置dockerfile属性为“始终复制”,FROMmcr.microsoft.com/dotnet/aspnet:6.0ASbaseWORKDIR/webCOPY..EXPOSE80EXPOSE443FROMbaseASfinalENTRYPOINT["dotnet","OneZhanMVC.dll"]二、创建镜像cd项目目录......