Mazhichaoruya / ROS-Object-Detection-2Dto3D-RealsenseD435

Use the Intel D435 real-sensing camera to realize object detection based on the Yolov3-5 framework under the Opencv DNN(old version)/TersorRT(now) by ROS-melodic.Real-time display of the Pointcloud in the camera coordinate system.
69 stars 9 forks source link

你好,我运行run.launch文件后报错可以帮忙解决下吗? #2

Open wuhaoqi-1 opened 3 years ago

wuhaoqi-1 commented 3 years ago

我用的是jetson xavier nx Ubuntu 18.04 ros melodic cuda 10.2 cudnn 7.6.5 tensorrt 7.0.0 深度相机用的是D455 运行run.launch 文件后D455可以正常启动,但报下面这样的错误 image

Mazhichaoruya commented 3 years ago

这个TensorRT的引擎加载错误,你的模型参数文件配置好了吗?在cuda trt环境搭建好的前提下 需要加载合适的推理模型 工程里面默认的是Yolov5

------------------ 原始邮件 ------------------ 发件人: "Mazhichaoruya/ROS-Object-Detection-2Dto3D-RealsenseD435" @.>; 发送时间: 2021年3月15日(星期一) 下午3:12 @.>; @.***>; 主题: [Mazhichaoruya/ROS-Object-Detection-2Dto3D-RealsenseD435] 你好,我运行run.launch文件后报错可以帮忙解决下吗? (#2)

我用的是jetson xavier nx Ubuntu 18.04 ros melodic cuda 10.2 cudnn 7.6.5 tensorrt 7.0.0 深度相机用的是D455 运行run.launch 文件后D455可以正常启动,但报下面这样的错误

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.

wuhaoqi-1 commented 3 years ago

我是直接使用从你的github上下载的coco.names和yolov5s.engine这两个文件image 我再试下自己生成这两个文件,运行看看会不会解决这个问题。 谢谢你的回复!

Mazhichaoruya commented 3 years ago

yolov5 有多个版本的模型 因为Github大小限制只上传了最小的s,但是仓库代码指定的好像不是s,具体过去太久我已经忘了,你可以去链接指向的开源仓库找配置的具体位置

------------------ 原始邮件 ------------------ 发件人: "Mazhichaoruya/ROS-Object-Detection-2Dto3D-RealsenseD435" @.>; 发送时间: 2021年3月15日(星期一) 晚上6:20 @.>; @.**@.>; 主题: Re: [Mazhichaoruya/ROS-Object-Detection-2Dto3D-RealsenseD435] 你好,我运行run.launch文件后报错可以帮忙解决下吗? (#2)

我是直接使用从你的github上下载的coco.names和yolov5s.engine这两个文件 我再试下自己生成这两个文件,运行看看会不会解决这个问题。 谢谢你的回复!

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.

wuhaoqi-1 commented 3 years ago

你好,我现在用自己在tensorrt上生成的yolov5s.engine文件,可以在你的这个Object-Detection-2Dto3D-RealsenseD435包中正常使用并能用深度相机检测出来物品。但我把yolov5s.engine模型文件放入到ROS-Object-Detection-2Dto3D-RealsenseD435这个包中,在ros环境下使用就会报之前那个错误/home/wu/remmina_screenshot-2021-3-18-8:21:1.394685.png 这个应该是改哪部分代码可以解决这个问题?

wuhaoqi-1 commented 3 years ago

![Uploading remmina_screenshot-2021-3-18-8:21:1.394685.png…]()

Mazhichaoruya commented 3 years ago

const auto window_name= "RGB Image"; char* input="../input/VOC"; char* output="../output/"; std::string filename; std::string weight="../engine/"; std::string classname_path="../engine/coco.names"; //stuff we know about the network and the input/output blobs static const int INPUT_H = Yolo::INPUT_H; 我在realsense_d435/src/Publisher_realsense.cpp 文件中定义了 模型参数的路径 默认的是在文件的上层目录 ,显然是错误的,建议改成绝对路径 抱歉 这个问题我应该在readme中指出 有时间我应该单独做一个配置文件的,最近太忙 没时间规划代码

wuhaoqi-1 commented 3 years ago

我改成绝对路径现在可以正常运行不报错了,谢谢啦