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

Support azureml-pipeline-steps on M1 Mac #23538

Closed
davystrong opened this issue Mar 16, 2022 · 12 comments
Closed

Support azureml-pipeline-steps on M1 Mac #23538

davystrong opened this issue Mar 16, 2022 · 12 comments
Assignees
Labels
Client This issue points to a problem in the data-plane of the library. customer-reported Issues that are reported by GitHub users external to the Azure organization. Machine Learning needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team question The issue doesn't require a change to the product in order to be resolved. Most issues start as that Service Attention Workflow: This issue is responsible by Azure service team.

Comments

@davystrong
Copy link

  • Package Name: azureml-pipeline-steps
  • Package Version: 1.39.0
  • Operating System: macOS Monterey 12.3
  • Python Version: 3.8.12

Describe the bug
I can't install azureml-pipeline-steps on an M1 Mac because some dependencies don't support ARM. I have found four problem dependencies:

  • pyarrow (azureml-pipeline-steps uses an old version which doesn't have ARM support. New versions do).
  • azureml-dataprep-native, azureml-dataprep-rslex and dotnetcore2, all of which are distributed as binary wheels and don't support ARM.

To Reproduce
Steps to reproduce the behavior:

  1. Run pip install azureml-pipeline-steps

Expected behavior
It should install correctly.

@ghost ghost added needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. customer-reported Issues that are reported by GitHub users external to the Azure organization. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that labels Mar 16, 2022
@azure-sdk azure-sdk added Client This issue points to a problem in the data-plane of the library. Machine Learning needs-team-triage Workflow: This issue needs the team to triage. labels Mar 16, 2022
@ghost ghost removed the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label Mar 16, 2022
@xiangyan99 xiangyan99 added CXP Attention and removed needs-team-triage Workflow: This issue needs the team to triage. labels Mar 16, 2022
@ghost ghost added the needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team label Mar 16, 2022
@SaurabhSharma-MSFT
Copy link
Member

@davystrong Thanks for reporting this issue. We are redirecting it to services team to look into it.

@SaurabhSharma-MSFT SaurabhSharma-MSFT added Service Attention Workflow: This issue is responsible by Azure service team. and removed CXP Attention labels Mar 18, 2022
@ghost
Copy link

ghost commented Mar 18, 2022

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @azureml-github.

Issue Details
  • Package Name: azureml-pipeline-steps
  • Package Version: 1.39.0
  • Operating System: macOS Monterey 12.3
  • Python Version: 3.8.12

Describe the bug
I can't install azureml-pipeline-steps on an M1 Mac because some dependencies don't support ARM. I have found four problem dependencies:

  • pyarrow (azureml-pipeline-steps uses an old version which doesn't have ARM support. New versions do).
  • azureml-dataprep-native, azureml-dataprep-rslex and dotnetcore2, all of which are distributed as binary wheels and don't support ARM.

To Reproduce
Steps to reproduce the behavior:

  1. Run pip install azureml-pipeline-steps

Expected behavior
It should install correctly.

Author: davystrong
Assignees: -
Labels:

question, Machine Learning, Service Attention, Client, customer-reported, needs-team-attention

Milestone: -

@nagydavid
Copy link

nagydavid commented Jun 13, 2022

HI @SaurabhSharma-MSFT, @bandsina May I ask, is there any update regarding the support of M1 ?

@lnkirkham-datasparq
Copy link

Also have the same issue. Any update on this?

@nagydavid
Copy link

nagydavid commented Jul 5, 2022

Hi @SaurabhSharma-MSFT ,@xiangyan99, @bandsina Can we have an ETA or options for possible solutions.

Thanks in advance

@xiangyan99
Copy link
Member

@azureml-github

@davystrong
Copy link
Author

It's almost 5 months since I opened this issue, would love an update. Is this anywhere near being fixed?

@lloydhamilton
Copy link

lloydhamilton commented Sep 16, 2022

Install x86_64 python packages on M1 MacBook Apple Silicon

Found a temporary workaround that will allow M1 MacBook Pros to install x86 binaries.

The steps here will install x86_64 binarys of homebrew, poetry and python. I am using pyenv and poetry to manage python environments and dependencies respectively.

Configure new rosetta terminal

  1. Duplicate a new terminal by going to applications>utilities>Terminal.app
  2. Rename the duplicated terminal app to Rosetta Terminal.
  3. Right click on Rosetta Terminal and select Get Info.
  4. Tick the box Open using Rosetta

Install x86 dependencies

  1. First of all to run x86 executables, we'll need to install [Rosetta]. Open a new Rosetta Terminal:
softwareupdate --install-rosetta --agree-to-license
  1. Install x86 Home-brew:
arch -x86_64 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"

This will install homebrew at /usr/local/Homebrew/bin/brew

  1. Add this short script in ~./zshrc:
archcheck () {
   if [ "$(uname -p)" = "i386" ]
   then
     echo "Running in i386 mode (Rosetta)"
     eval "$(/usr/local/Homebrew/bin/brew shellenv)"
     alias brew='/usr/local/Homebrew/bin/brew'
   elif [ "$(uname -p)" = "arm" ]
   then
     echo "Running in ARM mode (M1)"
     eval "$(/opt/homebrew/bin/brew shellenv)"
     alias brew='/opt/homebrew/bin/brew'
   else
     echo "Unknown architecture detected"
   fi
}
eval "archcheck"

This script will evaluate on start up of each terminal session and set the appropriate homebrew path.

  1. Install pyenv:
brew install pyenv
  1. Add pyenv configs in ~/.zshrc
export PYENV_ROOT="$HOME/.pyenv"
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.zshrc
echo 'command -v pyenv >/dev/null || export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.zshrc
echo 'eval "$(pyenv init -)"' >> ~/.zshrc
  1. Restart the shell:
exec "$SHELL"
  1. Install python build dependencies and poetry:
brew install openssl readline sqlite3 xz zlib tcl-tk poetry
  1. Add poetry alias to ~/.zshrc:
echo 'alias poetry="/usr/local/Cellar/poetry/1.2.0_1/libexec/bin/poetry"' >> ~/.zshrc
  1. Restart shell:
exec "$SHELL"
  1. Install python 3.8.13 using pyenv:
pyenv install 3.8.13

@WiktorMadejski
Copy link

WiktorMadejski commented Oct 10, 2022

+1

Developing Azure ML from M1 requires additional set up, both for local and remote development. Makes it harder to advocate for Azure ML to clients working with M1 local workspaces.

@WiktorMadejski
Copy link

Install x86_64 python packages on M1 MacBook Apple Silicon

Found a temporary workaround that will allow M1 MacBook Pros to install x86 binaries.

The steps here will install x86_64 binarys of homebrew, poetry and python. I am using pyenv and poetry to manage python environments and dependencies respectively.

Configure new rosetta terminal

  1. Duplicate a new terminal by going to applications>utilities>Terminal.app
  2. Rename the duplicated terminal app to Rosetta Terminal.
  3. Right click on Rosetta Terminal and select Get Info.
  4. Tick the box Open using Rosetta

Install x86 dependencies

  1. First of all to run x86 executables, we'll need to install [Rosetta]. Open a new Rosetta Terminal:
softwareupdate --install-rosetta --agree-to-license
  1. Install x86 Home-brew:
arch -x86_64 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"

This will install homebrew at /usr/local/Homebrew/bin/brew

  1. Add this short script in ~./zshrc:
archcheck () {
   if [ "$(uname -p)" = "i386" ]
   then
     echo "Running in i386 mode (Rosetta)"
     eval "$(/usr/local/Homebrew/bin/brew shellenv)"
     alias brew='/usr/local/Homebrew/bin/brew'
   elif [ "$(uname -p)" = "arm" ]
   then
     echo "Running in ARM mode (M1)"
     eval "$(/opt/homebrew/bin/brew shellenv)"
     alias brew='/opt/homebrew/bin/brew'
   else
     echo "Unknown architecture detected"
   fi
}
eval "archcheck"

This script will evaluate on start up of each terminal session and set the appropriate homebrew path.

  1. Install pyenv:
brew install pyenv
  1. Add pyenv configs in ~/.zshrc
export PYENV_ROOT="$HOME/.pyenv"
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.zshrc
echo 'command -v pyenv >/dev/null || export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.zshrc
echo 'eval "$(pyenv init -)"' >> ~/.zshrc
  1. Restart the shell:
exec "$SHELL"
  1. Install python build dependencies and poetry:
brew install openssl readline sqlite3 xz zlib tcl-tk poetry
  1. Add poetry alias to ~/.zshrc:
echo 'alias poetry="/usr/local/Cellar/poetry/1.2.0_1/libexec/bin/poetry"' >> ~/.zshrc
  1. Restart shell:
exec "$SHELL"
  1. Install python 3.8.13 using pyenv:
pyenv install 3.8.13

@lloydhamilton works for me, thanks for describing it so nicely.

My notes:

  • ) pyenv/poetry are not a must - key points are
  1. Install -x86_64 brew using Rosetta Terminal
  2. Use same brew to instal build dependencies
  3. When python installs dependency make sure correct build dependencies are used

-) Keep in mind the executions will be very slow.

@luigiw
Copy link
Contributor

luigiw commented Oct 24, 2022

v1 SDK is in maintenance only mode in favor of the v2 SDK being GA. Please file an issue for v2 SDK if your requests stand for v2.
https://learn.microsoft.com/en-us/azure/machine-learning/how-to-migrate-from-v1

@luigiw luigiw closed this as completed Oct 24, 2022
@WiktorMadejski
Copy link

WiktorMadejski commented Feb 9, 2023

Folks you can also use conda:

  1. Instal miniconda on your MacOS with Apple Silicon

  2. create conda environment:
    CONDA_SUBDIR=osx-64 conda create -p conda python=3.8.13 -y
    conda activate
    conda config --env --set subdir osx-64

  3. Enjoy Azure ML Python SDK v1

@github-actions github-actions bot locked and limited conversation to collaborators May 10, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Client This issue points to a problem in the data-plane of the library. customer-reported Issues that are reported by GitHub users external to the Azure organization. Machine Learning needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team question The issue doesn't require a change to the product in order to be resolved. Most issues start as that Service Attention Workflow: This issue is responsible by Azure service team.
Projects
None yet
Development

No branches or pull requests

10 participants