Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting "FileNotFoundError: [WinError 3] The system cannot find the path specified: ''" when trying to clone a voice #98

Open
bimdas opened this issue Jul 8, 2023 · 6 comments

Comments

@bimdas
Copy link

bimdas commented Jul 8, 2023

Getting this error when trying to clone a voice.

Traceback (most recent call last):
File "F:\AI\Bark\installer_files\env\lib\site-packages\gradio\routes.py", line 439, in run_predict
output = await app.get_blocks().process_api(
File "F:\AI\Bark\installer_files\env\lib\site-packages\gradio\blocks.py", line 1384, in process_api
result = await self.call_function(
File "F:\AI\Bark\installer_files\env\lib\site-packages\gradio\blocks.py", line 1089, in call_function
prediction = await anyio.to_thread.run_sync(
File "F:\AI\Bark\installer_files\env\lib\site-packages\anyio\to_thread.py", line 33, in run_sync
return await get_asynclib().run_sync_in_worker_thread(
File "F:\AI\Bark\installer_files\env\lib\site-packages\anyio_backends_asyncio.py", line 877, in run_sync_in_worker_thread
return await future
File "F:\AI\Bark\installer_files\env\lib\site-packages\anyio_backends_asyncio.py", line 807, in run
result = context.run(func, *args)
File "F:\AI\Bark\installer_files\env\lib\site-packages\gradio\utils.py", line 700, in wrapper
response = f(*args, **kwargs)
File "F:\AI\Bark\bark\bark_webui.py", line 317, in clone_voice_gradio
clone_dir = clone_voice(
File "F:\AI\Bark\bark\bark_infinity\clonevoice.py", line 324, in clone_voice
audio_filepath_files = os.listdir(audio_filepath_directory)
FileNotFoundError: [WinError 3] The system cannot find the path specified: ''

@JonathanFly
Copy link
Owner

It's a bug, I'll try and fix Saturday night. In the meantime if you go the extras tap and make sure none of the path fields are blank, it should work for now.

@jurandfantom
Copy link

would like to report that same error goes for text2voice feature as well - will wait till next week for updates and test again. Wish to be more useful, but its fresh install step by step. Happy to find your project - love GUI and dedication :) wish you best of luck with it.

segment_text: hello world, my name is dog --Segment 1/1: est. 2.40s (1 of 1 iterations) hello world, my name is dog ----> negative_text_prompt: specific_npz_file_negative_prompt: None negative_text_prompt_logits_scale: None negative_text_prompt_divergence_scale: None -->All Audio Sections Finished at: 2023-07-11 17:28:47 in 29.45 seconds Traceback (most recent call last): File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\installer_files\env\lib\site-packages\gradio\routes.py", line 439, in run_predict output = await app.get_blocks().process_api( File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\installer_files\env\lib\site-packages\gradio\blocks.py", line 1384, in process_api result = await self.call_function( File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\installer_files\env\lib\site-packages\gradio\blocks.py", line 1089, in call_function prediction = await anyio.to_thread.run_sync( File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\installer_files\env\lib\site-packages\anyio\to_thread.py", line 33, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\installer_files\env\lib\site-packages\anyio\_backends\_asyncio.py", line 877, in run_sync_in_worker_thread return await future File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\installer_files\env\lib\site-packages\anyio\_backends\_asyncio.py", line 807, in run result = context.run(func, *args) File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\installer_files\env\lib\site-packages\gradio\utils.py", line 700, in wrapper response = f(*args, **kwargs) File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\installer_files\env\lib\site-packages\gradio\utils.py", line 700, in wrapper response = f(*args, **kwargs) File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\bark\bark_webui.py", line 749, in generate_audio_long_gradio ) = api.generate_audio_long_from_gradio(**kwargs) File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\bark\bark_infinity\api.py", line 1301, in generate_audio_long_from_gradio ) = generate_audio_long(**kwargs) File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\bark\bark_infinity\api.py", line 1616, in generate_audio_long write_one_segment( File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\bark\bark_infinity\api.py", line 505, in write_one_segment write_seg_wav(filepath, audio_arr, **kwargs) File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\bark\bark_infinity\api.py", line 562, in write_seg_wav write_audiofile(filepath, audio_arr, **kwargs) File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\bark\bark_infinity\api.py", line 677, in write_audiofile audio = AudioSegment.from_wav(temp_wav) File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\installer_files\env\lib\site-packages\pydub\audio_segment.py", line 808, in from_wav return cls.from_file(file, 'wav', parameters=parameters) File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\installer_files\env\lib\site-packages\pydub\audio_segment.py", line 728, in from_file info = mediainfo_json(orig_file, read_ahead_limit=read_ahead_limit) File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\installer_files\env\lib\site-packages\pydub\utils.py", line 274, in mediainfo_json res = Popen(command, stdin=stdin_parameter, stdout=PIPE, stderr=PIPE) File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\installer_files\env\lib\subprocess.py", line 971, in __init__ self._execute_child(args, executable, preexec_fn, close_fds, File "E:\Magazyn\Grafika\AI\Text2Voice\Bark_Suno_v2\installer_files\env\lib\subprocess.py", line 1456, in _execute_child hp, ht, pid, tid = _winapi.CreateProcess(executable, args, FileNotFoundError: [WinError 2] The system cannot find the file specified

@JonathanFly
Copy link
Owner

Just pushed a fix. If you know how to do a git pull you can do so.

If using the windows installer, you should be able just run TROUBLESHOOT_BARK_INFINITY.bat and then do the git pull (make sure you are in the bark directory)

@neonarc4
Copy link

@JonathanFly is clone voice not work for directml?


if get_SUNO_USE_DIRECTML() is True:
  ...
else:
   ...
    from .clonevoice import wav_to_semantics, generate_fine_from_wav, quick_clone

since u only define on else statement

@JonathanFly
Copy link
Owner

@JonathanFly is clone voice not work for directml?


if get_SUNO_USE_DIRECTML() is True:
  ...
else:
   ...
    from .clonevoice import wav_to_semantics, generate_fine_from_wav, quick_clone

since u only define on else statement

It didn't work for directml so I just did that to get Bark overall working. It might not be a hard fix, didn't try and figure it out.

I was kind of hoping DirectML would get a newer version and fix more bugs so it didn't require as many code changes. But I just checked, and it looks like torch-directml==0.2.0.dev230426 is still the latest version? I'm a little confused how to use the latest version on Github honestly. (I only used DirectML to try and get Bark to work this one time, not otherwise familiar with it.)

@neonarc4
Copy link

neonarc4 commented Jan 30, 2024

honestly look like these directml people didnt want to go recent torch version 2.1 and torch audio 2.1 but i heard hip sdk launched on rocm no idea about that part ;/ but waiting for rocm torch would be look like an month :_ guess let wait for directml v2.1

here hop in microsoft/DirectML#537

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants