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

fix(setup): install either tensorflow-macos or tensorflow depending on platform processor #124

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

btruhand
Copy link

Issue #, if available:

I have a M1 Mac and unable to install the dependencies for development using the provided command in the README which is pip install -e ".[test,dev]"

Error gotten:

ERROR: Could not find a version that satisfies the requirement tensorflow<2.11,>=2.4.0; extra == "dev" (from sagemaker-huggingface-inference-toolkit[dev,test]) (from versions: 2.13.0rc0, 2.13.0rc1, 2.13.0rc2, 2.13.0, 2.13.1, 2.14.0rc0, 2.14.0rc1, 2.14.0, 2.14.1, 2.15.0rc0, 2.15.0rc1, 2.15.0, 2.15.1, 2.16.0rc0, 2.16.1)
ERROR: No matching distribution found for tensorflow<2.11,>=2.4.0; extra == "dev"

Python version: 3.9.1

Description of changes:

Found a solution suggested by Apple here where for TF versions <= 2.12 we should install tensorflow-macos instead. Checking sys.platform == "darwin" and platform.processor() == "arm" seems to have fixed the problem for me

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

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

Successfully merging this pull request may close these issues.

1 participant