Jeff Holmes MS MSCS
codecypher

Follow

codecypher

Follow
How to install Razer Core X on macOS

How to install Razer Core X on macOS

Guide to installing Razer Core X eGPU on macOS with Intel processor

Jeff Holmes MS MSCS's photo
Jeff Holmes MS MSCS
·Mar 23, 2022·

3 min read

Cover photo: Thomas Foster on Unsplash

Starting with macOS 12.1, Apple has added support for certain eGPU and AMD graphics cards[1] as well as the tensorflow-metal plugin [2]. Unfortunately, the Apple and Razer support websites seem to be missing quite a few steps, especially for macOS with an Intel processor.

Here is the system configuration that I am using:

Install Razer Core X

Here are the steps that worked for me:

  1. Disconnect all video inputs.

  2. Connect Razer Core X using USB-C cable.

  3. Connect computer monitor to Razer Core X using HDMI or DisplayPort cable.

  4. You should now see the eGPU menu bar item as shown in Figure 1. If you see a blank screen then you may need to shut down and Reset NVRAM or PRAM on your Mac [3] and/or Reset the SMC [4]. Then reboot once more.

  5. Now the eGPU should be working but the builtin Intel video processor has now been disabled. If so, disconnect all video inputs and connect only the USB-C or HDMI input from the Mac mini. Reset NVRAM or PRAM on your Mac [3] and/or Reset the SMC [4]. Then reboot once more.

  6. Leave the video input connected to the builtin Intel video processor which should be working now.

  7. Reconnect the USB-C cable to the Razer Core X and you should again see the menu bar icon shown in Figure 1 which means all is working now.

Figure 1: Apple menu bar

Install tensorflow-metal plugin

Here are the steps that worked for me:

  1. Edit the .zshrc file for your user profile and add the following code snippet:

  2. Open a terminal such xterm or iTerm2.

# Setup pyenv
export PYENV_ROOT="$HOME/.pyenv"
export PATH="$PYENV_ROOT/bin:$PATH"
eval "$(pyenv init --path)"

3. Open a terminal such xterm or iTerm.

4. Create a virtual environment (recommended) using Pyenv (python version 3.8 required):

python3 -m venv ~/tensorflow-metal  
source ~/tensorflow-metal/bin/activate  
python -m pip install -U pip  
pyenv local 3.8

5. Open a new terminal and verify the python version is 3.8. If not you need to tweak the setup of Pyenv via .zshrc:

pyenv -V

6. Install base TensorFlow:

python -m pip install tensorflow-macos

7. Install tensorflow-metal plugin:

python -m pip install tensorflow-metal

8. Verify install of tensorflow-metal plugin. Below is a sample tflow_test.py sample python script:

#!/usr/bin/env python3
import tensorflow as tf

# The driver function (confirm that code is under main function)
if __name__ == "__main__":
print(f"tensorflow version is {tf.__version__}")
print(f"{tf.config.list_physical_devices('GPU')}")

Sample output for tflow_test.py:

tensorflow version is 2.8.0
[PhysicalDevice(name='/physical_device:GPU:0', device_type='GPU')]

Now everything should be working. Enjoy!

References

[1] “Use an external graphics processor with your Mac,” Apple Support, Jan. 4, 2022.

[2] “Getting Started with tensorflow-metal PluggableDevice,” Apple Developer, Last accessed: Aug. 19, 2022.

[3] “Reset NVRAM or PRAM on your Mac,” Apple Support, Aug. 11, 2022.

[4] “How to reset the SMC of your Mac,” Apple Support, Aug. 16, 2022.

 
Share this