Minisforum MS S1 Max Comfy UI Guide

NP.

I’ve been working on doing an interesting RAG system and have had to deal with this, the Ryzen AI software, and switching my Python VENV a fair amount over the past 6 months. Got my GFX1151 in July.

You have Ryzen AI 1.6.1 (see Installation Instructions — Ryzen AI Software 1.6.1 documentation ) if you want to play with the NPU, which with the right model is great for something small, but is slower than GPU, depending on the size and need. Also, people need to realize that installing the wrong onnxruntime can then break the Ryzen AI suite for onnx models or that onnx directml models have limitations on the onnx instruction sets so that if you can use Torch and newer transformers, you can sometimes get faster results, but it is more difficult to get working versus some onnx models on Windows.

I personally set up Ryzen AI 1.6.1, then I add on the ROCm builds to the cloned conda environment of Ryzen AI 1.6.1 to get it working, followed by pointing the conda environment active.d folder env_vars.bat or env_vars.ps1 to set the environment pointing to the newer HIP and ROCm drivers in the repo or nightlies instead of the HIP SDK, which is still stuck on ROCm 6.4 for windows. Ryzen AI 1.6.1 has modules for python in python 3.12, so that is way better than the older Ryzen AI on windows in Python 3.10. I might just do a write up after christmas on how to setup the python conda environment to have both onnx and ROCm/Torch working properly on windows without WSL.

That might be important for someone running multiple models together (like I have with my RAG system, which I submitted for one of the cards). I’d love troubleshooting getting an R9700 working alongside this in a complex windows environment without using WSL to help the community on tips and tricks.

Edit: on further review of the nightlies, it seems they have now caught up v2 and v2-staging folders to be the same. There was a previous time when nightlies they were not. Ignore that part. Thank you.

But the repo link is good.

This is excellent news. I’ll give it a spin on Linux in the next few days.

1 Like

No such luck in my attempts on Linux. Looks like several ROCm nighties for Linux are missing. 7.10 does install but it leads to missing module errors when attempting to start ComfyUI.

Someone did make an automated script to get ComfyUI running on Strix Halo under Linux but it depends on Python 3.11 and uses ROCm 6.

I have been working on a video for weeks and still findinf rocm 6.4 for strix halo, plus scripts, way easier to use/more reliable. Even just long-running things seem to be more reliable

1 Like

https://repo.amd.com/rocm/whl/gfx1151/rocm-7.10.0.tar.gz
https://repo.amd.com/rocm/whl/gfx1151/rocm_sdk_core-7.10.0-py3-none-linux_x86_64.whl
https://repo.amd.com/rocm/whl/gfx1151/rocm_sdk_devel-7.10.0-py3-none-linux_x86_64.whl
https://repo.amd.com/rocm/whl/gfx1151/rocm_sdk_libraries_gfx1151-7.10.0-py3-none-linux_x86_64.whl
https://repo.amd.com/rocm/whl/gfx1151/torch-2.9.1%2Brocm7.10.0-cp312-cp312-linux_x86_64.whl
https://repo.amd.com/rocm/whl/gfx1151/torchaudio-2.9.0%2Brocm7.10.0-cp312-cp312-linux_x86_64.whl
https://repo.amd.com/rocm/whl/gfx1151/torchvision-0.24.0%2Brocm7.10.0-cp312-cp312-linux_x86_64.whl
https://repo.amd.com/rocm/whl/gfx1151/numpy-2.3.5-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
https://repo.amd.com/rocm/whl/gfx1151/

Here are the linux specific files for the release candidate repos (not nightlies) that should be more stable.

Make sure if you have rocm 6.4 installed for the system that after starting the venv, it is pointing to the python folder site-packages for the conda environment or python environment, however you have it setup.

I had a problem with it grabbing the wrong 6.4 hipclang and wrong hip drivers, using 6.4, until I setup the .bat or .ps1 in the activate.d folder (etc/conda/activate.d) to setup the env vars to have it properly use ROCm 7.9 and 7.10

After I did that, a lot of issues became much easier to work with. Nightlies were a nightmare to work with because they would sometimes not have the dates synced between ROCm and torch, which then caused a conflict on python packages. ANNOYING.

Here is an example of an env_vars.ps1 in windows conda environment for the setup after you have those packages installed. This is to ensure you are pointing to the right drivers, etc., or you may hit issues.

$env:ROCM_PATH = “C:\Users<user name>.conda\envs<venv name>\Lib\site-packages_rocm_sdk_core”
$env:PATH = “C:\Program Files\Tesseract-OCR;” + $env:PATH
$env:PATH = “C:\Program Files\Tesseract-OCR\tessdata;” + $env:PATH
$env:PATH = “C:\Users<user name>\AppData\Local\Programs\Tesseract-OCR\tessdata;” + $env:PATH
$env:TESSDATA_PREFIX = “C:\Program Files\Tesseract-OCR\tessdata” + $env:TESSDATA_PREFIX
$env:TESSERACT_PATH = “C:\Program Files\Tesseract-OCR” + $env:TESSERACT_PATH
$env:HIP_CLANG_PATH = “C:\Users<user name>.conda\envs<venv name>\Lib\site-packages_rocm_sdk_core\lib\llvm\bin” + $env:HIP_CLANG_PATH
$env:HIP_PATH = “C:\Users<user name>.conda\envs<venv name>\Lib\site-packages_rocm_sdk_core” + $env:HIP_PATH
$env:RYZEN_AI_INSTALLATION_PATH = “C:\Program Files\RyzenAI\1.6.1” + $env:RYZEN_AI_INSTALLATION_PATH
$env:TRITON_LIBHIP_PATH = “C:\Users<user name>.conda\envs<venv name>\Lib\site-packages_rocm_sdk_core\bin\amdhip64_7.dll”
$env:TORCH_ROCM_AOTRITON_ENABLE_EXPERIMENTAL = “1”

That might help, it might not, but it really helped me. I’ve been using python 3.12 since Ryzen AI 1.6.0 came out, although 1.6.1 is currently out. You need that for the ONNX for the NPU and directml, when applicable. But you have to do some weaving in as the newest packages use numpy 2.3.5, but the Ryzen AI 1.6.1 uses the older 1.26.4.

That means you may have to do multiple venv in some complex projects if you MUST have the newer numpy under a transformers/sentence-transformers scenario, but need onnx for a different model in the pipeline. RARE to come up, but worth noting.

https://rocm.docs.amd.com/en/7.10.0-preview/rocm-for-ai/pytorch-comfyui.html

Just found AMD put up the 7.10.0 preview where you can go through the matrix with instructions for comfy-ui, including the recommended driver link and instructions.

These are updated sometime in December after 7.10 preview was added to the official repo for download, instead of nightlies.

@wendell - see if that may help with stability, considering the updated instructions.

1 Like