Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

51cmphere

macrumors newbie
Original poster
Mar 1, 2024
2
0
Hi. I am trying setup tensorflow and ML on my Mac Pro 5,1. It runs really well generally, but the hurdle is the non-avx processor. I've been trying for days to compile a non-avx version of TF, and I succeeded with version 2.9.2, and installed a non-avx version of the tensforflow-macos as force installed Metal . It works in the sense that the terminal returns that the correct version is installed. But it still complains of illegal hardware instruction and Python unexpectly quits when I test it out. I wonder if anyone else has successfully installed TF on a 5,1 and what versions they are using.

My setup is as follows:
Mac Pro (Mid 2010). Mac OS 12.7.3 (21H1015) using Open Core Legacy Patcher. 3.33 GHz 6-Core Intel Xeon X5680. Memory 64 GB 1333 MHz DDR3. AMD Radeon RX 5700 XT 8 GB.

Thanks!
 

impulse462

macrumors 68020
Jun 3, 2009
2,097
2,878
is this an officially supported non-avx version of TF? if not probably some inbuilt functions are still requiring hardware support which the 5,1 cpu doesn't have. curious to what your usecase is?
 

51cmphere

macrumors newbie
Original poster
Mar 1, 2024
2
0
Thanks. I want to use this to explore machine learning and local language models. I have Ollama running now with the CPU but it's too slow to be useful. I'd like to give it access to Home Assistant and a bunch of sensors around the house and see what it can do with smart home automations.

I'm trying to build TF with Bazel, but it is official TF. I am running into consistent problems during the build it which it stops because it says items inside the xcode app package are missing, even though copy and pasting the path into the finder or into another terminal take me straight to what it's look for. Ive fully deleted xcode and command line tools and re-installed, and even created a new mac user to ensure an extra clean environment. But every single time, this happens.

TF 2.9 is the only version that builds to completion with the non-avx flags, and the macos flag. But even then, after force installing the apple metal plugin and tensorflow-macos, or a non-avx version i found on github, it still complains of illegal instruction.

Given the community of 5,1 users and the power of the machine, Im surprised I haven't found more community builds readily available.

Thanks for your help.
 

impulse462

macrumors 68020
Jun 3, 2009
2,097
2,878
could you post a screenshot of the error message? i'm assuming youve googled the operation which TF uses that fails when trying to run on the CPU? TF 2.9 was released in 2022 and the 5,1 cpu was released in 2011. have you tried a TF 1.x version?
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.