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

docker compose up --build Error : espeak-ng-data/phontab': No such file or directory. #127

Closed
small-tk opened this issue Feb 7, 2025 · 10 comments

Comments

@small-tk
Copy link

small-tk commented Feb 7, 2025

kokoro-tts-1 | Error processing file '/home/runner/work/espeakng-loader/espeakng-loader/espeak-ng/_dynamic/share/espeak-ng-data/phontab': No such file or directory.

@651764643
Copy link

This issue occurs on a computer with an x86 architecture, using an Intel CPU.

@TheMrCodes
Copy link

Still a problem for me on windows with AMD Ryzen processor.

@remsky But got it patch by changing the folder creation hierarchy, by first creating the share.

Here is my one line change:

diff --git a/docker/gpu/Dockerfile b/docker/gpu/Dockerfile
index 2360b82..86d041c 100644
--- a/docker/gpu/Dockerfile
+++ b/docker/gpu/Dockerfile
@@ -3,7 +3,8 @@ FROM --platform=$BUILDPLATFORM nvidia/cuda:12.4.1-cudnn-runtime-ubuntu22.04
 ENV DEBIAN_FRONTEND=noninteractive
 
 # Install Python and other dependencies
-RUN apt-get update && apt-get install -y \
+RUN mkdir -p /usr/share/espeak-ng-data \
+  && apt-get update && apt-get install -y \
     python3.10 \
     python3.10-venv \
     espeak-ng \

@remsky
Copy link
Owner

remsky commented Feb 8, 2025

Feel free to submit a PR, but otherwise thanks! Will take a look later tonight. I see I did partially miss the symlink to handle all cases which could have been part of the cause.

@shinishiho
Copy link

I'm having this issue running with uv on macOS as well

@dong4j
Copy link

dong4j commented Feb 8, 2025

@shinishiho I encountered the error while running on M2, but @TheMrCodes method is also applicable to macOS. First, execute mkdir -p /usr/share/espeak-ng-data.

@thomas-hensel
Copy link

On Mac M3 via OrbStack - I started with the docker cmd ...
and got the error
Error processing file '/home/runner/work/espeakng-loader/espeakng-loader/espeak-ng/_dynamic/share/espeak-ng-data/phontab': No such file or directory.

I created in OrbStack Files section
/home/runner/work/espeakng-loader/espeakng-loader/espeak-ng/_dynamic
set permissions world readable
started a shell and soft linked /usr/share into /home/runner/work/espeakng-loader/espeakng-loader/espeak-ng/_dynamic

This has worked for me for short texts <200 characters

Longer texts bring: Error generating speech: The object is in an invalid state.

@remsky
Copy link
Owner

remsky commented Feb 8, 2025

Taking a look, it looks like the issue isn't consistent between systems, a conflict with the upstream espeak-loader and the system version I install. Digging into to find a solution across all builds

@remsky
Copy link
Owner

remsky commented Feb 9, 2025

hexgrad/misaki@000dd1e

In progress on the fix, think it's related to this commit from a few days ago.

@markldn
Copy link

markldn commented Feb 9, 2025

This fixed it for me

mkdir -p /home/runner/work/espeakng-loader/espeakng-loader/espeak-ng/_dynamic/share/

ln -s /app/.venv/lib/python3.10/site-packages/espeakng_loader/espeak-ng-data /home/runner/work/espeakng-loader/espeakng-loader/espeak-ng/_dynamic/share/espeak-ng-data

@remsky
Copy link
Owner

remsky commented Feb 10, 2025

https://github.com/remsky/Kokoro-FastAPI/releases/tag/v0.2.1

Should be implemented here, as far as I was able to test on a few machines. Let me know if the issues persists

@remsky remsky closed this as completed Feb 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

8 participants