当前位置:网站首页>[3D Detection Series-PointRCNN] Reproduces the PointRCNN code, and realizes the visualization of PointRCNN3D target detection, including the download link of pre-training weights (starting from 0 and
[3D Detection Series-PointRCNN] Reproduces the PointRCNN code, and realizes the visualization of PointRCNN3D target detection, including the download link of pre-training weights (starting from 0 and
2022-07-30 04:45:00 【Callme_TeacherPi℡】
[3D检测系列-PointRCNN] 复现PointRCNN代码
(1)Use the dataset format provided by the official website
(3)Displays with a specific index LiDAR 和图像
(4)显示带有modified LiDAR fileAppend point cloud labels/标记的 LiDAR 作为第 5 维
Attach the environment configuration first:
Ubuntu18.04
python3.6
pytorch 1.8.0 torchvision 0.9.0 cuda 11.1
(These few are in no hurry to dress up,后面有教程) mayavi 4.7.1 vkt 8.2.0 traits 6.2.0 traitsui 7.2.1 PyQt5 5.15.2
1.下载代码
https://github.com/sshaoshuai/PointRCNNPytorch版本的代码、直接进github下载,This step should not require much explanation.
If you can't download it, you can open a terminal directly,输入一下代码
git clone https://github.com/sshaoshuai/PointRCNN!!!!注意 !!!!
!!!The code is incomplete after downloading!!!
不然会报以下错误:No moudle named 'iou3d_cuda'
pointnet2_libOpen is empty,这个时候需要在githubOpen this folder separately,Download what's inside,Then put it in the local code folder.Then you also need to run the following code to install some tools:
sh build_and_install.sh错误1:

error: command 'gcc' failed with exit status 1
解决方法:进入一下目录:~/pointnet2_lib/pointnet2/src/ ----->将文件中所有cpp文件的的THCState_getCurrensStream(state) 全部改为 c10::cuda::getCurrentCUDAStream()
错误2:

解决方法:进入一下目录:~/lib/utils/roipool3d/src/roipool3d.cpp ----->将文件中的AT_CHECK 改为 TORCH_CHECK
2.准备数据集
(1)Use the dataset format provided by the official website
首先需要下载KITTI数据集,If you are on the official website, you don't have to try it because you can't download it at all.There is a big guy who uploaded it directly in Baidu cloud disk and everyone can download it in him.KITTI数据集下载(百度云)(It is not easy for the author to give others a thumbs up and support!!)
Then the data set structure of the official website is as follows:

Maybe some idiots don't understand(I'll try my best to explain it to you guys,可自行跳过),You can refer to mine below:

(2)使用软连接
because of runningPointRCNN之前,I ran firstPointPIllarsSo in order to avoid re-copying a copy,Soft connection can be used directly.将PointPillarsThe data set inside is directly connected here.
在PointRCNN的data/KITTI文件夹下:
ln -s (PointPillars数据集的路径) object
objectRepresents the name of the created folder,It's better to take that name,Otherwise, modify the code. And the path to the dataset is inclusivetraining和testing的根目录.然后就会生成一个object文件就OK了.
3.检测结果
Direct detection is possible using the author's pre-trained model,将模型放在tools下面,He can't download it from the Internet.我上传到CSDN了:----PointRCNN预训练权值-----
Next, start testing:
python eval_rcnn.py --cfg_file cfgs/default.yaml --ckpt PointRCNN.pth --batch_size 4 --eval_mode rcnn --set RPN.LOC_XZ_FINE false错误1:

TypeError: load() missing 1 requered positional argument : ‘Loader’
解决方法:
pip install pyyaml==5.1开始了!!!!Start waiting now!!

大约等10分钟后:

The detection results are placed under the following paths:
PointRCNN/output/rcnn/default/eval/epoch_no_number/val/final_result/4.结果可视化
Clone visualizer:
git clone https://github.com/kuixu/kitti_object_vis.gitAfter cloningdataAlso in the file like above2.(2)Set up a soft connection as well.可以把他的objectAfter deleting it, do it again.Then some dependencies are required:(Remember to use mirroring, otherwise it will be slow!!!)
pip install opencv-python pillow scipy matplotlib pyside2然后需要使用conda来安装mayavi,这个不能用pip我也不知道为什么....But it does work herepipBasically useless....不知道为什么
conda install mayavi然后在kitti_object_vis文件中打开终端:
(1)仅显示 LiDAR
python kitti_object.py --show_lidar_with_depth --img_fov --const_box --vis此时可能出现以下错误:
错误1:ModuleNotFoundError: No module named 'vtkIOParallelPython'
![]()
解决方法:
conda install jsoncpp=1.8.3
pip install pyface==7.3.0
Then continue our code to appear the interface:(大功告成!!)Press Enter once in the terminal to view the next image

Then there are several other different display methods below:(The specific can view the source codegithub kitti_object_vis)
(2)显示 LiDAR 和图像
python kitti_object.py --show_lidar_with_depth --img_fov --const_box --vis --show_image_with_boxes
(3)Displays with a specific index LiDAR 和图像
python kitti_object.py --show_lidar_with_depth --img_fov --const_box --vis --show_image_with_boxes --ind 1 
(4)显示带有modified LiDAR fileAppend point cloud labels/标记的 LiDAR 作为第 5 维
python kitti_object.py --show_lidar_with_depth --img_fov --const_box --vis --pc_label
自己写的所以有点复杂,但是至少能完成嘿嘿.如果各位有优化欢迎评论区讨论!!
大功告成!编写不易,大家成功后点个关注or赞谢谢~~
边栏推荐
- DAY17, CSRF vulnerability
- Database Design of Commodity Management System--SQL Server
- 4. Web Development
- Notes on "The Law of Construction"---Chapter 10 Typical Users and Scenarios
- handler+message [message mechanism]
- 全流程调度——Azkaban入门与进阶
- Catch That Cow(详解)
- file system two
- 斐波那契数列的递归优化《备忘录递归》
- Discourse 自定义头部链接(Custom Header Links)
猜你喜欢

WPF study notes "WPF Layout Basics"

Chapter8 支持向量机

Stimulsoft ReportsJS and DashboardsJS. 2022.3.3

How with Mexico Volkswagen VW EDI connection to Mexico

How does MySql find out the latest data row that meets the conditions?

The Complete Go Books - Beginner to Advanced and Web Development

The Azure developer news 丨 memorabilia in July
![[C language] Program environment and preprocessing](/img/d2/a0437da7d651e755951dd2a15827cf.png)
[C language] Program environment and preprocessing

六、读取应用配置+日志配置

复现XXL-JOB 任务调度中心后台任意命令执行漏洞
随机推荐
Get the local IP and Request's IP
Catch That Cow(详解)
[Awards every week] The "Edge Containers" track of the Cloud Native Programming Challenge invites you to fight!
文件系统二
小程序使用npm包定制全局样式
The Complete Go Books - Beginner to Advanced and Web Development
BGP的简单实验
Usage of EFR32 as sniffer for Zigbee/Thread
1. Get data - requests.get()
深圳见!云原生加速应用构建专场:来看云原生 FinOps、SRE、高性能计算场景最佳实践
字符串问题(下)
[Linear table] - Detailed explanation of three practice questions of LeetCode
QT(39)-vs development qt program prompts that the source file cannot be opened
全流程调度——Azkaban入门与进阶
A brief introduction to the SSM framework
Code open source design and implementation ideas
How with Mexico Volkswagen VW EDI connection to Mexico
六、读取应用配置+日志配置
LeetCode Algorithm 328. 奇偶链表
Thinkphp 5.0.24 Variable Override Vulnerability Causes RCE Analysis