-
Notifications
You must be signed in to change notification settings - Fork 5.2k
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
macOS arm64 (lack of) support should be documented #2798
Comments
Closing since I've moved on to other projects and won't be able to keep this issue up to date |
Hi @justin-f-perez , |
many thanks. In retrospect, mediapipe works normally as long as you find a way to advertise as x86_64. I updated the last sentence of the issue. (To suggest referencing the manufacturer docs instead of "try again later") overall problem isnt that mediapipe and other projects can't run on these machines- it's that they refuse to, because it appears to be an unsupported platform. If the user tricks the build tools into thinking they're running on x86_64, the emulator works well. |
Hello, I would just like to express my interest in this feature. I have an M1 Macbook Pro and I'm trying to figure out a method to use the mediapipe library in a python project. Any help would be greatly appreciated. Thanks! |
# create the environment using x86_64 python3
❯ conda create --name=my_mediapipe_environment --override-channels --channel='conda-forge/osx-64' python
# below line causes 'conda activate <env name>' to export CONDA_SUBDIR=osx-64
# this causes conda to look exclusively for x86_64 packages while the environment
# is active (thus, 'conda install' you do while the environment is active is sure
# to use the same architecture as your python)
❯ conda env config vars set --name=my_mediapipe_environment CONDA_SUBDIR=osx-64
# activate the environment
❯ conda activate my_mediapipe_environment
# install meidapipe, it works!
❯ pip install mediapipe
# test import mediapipe just be sure
❯ python -c 'import mediapipe'
# NOTE: it does *actually* work beyond just importing The alternative is to install an x86_64 python yourself and manually manage the environment. I don't recommend it. If you don't have |
You have no idea how long I've been looking or trying different solutions for this. I kept and old macbook just to debug mediapipe applications. Incredible thank you! |
Glad it helped! It looks like you may be able to install natively on M1 now too thanks to a community member building arm64 wheels under a different package name: #3277 I haven't tried this yet though |
URL(s) with the issue:
https://github.com/google/mediapipe/blob/master/docs/getting_started/python.md
https://github.com/google/mediapipe/blob/master/docs/getting_started/ios.md
https://github.com/google/mediapipe/blob/master/docs/getting_started/install.md#installing-on-macos
Description of issue (what needs changing):
On some paths through the Getting Started documentation, it's not clear that arm64 macs are unsupported at the moment. For example, the Android docs send you to install on mac which has you try- and fail- to build and run the C++ Hello World demo.
It seems arm64 macOS is unsupported, but that information isn't easy to find in the docs.
Current state
This is a common and unexpected outcome for new developers
PRs adding M1 support but
Getting Started > Python docs
install on macos without conda
see this thread for how to install without conda
install on macos with conda
These instructions assume
conda
is already installed (e.g. viabrew install --cask miniconda && conda init && exec zsh
)environment.yml
file:Installation > macOS docs
For example the following text could be added to the Installing on macOS section instructing users to attempt to build 'Hello world', "x86_64 only; macOS arm64 is currently unsupported. Please refer to the manufacturer documentation for running in x86_64 emulation mode."
The text was updated successfully, but these errors were encountered: