-
-
Notifications
You must be signed in to change notification settings - Fork 77
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
Failed building wheel for thinc #25
Comments
If I try "pip install kokoro --pre" I get a similar error except instead of thinc the error is for blis instead. |
I had the same issue with Python 3.13. If you're using conda, use this
|
Thank you that worked. Like I said I'm not a programmer so can you explain to me once I conda activate the env how do I use kokoro. What I mean is with other conda env I have I get a local host address that I can use the app at. So I guess what Im asking is what steps do I take after I activate the conda env in order to use kokoro? Thanks again for helping get this far |
Create a conda env with the above config: Here's the example I use to generate a sample of all american voices: from kokoro import KPipeline
import soundfile as sf
from pathlib import Path
import torch
def generate_voice_swatches():
voices = """
af_heart
af_alloy
af_aoede
af_bella
af_jessica
af_kore
af_nicole
af_nova
af_river
af_sarah
af_sky
am_adam
am_echo
am_eric
am_fenrir
am_liam
am_michael
am_onyx
am_puck
am_santa
"""
voices = voices.split()
text = "Weakness on short utterances, especially less than 10-20 tokens. Root cause could be lack of short-utterance training data and/or model architecture. One possible inference mitigation is to bundle shorter utterances together."
for voice in voices:
generate(text, voice, f"{voice}.wav")
# Generate the audio for `text` using `voice` and save it to `outfile` as WAV
def generate(text, voice, outfile):
generator = pipeline(
text,
voice=voice,
speed=1, # type: ignore (https://github.com/python/mypy/issues/3186)
split_pattern=r"\n+",
)
data = []
for gs, ps, audio in generator:
data.append(audio)
# concatenate each "chunk" of audio samples
concated = torch.concatenate(data)
sf.write(outfile, concated, 24000)
generate_voice_swatches() |
Above comments might have solutions. As for potential root cause, I suspect it might be a |
@hexgrad, those questions seem to be too old (2018ish). @SBGxJAMES could you confirm if you're on a rolling release distro like Arch or Fedora? Here's the PR that adds Python 3.13 supported to thincc. It's not merged yet. I think the version constraint in my conda env file was too aggressive. If anyone have the time to test it with Python 3.12 and confirm, we can relax the constraint in the env file added in the README. This sort of things happen a lot, so I always try to test it with the current python version minus 1 and the python version that ships with debian. |
Hey guys, sorry I've been out of town all weekend and thank you to everyone helping me. @itsfarseen I'm on windows 11 not linux. I did succesfully install using the yml env you provided but like I said I'm not a programmer so I tend to get lost in the weeds when I try to do a lot of this stuff. please bare with me lol. I really do appreciate all the help. After I execute the conda activate kokoro command in my cmd prompt. Im not sure what to do next. Is there a ui or do I need to work from an ide? I understand enough about code to work from an ide but just barely lol. What I mean is with other AI that I have been learning recently there is a local host with a ui like open-webui for LLMs or ComfyUI for diffusion models. So if there isnt a ui I see you said copy your example into run.py and run it. I follow you sort of except I'm not sure where the run.py file is located nor do I know what you mean by copy it into the run.py file. I realize I dont know what I'm talking about and it may be tiresome trying to hold my hand so no hard feelings if I'm asking for too much guidance but I do appreciate the help. IF that example generates a sample of all american voices, do I then just limit the list to the voice I want and replace the example text with the text I wish to generate in order to generate my desired tts file? Also If I'm asking too much for an issue post the mod can move this to discussion if you guys are willing to hold my hand while I learn thats cool too. Again thanks for everyones help. |
@SBGxJAMES, since this is no longer about the original issue (failed to build thinc), let's move this discussion elsewhere. I can't find a "discussion" tab for this repo, so we can discuss this over email. If the above conda snippet solves the original issue for you, please close this issue. |
The above conda snippet does solve the issue thanks. |
Hey guys, I tried pip installing Kokoro. Everything seems to start off going well then towards the end of the install I get the error
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for thinc
Failed to build thinc
ERROR: Failed to build installable wheels for some pyproject.toml based projects (thinc)
[end of output]
I'll be honest, I'm not a programmer and I dont know what this means or how to fix it so I'm reaching out to see if anyone can guide me on a solution. Thank you in advance for anyone willing to help. please keep in mind I'm not a programmer so if you are willing to help if you could explain it to me like I'm a toddler that would help lol.
The text was updated successfully, but these errors were encountered: