tortoise-tts
tortoise-tts copied to clipboard
ImportError: cannot import name 'Annotated' from 'pydantic.typing'
Everytime I try to generate a TTS, I get this error:
`(base) C:\Users\austi\tortoise-tts>python tortoise/do_tts.py --text "I'm going to speak this" --voice random --preset fastconda install mkl mkl-include
Traceback (most recent call last):
File "C:\Users\austi\tortoise-tts\tortoise\do_tts.py", line 7, in
Install seems broken right now I've followed the install to a T and still getting multiple errors, Been trying to make this work for over a week now.. I'm using Anaconda as well..
conda create --name tortoise python=3.9 numba inflect
conda activate tortoise
conda install pytorch torchvision torchaudio pytorch-cuda=11.7 -c pytorch -c nvidia
git clone https://github.com/neonbjb/tortoise-tts.git
cd tortoise-tts
python setup.py install
See my conda installation instructions here. Start fresh — reset your base conda environment if needed with:
conda install --rev 1
Also a pull request I made to adjust the current README.md.
conda create --name tortoise python=3.9 numba inflect conda activate tortoise conda install pytorch torchvision torchaudio pytorch-cuda=11.7 -c pytorch -c nvidia git clone https://github.com/neonbjb/tortoise-tts.git cd tortoise-tts python setup.py install
See my conda installation instructions here. Start fresh — reset your base conda environment if needed with:
conda install --rev 1
Also a pull request I made to adjust the current README.md.
You're a genius. thank you so much for the help.
Now my issue is Generating autoregressive samples.. 0%| | 0/32 [00:00<?, ?it/s]
Any ideas on why it isn't progressing? Thanks so much!
The first iteration shows like that. Sometimes the iterations can be up to a minute long or more if you had a long prompt, and if you are using the gpu for other things.
Try the ultra_fast preset, close all other apps, and use a short prompt for a test.
The first iteration shows like that. Sometimes the iterations can be up to a minute long or more if you had a long prompt, and if you are using the gpu for other things.
Try the ultra_fast preset, close all other apps, and use a short prompt for a test.
Right as you commented it started moving! Appreciate your help :)
I was going through the same issue with a different repo and this solved it for me:
In the inflect init.py, for your case this path: C:\Users\austi\anaconda3\lib\site-packages\inflect-6.0.4-py3.10.egg\inflect_init.py__,
Replace the pydantic.typing import with the typing_extensions import like this:
# from pydantic.typing import Annotated from typing_extensions import Annotated
I got this from the pydantic site itself - https://docs.pydantic.dev/latest/usage/strict_mode/#strict-mode-with-annotated-strict. For full context, I'm using a python==3.8.0 miniconda env on Ubuntu 22.04
我正在用不同的 repo 遇到同样的问题,这为我解决了它:
在 inflect init.py 中,对于您的情况,此路径:C:\Users\austi\anaconda3\lib\site-packages\inflect-6.0.4-py3.10.egg\inflect_init.py__,
将 pydantic.typing import 替换为 typing_extensions 导入,如下所示:
# from pydantic.typing import Annotated from typing_extensions import Annotated
我从 pydantic 网站本身得到了这个 - https://docs.pydantic.dev/latest/usage/strict_mode/#strict-mode-with-annotated-strict。为了获得完整的上下文,我在 Ubuntu 22.04 上使用 python==3.8.0 miniconda env
thanks you . not you i con't fixed it.
我正在用不同的 repo 遇到同样的问题,这为我解决了它:
在 inflect init.py 中,对于您的情况,此路径:C:\Users\austi\anaconda3\lib\site-packages\inflect-6.0.4-py3.10.egg\inflect_init.py__,
将 pydantic.typing import 替换为 typing_extensions 导入,如下所示:
# from pydantic.typing import Annotated from typing_extensions import Annotated
我从 pydantic 网站本身得到了这个 - https://docs.pydantic.dev/latest/usage/strict_mode/#strict-mode-with-annotated-strict。为了获得完整的上下文,我在 Ubuntu 22.04 上使用 python==3.8.0 miniconda env
is good .you can to fix the primitive question ,you will help lots of people