State of ML development on M1 mac [July 2021]

Hi,

I am a machine learning scientist and have been using Mac hardware for last 7 years for initial work and different prototypes. I use basic python packages, like numpy/pandas/scikit/seaborn for my work and all of them run decently on my existing Mac x86 based hardware. I opted for a Mac M1 hardware earlier this month assuming that the M1 arm64 related issues must have been sorted out or have some workarounds after 8 months post M1's launch.

I started setting up my M1 hardware (iMac) with the abovementioned python packages and I was surprised to see the current state of support of these basic ML tools on M1. It looks like (please correct me if I am wrong here), I have broadly two options-

  1. install miniconda or similar system and install each of these packages with precisely picked up version and create a virtual environment and check the progress & take care of circular dependencies among them! It is a nightmare to update versions of each package and run python code out of this env.

  2. install arm64 gcc and take source code from each of these packages from github and try to build them locally and resolve build problems by scrounging through forums and run in loops.

After failing to build all the packages numerous times and reformating the machine twice, I am started to wonder -

a) is the state of ML development on the latest flagship M1 model of an Apple device is really this bad now?

b) what happened to rosetta2 promise where I could install and run an x86 program on this M1 hardware when the performance is not a concern?

I would request the dev community to share your stories and how are you developing ML applications on your M1 hardware now.

Thanks!

To invoke Rosetta, you have to build for x64. Try:

arch -x86_64 brew install, or find how to specify the target for the compiler/runtime you need.

As to native M1 support: ML is probably to most hardware-specific software developers work with, so it is no wonder that it takes a while to migrate.

State of ML development on M1 mac [July 2021]
 
 
Q