admin管理员组文章数量:1305300
I want to import the PCL (Point Cloud Library). I am currently working in VS Code and my chosen Interpreter is Python 3.11.8, embedded in a conda environment. The PCL Version is 1.14.1.
When I run the line import pcl
in the code, it returns ModuleNotFoundError: No module named 'pcl'
. If I run the exact same command in the VS Code terminal, it runs without issues. Same for the regular terminal and conda power shell. conda list pcl
also returns the expected results, everything seems to work perfectly fine - until I want to import the PCL in my regular code.
First, I thought the issue was caused by errors in the interpreter selection, so I included the sys library and added print(sys.executable)
, which returns C:\detectors\pcl_win\python.exe
, which is the env's correct path.
For further trouble shooting I imported numpy for some simple operations. It was found inside the environment without any irregularities, code runs smoothly.
First, I thought the issue was caused by errors in the interpreter selection, so I included the sys library and added print(sys.executable)
, which returns C:\detectors\pcl_win\python.exe
, which is the env's correct path.
For further trouble shooting I imported numpy for some simple operations. It was found inside the environment without any irregularities, code runs smoothly.
I also checked the build, but it's working for other people around me.
Has anyone had the same or similar experiences, or ideas for further troubleshooting?
In the very beginning, I had issues with the pcl installation that turned out to be a bug, solved by a software update - I hope this time it's different.
This is the complete output in VS Code:
path is C:\detectors\pcl_win\python.exe Traceback (most recent call last): File "c:\detectors\harris3d\harris3d_keypointextraction.py", line 9, in import pcl ModuleNotFoundError: No module named 'pcl'
The terminal output for the sys-query is
path is C:\detectors\pcl_win\python.exe
本文标签: pythonPCL import fails in codebut not in terminal (VS Code)Stack Overflow
版权声明:本文标题:python - PCL import fails in code, but not in terminal (VS Code) - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1741799248a2398123.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论