I'm trying to import modules ending in cpython-39-darwin.so
and python doesn't recognize them. When I remove cpython-39-darwin
and just leave .so
, my program can recognize them, but then it raises an error about 'incompatible architecture'. I noticed this issue when trying to import open3d, but it's happening with other libraries too.
I have a new MacBook (M1 Pro) and I'm wondering if this has anything to do with the issue.
import open3d
ModuleNotFoundError Traceback (most recent call last)
Input In [26], in <cell line: 1>()
----> 1 import open3d
File ~/opt/anaconda3/lib/python3.9/site-packages/open3d/
init
.py:90, in <module>
84 warnings.warn(
85 "Open3D was built with CUDA support, but Open3D CUDA Python "
86 "binding library not found! Falling back to the CPU Python "
87 "binding library.", ImportWarning)
89 if
DEVICE_API
== 'cpu':
---> 90 from open3d.cpu.pybind import (camera, data, geometry, io, pipelines,
91 utility, t)
92 from open3d.cpu import pybind
94 import open3d.core
ModuleNotFoundError: No module named 'open3d.cpu.pybind'
The file itself is in /open3d/cpu/pybind.cpython-39-darwin.so
. When I change it to /open3d/cpu/pybind.so
, it recognizes the file, but now I get the following error:
ImportError
...
(mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e')), '/usr/local/lib/pybind.so' (no such file), '/usr/lib/pybind.so' (no such file)