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

AttributeError: module 'open3d' has no attribute 'cpu' #5133

Open
neurodiverseEsoteric opened this issue Jul 5, 2024 · 5 comments
Open

AttributeError: module 'open3d' has no attribute 'cpu' #5133

neurodiverseEsoteric opened this issue Jul 5, 2024 · 5 comments

Comments

@neurodiverseEsoteric
Copy link

neurodiverseEsoteric commented Jul 5, 2024

Problem statement

Is the problem installation related? then visit this page first https://github.com/nortikin/sverchok#troubleshooting-installation-errors_.

For any other issues, or if the installation still failed; Please describe the problem here.

Steps to reproduce

  1. install sverchok
  2. install extras/site-packages for sverchok
  3. attempt to enable Sverchok-Open3d

Expected result

Sverchok-Open3d enabled
What did you expect to see as a result of those steps?
IDK I just wanted to enable all the things just in case

Actual result

Sverchok-Open3d addon fails to enable

What did you actually get?

Traceback (most recent call last): File "~/Applications/BLENDERS/stable/blender-4.1.1-stable.e1743a0317bc/4.1/scripts/modules/addon_utils.py", line 376, in enable mod = importlib.import_module(module_name) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "~/Applications/BLENDERS/stable/blender-4.1.1-stable.e1743a0317bc/4.1/python/lib/python3.11/importlib/__init__.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "<frozen importlib._bootstrap>", line 1204, in _gcd_import File "<frozen importlib._bootstrap>", line 1176, in _find_and_load File "<frozen importlib._bootstrap>", line 1147, in _find_and_load_unlocked File "<frozen importlib._bootstrap>", line 690, in _load_unlocked File "<frozen importlib._bootstrap_external>", line 940, in exec_module File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed File "~/.config/blender/4.1/scripts/addons/sverchok-open3d-master/__init__.py", line 34, in <module> from sverchok_open3d import sockets File "~/.config/blender/4.1/scripts/addons/sverchok-open3d-master/sockets.py", line 14, in <module> TriangleMesh = o3d.cpu.pybind.geometry.TriangleMesh ^^^^^^^ AttributeError: module 'open3d' has no attribute 'cpu'

Sverchok version

sverchok-master.zip

This is especially important for installation-related issues. Please specify how do you install Sverchok: from sverchok-master.zip from github, or from release zip file, or from cloned git repo.

@satabol
Copy link
Collaborator

satabol commented Jul 14, 2024

Hi @neurodiverseEsoteric
What operation system you are using? Can you do screenshot of error with full error text ? (Expand window before screen)

@neurodiverseEsoteric
Copy link
Author

ArchLinux x86_64 on a dell XPS

@satabol
Copy link
Collaborator

satabol commented Jul 25, 2024

Hi @neurodiverseEsoteric.

I have no ArchLinux now but can you do some actions to get more info:

  1. Open Scripting TAB in Blender:
    image
  2. Execute next commands:
    2.1. from sverchok_open3d.dependencies import open3d as o3d
    2.2. dir(o3d)

and put here a screenshot of a result?

@neurodiverseEsoteric
Copy link
Author

Sorry, but it seems the error was with the specific version of blender I downloaded. I'm able to install open3d and get the same output as you have in your screenshots for both stable builds of Blender versions 3 and 4. If I come across it again with another build; I'll let you know. Thanks anyway...

@nortikin
Copy link
Owner

it seems, open3d can be build with cuda or cpu

dir(o3d)
['DEVICE_API', 'builtins', 'cached', 'doc', 'file', 'loader', 'name', 'package', 'path', 'spec', 'version', '_build_config', '_jupyter_labextension_paths', '_jupyter_nbextension_paths', '_ml3d', '_pybind_cuda', 'camera', 'core', 'cuda', 'data', 'geometry', 'io', 'ml', 'open3d', 'pipelines', 'platform', 'pybind', 't', 'utility', 'visualization']

@nortikin nortikin reopened this Sep 16, 2024
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

3 participants