(Hacky Fixes Included) The UI resolves incorrect directory for ACE-Step-1.5 on Linux & Torchcodec icompatibility with PyTorch 2.10
Hello! There were some problems I ran into when setting this up on EndeavourOS (Arch Linux), and I'd like to share the issues here for both the creator and for users looking for a quick fix.
The fixes
If you'd just like to see the fixes, here the are.
python ENOENT
If you're getting this error in the UI:
Generation failed. Please try again.: spawn /home/ferase/AI/ACEStep/ace-step-ui/ACE-Step-1.5/env/bin/python ENOENT
Follow these steps:
- Make sure both the backend and frontend are setup via
ace-step-ui/setup.sh - Create a symlink for the
ACE-Step-1.5folder insideace-step-ui - Inside the
ACE-Step-1.5folder, make a symlink for the.venvfolder created by UV within the same folder and name itenv
Your directory structure should look something like this now:
- ACEStep/ (parent folder)
- ACE-Step-1.5/
- ace-step-ui/
- ACE-Step-1.5/ (symlink to ../ACE-Step-1.5)
- .venv/
- ...
- env/ (symlink to ./venv)
- ...
No audio files generated/Torchcodec
Instead of cloning the original ACE-Step-1.5 repo, clone this fork by psale that removes the need for Torchcodec: https://github.com/psale/ACE-Step-1.5
Its pull request is here: https://github.com/ace-step/ACE-Step-1.5/pull/1145
Two things though:
- You should not retian your old environment, use UV to make a new one as per the instructions in this repo
- You still need to symlink all of the aforementioned folders as this doesn't fix that issue
Now, to the more in-depth explanations of my experience with these issues.
Bad Ace-Step-1.5 Path
Running through the install instructions of this UI, it was made clear to place the folders of both the backend and frontend beside one another. This is how I set it up, with the structure looking like this:
- ACEStep/ (parent folder)
- ACE-Step-1.5/ (backend)
- ace-step-ui/ (frontend, this project)
However, upon launching the UI after installing relevant dependencies, attempting to generate a song resulted with the UI raising this error:
Generation failed. Please try again.: spawn /home/ferase/AI/ACEStep/ace-step-ui/ACE-Step-1.5/env/bin/python ENOENT
This suggests it expects ACE-Step-1.5 to be stored within the ace-step-ui folder, contrary to the instructions. However, moving it there caused various other errors (I don't have them saved, so I can't put them here). Therefore, it seems like the UI is getting confused on where it thinks the backend should be. This is corroborated by the UI, despite failing to generate audio, creating an ACE-Step-1.5/output folder tree under ace-step-ui.
My solution was to symlink the ACE-Step-1.5 folder inside the ace-step-ui folder. However, I was also required to then symlink the .venv folder inside the ACE-Step-1.5 folder to an env folder inside the same directory, meaning ACE-Step-1.5 would contain .venv (the actual environment created by UV) and env (a symlink to that folder) because the UI expected python to be found at ace-step-ui/ACE-Step-1.5/env/bin/python, not ace-step-ui/ACE-Step-1.5/.venv/bin/python.
PyTorch 2.10 and Torchcodec
This isn't an issue with this repo, rather this seems to be a problem with ACE Step and UV. I note it here for users encountering the issue and for if the creator wishes to make a disclaimer for those installing the UI.
The UV environment installs torch==2.10, which seems to be the intended version by ACE Step. This will cause songs to fail to export at the end of generation because libtorchcodec.so isn't fully compatible with PyTorch 2.10.
My fix for this was grabbing this fork of ACE-Step-1.5 from psale: https://github.com/psale/ACE-Step-1.5
You can see the pull request here: https://github.com/ace-step/ACE-Step-1.5/pull/1145