Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

3D点云的追踪 #12

Closed
JulyLi2019 opened this issue Sep 15, 2022 · 3 comments
Closed

3D点云的追踪 #12

JulyLi2019 opened this issue Sep 15, 2022 · 3 comments

Comments

@JulyLi2019
Copy link

你好,请问只有点云数据,如何只显示3D点云的追踪效果呢?

@hailanyi
Copy link
Owner

hailanyi commented Sep 16, 2022

你可以初始化一个viewer,然后循环的往里面只加入点云和box就行了,以下是一个示例

from viewer.viewer import Viewer
import numpy as np

vi = Viewer() # set box_type='OpenPCDet' if you use OpenPCDet boxes
len_dataset = 1000

for i in range(len_dataset):
    pseudo_boxes = np.array([[1+i*0.01, 1, 1, 1, 1, 1, 0]]) # your boxes
    ids = np.array([i]) # your boxes ids (optional)

    pseudo_points = np.random.randn(100, 3) # your points

    vi.add_points(pseudo_points, radius=4)
    vi.add_3D_boxes(pseudo_boxes, ids=ids)
    vi.show_3D() # press the Enter key to view

@JulyLi2019
Copy link
Author

你可以初始化一个viewer,然后循环的往里面只加入点云和box就行了,以下是一个示例

from viewer.viewer import Viewer
import numpy as np

vi = Viewer() # set box_type='OpenPCDet' if you use OpenPCDet boxes
len_dataset = 1000

for i in range(len_dataset):
    pseudo_boxes = np.array([[1+i*0.01, 1, 1, 1, 1, 1, 0]]) # your boxes
    ids = np.array([i]) # your boxes ids (optional)

    pseudo_points = np.random.randn(100, 3) # your points

    vi.add_points(pseudo_points, radius=4)
    vi.add_3D_boxes(pseudo_boxes, ids=ids)
    vi.show_3D() # press the Enter key to view

谢谢你的指导,目前已经可以连续播放点云数据了,但是每次按下回车总是会复原成初始化坐标系,我的数据集点云需要拉到上帝视觉才能看到点云与检测框,请问这个问题有什么好的解决办法吗?

@hailanyi
Copy link
Owner

Thank you for pointing out this problem, I have updated the viewer/ viewer.py. Now pressing Enter key will not reset the coordinate system.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants