boy1dr / SpleeterGui

Windows desktop front end for Spleeter - AI source separation
Apache License 2.0
2.27k stars 248 forks source link

deezer spleeter command doesn't work sometimes on windows. #128

Closed mdwhitis closed 2 years ago

mdwhitis commented 2 years ago

from: https://githubmemory.com/repo/deezer/spleeter

It appears that sometimes the shortcut command spleeter does not work properly on windows. This is a known issue that we will hopefully fix soon. In the meantime replace spleeter separate by python -m spleeter separate in command line and it should work.

boy1dr commented 2 years ago

Hi @mdwhitis i don't use the shortcut command since this version of python/spleeter are not actually installed on the computer. The command i use is "python -W ignore -m spleeter separate " followed by the options/paths etc.

Are you having some trouble with SpleeterGUI ? Have you recently clicked the "Spleeter core upgrade" ?

mdwhitis commented 2 years ago

yes I did the core upgrade... It's not outputting anything at all for me... I've tried several different songs and track configurations.

mdwhitis commented 2 years ago

same behavior with or without the core upgrade.

mdwhitis commented 2 years ago

I'm using RX 8 for now... but would prefer to use the spleetergui

boy1dr commented 2 years ago

In the latest Spleeter upgrade there is a bug that affects windows users. To confirm, try to run a song through and look at the error text near the end for "jitdebug". If you see this then you can get it working again by running this command (replace Chris with your username)

C:\Users\chris\AppData\Roaming\SpleeterGUI\python>python -m pip install -U llvmlite==0.32.1

If none of this makes sense, just run a song through SpleeterGUI, copy the output text in here so i can see whats going wrong.

mdwhitis commented 2 years ago

I did n got this mess:

PS C:\Users\y\AppData\Roaming\SpleeterGUI\python> python -m pip install -U llvmlite==0.32.1 Collecting llvmlite==0.32.1 Downloading llvmlite-0.32.1.tar.gz (104 kB) |████████████████████████████████| 104 kB 2.2 MB/s Building wheels for collected packages: llvmlite Building wheel for llvmlite (setup.py) ... error ERROR: Command errored out with exit status 1: command: 'C:\Users\y\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\python.exe' -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\setup.py'"'"'; file='"'"'C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' bdist_wheel -d 'C:\Users\y\AppData\Local\Temp\pip-wheel-h_8hyisq' cwd: C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ Complete output (24 lines): running bdist_wheel C:\Users\y\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\python.exe C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ffi\build.py Trying generator 'Visual Studio 14 2015 Win64' Traceback (most recent call last): File "C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ffi\build.py", line 192, in main() File "C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ffi\build.py", line 180, in main main_win32() File "C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ffi\build.py", line 89, in main_win32 generator = find_win32_generator() File "C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ffi\build.py", line 77, in find_win32_generator try_cmake(cmake_dir, build_dir, generator) File "C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ffi\build.py", line 28, in try_cmake subprocess.check_call(['cmake', '-G', generator, cmake_dir]) File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2032.0_x64__qbz5n2kfra8p0\lib\subprocess.py", line 368, in check_call retcode = call(*popenargs, *kwargs) File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2032.0_x64__qbz5n2kfra8p0\lib\subprocess.py", line 349, in call with Popen(popenargs, **kwargs) as p: File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2032.0_x64qbz5n2kfra8p0\lib\subprocess.py", line 951, in init self._execute_child(args, executable, preexec_fn, close_fds, File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2032.0_x64qbz5n2kfra8p0\lib\subprocess.py", line 1420, in _execute_child hp, ht, pid, tid = _winapi.CreateProcess(executable, args, FileNotFoundError: [WinError 2] The system cannot find the file specified error: command 'C:\Users\y\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\python.exe' failed with exit code 1

ERROR: Failed building wheel for llvmlite Running setup.py clean for llvmlite Failed to build llvmlite Installing collected packages: llvmlite Attempting uninstall: llvmlite Found existing installation: llvmlite 0.36.0 Uninstalling llvmlite-0.36.0: Successfully uninstalled llvmlite-0.36.0 Running setup.py install for llvmlite ... error ERROR: Command errored out with exit status 1: command: 'C:\Users\y\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\python.exe' -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\setup.py'"'"'; file='"'"'C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlitef34d676bf9c4495ebda987fa47c5d652\setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record 'C:\Users\y\AppData\Local\Temp\pip-record-lrhxmuz\install-record.txt' --single-version-externally-managed --user --prefix= --compile --install-headers 'C:\Users\y\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\Include\llvmlite' cwd: C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ Complete output (27 lines): running install running build got version from file C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\llvmlite/_version.py {'version': '0.32.1', 'full': 'aa11b129c0b55973067422397821ae6d44fa5e70'} running build_ext C:\Users\y\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\python.exe C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ffi\build.py Trying generator 'Visual Studio 14 2015 Win64' Traceback (most recent call last): File "C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ffi\build.py", line 192, in main() File "C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ffi\build.py", line 180, in main main_win32() File "C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ffi\build.py", line 89, in main_win32 generator = find_win32_generator() File "C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ffi\build.py", line 77, in find_win32_generator try_cmake(cmake_dir, build_dir, generator) File "C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\ffi\build.py", line 28, in try_cmake subprocess.check_call(['cmake', '-G', generator, cmake_dir]) File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2032.0_x64__qbz5n2kfra8p0\lib\subprocess.py", line 368, in check_call retcode = call(*popenargs, *kwargs) File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2032.0_x64__qbz5n2kfra8p0\lib\subprocess.py", line 349, in call with Popen(popenargs, **kwargs) as p: File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2032.0_x64qbz5n2kfra8p0\lib\subprocess.py", line 951, in init self._execute_child(args, executable, preexec_fn, close_fds, File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2032.0_x64qbz5n2kfra8p0\lib\subprocess.py", line 1420, in _execute_child hp, ht, pid, tid = _winapi.CreateProcess(executable, args, FileNotFoundError: [WinError 2] The system cannot find the file specified error: command 'C:\Users\y\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\python.exe' failed with exit code 1

Rolling back uninstall of llvmlite Moving to c:\users\y\appdata\local\packages\pythonsoftwarefoundation.python.3.9_qbz5n2kfra8p0\localcache\local-packages\python39\site-packages\llvmlite-0.36.0.dist-info\ from C:\Users\y\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\~lvmlite-0.36.0.dist-info Moving to c:\users\y\appdata\local\packages\pythonsoftwarefoundation.python.3.9_qbz5n2kfra8p0\localcache\local-packages\python39\site-packages\llvmlite\ from C:\Users\y\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\~lvmlite ERROR: Command errored out with exit status 1: 'C:\Users\y\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\python.exe' -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlite_f34d676bf9c4495ebda987fa47c5d652\setup.py'"'"'; file='"'"'C:\Users\y\AppData\Local\Temp\pip-install-hyhh1_h2\llvmlitef34d676bf9c4495ebda987fa47c5d652\setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record 'C:\Users\y\AppData\Local\Temp\pip-record-lrhxmuz\install-record.txt' --single-version-externally-managed --user --prefix= --compile --install-headers 'C:\Users\y\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\Include\llvmlite' Check the logs for full command output.

mdwhitis commented 2 years ago

before you requested that I was gonna send you this:

PS C:\Users\y\AppData\Roaming\SpleeterGUI\python> python -m spleeter --help Traceback (most recent call last): File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2032.0_x64qbz5n2kfra8p0\lib\runpy.py", line 197, in _run_module_as_main return _run_code(code, main_globals, None, File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2032.0_x64qbz5n2kfra8p0\lib\runpy.py", line 87, in _run_code exec(code, run_globals) File "C:\Users\y\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\spleeter__main__.py", line 24, in from typer import Exit, Typer File "C:\Users\y\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\typer__init__.py", line 5, in from click.exceptions import Abort as Abort File "C:\Users\y\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\click\init__.py", line 7, in from .core import Argument File "C:\Users\y\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\click\core.py", line 9, in from ._compat import isidentifier File "C:\Users\y\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\click_compat.py", line 667, in from ._winconsole import _get_windows_console_stream, _wrap_std_stream File "C:\Users\y\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\click_winconsole.py", line 10, in import ctypes File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2032.0_x64qbz5n2kfra8p0\lib\ctypes__init__.py", line 8, in from _ctypes import Union, Structure, Array ImportError: Module use of python37.dll conflicts with this version of Python

mdwhitis commented 2 years ago

fixed using absolute path to python:

PS C:\Users\y\AppData\Roaming\SpleeterGUI\python> .\python.exe -m spleeter --help Usage: main.py [OPTIONS] COMMAND [ARGS]...

Options: --help Show this message and exit.

Commands: evaluate Evaluate a model on the musDB test dataset separate Separate audio file(s) train Train a source separation model PS C:\Users\y\AppData\Roaming\SpleeterGUI\python> .\python.exe -m pip install -U llvmlite==0.32.1 Requirement already up-to-date: llvmlite==0.32.1 in c:\users\y\appdata\roaming\spleetergui\python\lib\site-packages (0.32.1)

mdwhitis commented 2 years ago

but I still get no output

boy1dr commented 2 years ago

press windows key, type "cmd" and hit enter. then paste this following line and hit enter

C:\Users\y\AppData\Roaming\SpleeterGUI\python\python -m pip install -U llvmlite==0.32.1

mdwhitis commented 2 years ago

PS C:\Users\y> C:\Users\y\AppData\Roaming\SpleeterGUI\python\python -m pip install -U llvmlite==0.32.1

Requirement already up-to-date: llvmlite==0.32.1 in c:\users\y\appdata\roaming\spleetergui\python\lib\site-packages (0.32.1)

boy1dr commented 2 years ago

hmm, that's the only fix i know of. You will have to uninstall SpleeterGUI and re-install. But don't run the core upgrade until the python scripts are fixed by Deezer. I will change the notice on my site when that happens so just check in there periodically. https://makenweb.com/SpleeterGUI

mdwhitis commented 2 years ago

I did the ununinstall/reinstall already... still not working... it used to... not sure why

boy1dr commented 2 years ago

that is strange. After you uninstall, just check that this folder has been deleted before you reinstall C:\Users\y\AppData\Roaming\SpleeterGUI

mdwhitis commented 2 years ago

Yeah I did that... still doesn't work after reinstall

"Starting processing of all songs Processing C:\Users\y\Music\Talk Talk - HAPPINESS IS EASY - 1986.mp3 Finished processing all songs

Run complete"

folder in empty at the finish tho.

boy1dr commented 2 years ago

maybe there is something wrong with the mp3 file or the output location. i just output mine to a "output" folder on my desktop. i know there is problems with python writing to some locations on a pc outside of desktop and documents.

I just did a full uninstall, delete then re-install and it is working fine. There's no error after a re-install though? it's just not working.

you could try running it as administrator (right click the SpleeterGUI icon and click run-as-administrator). possibly even needs to be installed as administrator

mdwhitis commented 2 years ago

Yeah... running as administrator fixed it... I shoulda thought of that earlier

mdwhitis commented 2 years ago

Srry... I think I've finally gotten to the root of what I wanna complain about here. It works but only for 2 parts... 4 & 5 don't work... just saying it ran but not outputting anything.

boy1dr commented 2 years ago

Windows doesn't like Python very much. I found if i have ransomware protection turned on quite a lot of python based software simply doesn't work. Some anti-virus softwares may do something similar.

you can move C:\Users\y\AppData\Roaming\SpleeterGUI to another location that has less security and you will find it works better. "my documents" or on a second hard drive should work best. definitely not "c:\SpleeterGUI".

If you move that SpleeterGUI folder, next time you run SpleeterGUI click "Advanced -> Set SpleeterGUI path" and choose the new location.

To fix the 4 & 5 part modes you need to delete the pretrained models for them. next time you use them they will be downloaded again as long as nothing is preventing the download. They can be found in the "SpleeterGUI\pretrained_models" folder. delete folders "4stems" and "5stems".

mdwhitis commented 2 years ago

I have no antivirus running.

I moved C:\Users\y\AppData\Roaming\SpleeterGUI to C:\Users\y\Documents\SpleeterGUI and updated the path in SpleeterGUI

I deleted the 4 & 5 model training data.

Set the output path to my desktop.

running as administrator... I ran it for 4 channels... downloads the training data... says it runs... but no output

boy1dr commented 2 years ago

There has been some issues with the last few updates from Spleeter, i have managed to get python stable again. The latest installer 2.9.2 can be found here https://makenweb.com/SpleeterGUI