Open3D-ML
Open3D-ML copied to clipboard
Installation issue in Apple MacBook Pro M1 Max chip ("Open3D was not built with PyTorch/TensorFlow support!")
Checklist
- [X] I have searched for similar issues.
- [X] I have tested with the latest development wheel.
- [X] I have checked the release documentation and the latest documentation (for
master
branch).
Steps to reproduce the issue
I installed Miniforge first and then Open3D, TensorFlow and PyTorch
conda create --name vision3d python=3.9
conda activate vision3d
pip install --upgrade pip
pip install open3d
pip install --pre torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/nightly/cpu
conda install -c apple tensorflow-deps==2.6.0
pip install tensorflow-macos==2.6.0
pip install tensorflow-metal==0.1.2
Later I cloned Open3D-ML by:
git clone https://github.com/isl-org/Open3D-ML.git
cd Open3D-ML
Then, I set OPEN3D_ML_ROOT with:
source set_open3d_ml_root.sh
Error message
python -c "import open3d.ml.torch as ml3d"
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/Users/username/miniforge3/envs/vision3d/lib/python3.9/site-packages/open3d/ml/torch/__init__.py", line 33, in <module>
raise Exception('Open3D was not built with PyTorch support!')
Exception: Open3D was not built with PyTorch support!
python -c "import open3d.ml.tf as ml3d"
Init Plugin
Init Graph Optimizer
Init Kernel
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/Users/username/miniforge3/envs/vision3d/lib/python3.9/site-packages/open3d/ml/tf/__init__.py", line 33, in <module>
raise Exception('Open3D was not built with TensorFlow support!')
Exception: Open3D was not built with TensorFlow support!
Open3D, Python and System information
- Operating system: (e.g. OSX 12.5)
- Python version: (e.g. Python 3.9.13)
- Open3D version: (0.15.1)
- System type: (apple-silicon)
- Is this remote workstation?: no
- How did you install Open3D?: (e.g. pip)
- Compiler version (if built from source): (e.g. gcc 13, clang 13) -- Not built from source
Additional information
@YilingQiao, @germanros1987, @yxlao please help.
Did you solve this issue? I have the same problem on Mac.
It looks like Open3d-Ml v0.15.1
needs pytorch==1.12.0
but pip install torch
on Mac M1 installs pytorch 1.13
, this is why we get this error: Exception: Open3D was not built with TensorFlow support!
See the requirements-torch.txt
, the torch for Darwin
platform:
--extra-index-url https://download.pytorch.org/whl/cpu/
torch==1.12.0+cpu ; sys_platform != 'darwin'
torchvision==0.13.0+cpu ; sys_platform != 'darwin'
torch==1.12.0 ; sys_platform == 'darwin'
torchvision==0.13.0 ; sys_platform == 'darwin'
tensorboard
So the only solution is building both pytorch=0.12 and open3d=0.15 from the source or waiting for a newer version of open3d.
Open3D v0.17 is built with PyTorch and tensorflow support for Apple Silicon.