question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cannot import name '_ext' && Pcl install on 18.04 Buntu

See original GitHub issue

Hello,

First of all, thank you for your work.

In the context of a concrete application for my thesis subject I would like to test your PVN3D code. However, I encounter a problem that I can’t correct. Indeed, when using demo_linemod.sh I encounter the following problem :

ImportError: cannot import name '_ext' from 'lib.pointnet2_utils' (/home/tpetitjean/PhD_Thesis/T1Pvn3D/PVN3D/pvn3d/lib/pointnet2_utils/__init__.py)

I’m sure I installed PointNet properly, and built it as indicated. I can see PointNet installed in my Conda env and using the python3 setup.py command build_ext has created a build file inside the PointNet tree.

Do you have any idea what I can do to correct this problem? Is there a file to move by hand after the build? Or is it the build that did not work as expected?

I thank you in advance for your clarification and wish you a very pleasant continuation. Sincerely, Theo

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:7

github_iconTop GitHub Comments

1reaction
aiai84commented, May 18, 2021

I saw your words and i think the main problem is the installation of the PCL on Ubuntu 18.04. I install it in two computer, ubuntu 16.04 and 20.04, IN 16.04, it is more easier, It seems that through sudo apt-get install libpcl-all can install . For 18.04 and higher, must through the git method
sudo apt install libpcl-dev libvtk6-dev clone fork with fix for Ubuntu 18.04 git clone https://github.com/Tuebel/python-pcl cd python-pcl python3 setup.py install ` pcl 1.7 is not suitable for 18.04, hope this will help you!

0reactions
liupengleicommented, Jun 30, 2021

I have the same problem, did you manage to solve this issue ?

Hi, yes i did, some point are explained here, if you can’t fix it with my previous answer, be sure to notify me, and i’ll do my possible to make the solution bit more clear in order to help there 😉

I solved this problem in a strange way, I installed the tutorial installation, and then Cannot import name’_ext’ appears; the solution: Change from. Import _ext to:

try: from lib.pointnet2_utils import _ext except ImportError: from torch.utils.cpp_extension import load import glob import os.path as osp import os

Read more comments on GitHub >

github_iconTop Results From Across the Web

I can find python-pcl by "pip list",but cannot import pcl #359
My environment: Ubuntu 18.04 anaconda 3.7 python 3.7 Here my pcl version looked by pip list: ... ModuleNotFoundError: No module named 'pcl.
Read more >
Install PCL Library on Python/Ubuntu 18.04 LTS
Step 4: type "python" on the terminal, then "import pcl". you will see another error for example: "libpcl-outofcore1.7", again search it that ...
Read more >
16.04 - What is the package to install full PCL with Aptitude ...
Asking on PCL Users Mailing List, I got this answer: Don't add that PPA. Just use what is distributed by default on Ubuntu....
Read more >
python-pcl Documentation
Users need not to install Cython as a distribution package of python-pcl only contains generated sources. 2.4 Uninstall python-pcl. Use pip to ...
Read more >
Install Openrave · GitBook - roboticslab-uc3m.github.io
Ubuntu 18.04 Bionic: OpenRAVE 0.9.0 with Python 2 bindings, FCL, and Qtcoin viewer. sudo apt install git lsb-release # probably already installed.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found