open-mmlab / mmdetection3d

OpenMMLab's next-generation platform for general 3D object detection.
https://mmdetection3d.readthedocs.io/en/latest/
Apache License 2.0
5.21k stars 1.53k forks source link

[Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' #2737

Open yuzhenboo opened 1 year ago

yuzhenboo commented 1 year ago

Prerequisite

Task

I'm using the official example scripts/configs for the officially supported tasks/models/datasets.

Branch

main branch https://github.com/open-mmlab/mmdetection3d

Environment

TorchVision: 0.15.1+cu117 OpenCV: 4.8.0 MMEngine: 0.8.4 MMDetection: 3.0.0 MMDetection3D: 1.2.0+0f9dfa9 spconv2.0: False

Reproduces the problem - code sample

(pt20gpu) ljLi@sstd:~/mmdetection3d$ python demo/pcd_demo.py demo/data/kitti/000008.bin configs/pointpillars/pointpillars_hv_secfpn_8xb6-160e_kitti-3d-car.py hv_pointpillars_secfpn_6x8_160e_kitti-3d-car_20220331_134606-d42d15ed.pth --show /home/ljLi/mmdetection3d/mmdet3d/models/dense_heads/anchor3d_head.py:94: UserWarning: dir_offset and dir_limit_offset will be depressed and be incorporated into box coder in the future warnings.warn( Loads checkpoint by local backend from path: hv_pointpillars_secfpn_6x8_160e_kitti-3d-car_20220331_134606-d42d15ed.pth /home/ljLi/anaconda3/envs/pt20gpu/lib/python3.9/site-packages/mmengine/visualization/visualizer.py:196: UserWarning: Failed to add <class 'mmengine.visualization.vis_backend.LocalVisBackend'>, please provide the save_dir argument. warnings.warn(f'Failed to add {vis_backend.class}, ' /home/ljLi/anaconda3/envs/pt20gpu/lib/python3.9/site-packages/torch/functional.py:504: UserWarning: torch.meshgrid: in an upcoming release, it will be required to pass the indexing argument. (Triggered internally at ../aten/src/ATen/native/TensorShape.cpp:3483.) return _VF.meshgrid(tensors, kwargs) # type: ignore[attr-defined] [Open3D WARNING] GLFW Error: X11: Failed to open display :0.0 [Open3D WARNING] Failed to initialize GLFW [Open3D WARNING] GLFW Error: The GLFW library is not initialized Traceback (most recent call last): File "/home/ljLi/mmdetection3d/demo/pcd_demo.py", line 60, in main(args) File "/home/ljLi/mmdetection3d/demo/pcd_demo.py", line 46, in main visualizer.add_datasample( File "/home/ljLi/anaconda3/envs/pt20gpu/lib/python3.9/site-packages/mmengine/dist/utils.py", line 401, in wrapper return func(*args, *kwargs) File "/home/ljLi/mmdetection3d/mmdet3d/visualization/local_visualizer.py", line 1071, in add_datasample self.show( File "/home/ljLi/anaconda3/envs/pt20gpu/lib/python3.9/site-packages/mmengine/dist/utils.py", line 401, in wrapper return func(args, kwargs) File "/home/ljLi/mmdetection3d/mmdet3d/visualization/local_visualizer.py", line 863, in show self.view_control.convert_to_pinhole_camera_parameters() # noqa: E501 AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters'

Reproduces the problem - command or script

python demo/pcd_demo.py demo/data/kitti/000008.bin configs/pointpillars/pointpillars_hv_secfpn_8xb6-160e_kitti-3d-car.py hv_pointpillars_secfpn_6x8_160e_kitti-3d-car_20220331_134606-d42d15ed.pth --show

Reproduces the problem - error message

AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters'

Additional information

No response

ioeddk commented 1 year ago

Any updates? I have the same problem.

Chuanheliu1 commented 1 year ago

yeah, encounter the same problem

yuzhenboo commented 1 year ago

问题还是没有解决

sunjiahao1999 commented 1 year ago

It seems to you run this demo on remote server. You should not use "--show" when $DISPLAY is None.

sunjiahao1999 commented 1 year ago

We will add a warning in this case.

yuzhenboo commented 1 year ago

就是当我没有输入--show的时候,依然没办法成功将结果输出到output中

yuzhenboo commented 1 year ago

就是当我没有输入--show的时候,依然没办法成功将结果输出到output中

thiesymon commented 11 months ago

it also does not work without "--show"

yuzhenboo commented 11 months ago

some question!!!!

what?

ppsychoo commented 9 months ago

Have you solve it? I have the same question!!!

Tzu-Hsiang-Lin commented 8 months ago

I solved the problem by setting conda-forge as my priority installation channel before installing PyTorch. Here is the link that shows you how to set the channel: https://ostechnix.com/enable-conda-forge-channel-for-conda-package-manager/ Some of the package bugs have been fixed in the conda-forge channel but not in the default channel.

caiyi4gis commented 7 months ago

I met and fixed the same problem when Open3D calls OpenGL, possibly due to dual graphics on the laptop. Follow these steps:

  1. Check 'nvidia-settings' for only the item < GPU 0 - Nvidia GeForce ...> .
  2. If yes, try 'sudo prime-select nvidia'.
samueleruffino99 commented 7 months ago

Is it possible to run this command on WSL2?

lin0711 commented 6 months ago

I met and fixed the same problem when Open3D calls OpenGL, possibly due to dual graphics on the laptop. Follow these steps:

  1. Check 'nvidia-settings' for only the item < GPU 0 - Nvidia GeForce ...> .
  2. If yes, try 'sudo prime-select nvidia'.

please speak it in detail, thanks

hyf493 commented 6 months ago

hello,Has this problem been resolved? I encountered this issue while running tools/misc/browse_dataset.py

AndrewSkywalker6666 commented 5 months ago

I encountered the same issue.

yuzhenboo commented 5 months ago

hello,Has this problem been resolved? I encountered this issue while running tools/misc/browse_dataset.py

Sorry,I still have not resolved this question

mhmdrz-mirdamadi commented 5 months ago

Same problem

YJJ1125 commented 4 months ago

请问是用的纯点云数据进行训练的吗?

yuzhenboo commented 4 months ago

不是,这个问题已经是差不多一年前的问题了,后来我就没有用这个算法进行检测 了

Onlyher @.***

 

------------------ 原始邮件 ------------------ 发件人: "open-mmlab/mmdetection3d" @.>; 发送时间: 2024年5月11日(星期六) 上午10:24 @.>; @.**@.>; 主题: Re: [open-mmlab/mmdetection3d] [Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' (Issue #2737)

请问是用的纯点云数据进行训练的吗?

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

hyf493 commented 4 months ago

我是使用的kitti多模态数据,我当时是想进行测试可视化

------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2024年5月11日(星期六) 中午12:00 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [open-mmlab/mmdetection3d] [Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' (Issue #2737)

不是,这个问题已经是差不多一年前的问题了,后来我就没有用这个算法进行检测 了

Onlyher @.***

&nbsp;

------------------&nbsp;原始邮件&nbsp;------------------ 发件人: "open-mmlab/mmdetection3d" @.&gt;; 发送时间:&nbsp;2024年5月11日(星期六) 上午10:24 @.&gt;; @.**@.&gt;; 主题:&nbsp;Re: [open-mmlab/mmdetection3d] [Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' (Issue #2737)

请问是用的纯点云数据进行训练的吗?

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.&gt; — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.>

hyf493 commented 4 months ago

sorry,I don't have a solution either.

------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2024年4月20日(星期六) 上午9:27 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [open-mmlab/mmdetection3d] [Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' (Issue #2737)

hello,Has this problem been resolved? I encountered this issue while running tools/misc/browse_dataset.py

Sorry,I still have not resolved this question

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>

hyf493 commented 4 months ago

抱歉,我好像是运行tools/misc/browse_dataset.py,出现的这个问题,具体是点云数据还是多模态数据,记不太清了

------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2024年5月11日(星期六) 中午12:00 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [open-mmlab/mmdetection3d] [Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' (Issue #2737)

不是,这个问题已经是差不多一年前的问题了,后来我就没有用这个算法进行检测 了

Onlyher @.***

&nbsp;

------------------&nbsp;原始邮件&nbsp;------------------ 发件人: "open-mmlab/mmdetection3d" @.&gt;; 发送时间:&nbsp;2024年5月11日(星期六) 上午10:24 @.&gt;; @.**@.&gt;; 主题:&nbsp;Re: [open-mmlab/mmdetection3d] [Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' (Issue #2737)

请问是用的纯点云数据进行训练的吗?

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.&gt; — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.>

YJJ1125 commented 4 months ago

好的 谢谢你。在排查过程种我发现 使用服务器进行点云数据读取可视化出现问题,主要是open3d无法创建窗口的问题,我还在持续跟进这个问题,再次感谢,

尹嘉洁

Tel:18732049152 @. | ---- 回复的原邮件 ---- | 发件人 | @.> | | 发送日期 | 2024年5月13日 08:49 | | 收件人 | @.> | | 抄送人 | @.> , @.***> | | 主题 | Re: [open-mmlab/mmdetection3d] [Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' (Issue #2737) |

抱歉,我好像是运行tools/misc/browse_dataset.py,出现的这个问题,具体是点云数据还是多模态数据,记不太清了

------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2024年5月11日(星期六) 中午12:00 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [open-mmlab/mmdetection3d] [Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' (Issue #2737)

不是,这个问题已经是差不多一年前的问题了,后来我就没有用这个算法进行检测 了

Onlyher @.***

&nbsp;

------------------&nbsp;原始邮件&nbsp;------------------ 发件人: "open-mmlab/mmdetection3d" @.&gt;; 发送时间:&nbsp;2024年5月11日(星期六) 上午10:24 @.&gt;; @.**@.&gt;; 主题:&nbsp;Re: [open-mmlab/mmdetection3d] [Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' (Issue #2737)

请问是用的纯点云数据进行训练的吗?

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.&gt; — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.>

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>

hyf493 commented 4 months ago

感谢,希望您尽快解决问题,有什么需要我帮助的,尽管说

------------------ 原始邮件 ------------------ 发件人: "open-mmlab/mmdetection3d" @.>; 发送时间: 2024年5月13日(星期一) 上午9:28 @.>; @.**@.>; 主题: Re: [open-mmlab/mmdetection3d] [Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' (Issue #2737)

好的 谢谢你。在排查过程种我发现 使用服务器进行点云数据读取可视化出现问题,主要是open3d无法创建窗口的问题,我还在持续跟进这个问题,再次感谢,

尹嘉洁

Tel:18732049152 @. | ---- 回复的原邮件 ---- | 发件人 | @.> | | 发送日期 | 2024年5月13日 08:49 | | 收件人 | @.> | | 抄送人 | @.> , @.***> | | 主题 | Re: [open-mmlab/mmdetection3d] [Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' (Issue #2737) |

抱歉,我好像是运行tools/misc/browse_dataset.py,出现的这个问题,具体是点云数据还是多模态数据,记不太清了

------------------ 原始邮件 ------------------ 发件人: @.&gt;; 发送时间: 2024年5月11日(星期六) 中午12:00 收件人: @.&gt;; 抄送: @.&gt;; @.&gt;; 主题: Re: [open-mmlab/mmdetection3d] [Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' (Issue #2737)

不是,这个问题已经是差不多一年前的问题了,后来我就没有用这个算法进行检测 了

Onlyher @.***

&amp;nbsp;

------------------&amp;nbsp;原始邮件&amp;nbsp;------------------ 发件人: "open-mmlab/mmdetection3d" @.&amp;gt;; 发送时间:&amp;nbsp;2024年5月11日(星期六) 上午10:24 @.&amp;gt;; @.**@.&amp;gt;; 主题:&amp;nbsp;Re: [open-mmlab/mmdetection3d] [Bug] 运行mmdetection3d里面的pcd_demo.py的时候出现这个问题AttributeError: 'NoneType' object has no attribute 'convert_to_pinhole_camera_parameters' (Issue #2737)

请问是用的纯点云数据进行训练的吗?

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.&amp;gt; — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.&gt;

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

woreom commented 1 month ago

Is it possible to run this command on WSL2?

I used to do it, but for some reason now I'm getting this error