oobabooga / text-generation-webui

A Gradio web UI for Large Language Models.
GNU Affero General Public License v3.0
40.83k stars 5.34k forks source link

Official linked XTTS_v2 google colab throws tokenizers version error #6100

Open flocked opened 5 months ago

flocked commented 5 months ago

Describe the bug

When using the google colab for XTTS_v2 that is linked in the official tutorial it throws an error in the second step: ImportError: tokenizers>=0.19,<0.20 is required for a normal functioning of this module, but found tokenizers==0.14.1.

Is there an existing issue for this?

Reproduction

Run the 1. step of the Google colab and then the 2. This throws the linked error.

Screenshot

No response

Logs

Traceback (most recent call last):
  File "/content/TTS/TTS/demos/xtts_ft_demo/xtts_demo.py", line 15, in <module>
    from TTS.demos.xtts_ft_demo.utils.gpt_train import train_gpt
  File "/content/TTS/TTS/demos/xtts_ft_demo/utils/gpt_train.py", line 8, in <module>
    from TTS.tts.layers.xtts.trainer.gpt_trainer import GPTArgs, GPTTrainer, GPTTrainerConfig, XttsAudioConfig
  File "/content/TTS/TTS/tts/layers/xtts/trainer/gpt_trainer.py", line 13, in <module>
    from TTS.tts.configs.xtts_config import XttsConfig
  File "/content/TTS/TTS/tts/configs/xtts_config.py", line 5, in <module>
    from TTS.tts.models.xtts import XttsArgs, XttsAudioConfig
  File "/content/TTS/TTS/tts/models/xtts.py", line 10, in <module>
    from TTS.tts.layers.xtts.gpt import GPT
  File "/content/TTS/TTS/tts/layers/xtts/gpt.py", line 10, in <module>
    from transformers import GPT2Config
  File "/usr/local/lib/python3.10/dist-packages/transformers/__init__.py", line 26, in <module>
    from . import dependency_versions_check
  File "/usr/local/lib/python3.10/dist-packages/transformers/dependency_versions_check.py", line 57, in <module>
    require_version_core(deps[pkg])
  File "/usr/local/lib/python3.10/dist-packages/transformers/utils/versions.py", line 117, in require_version_core
    return require_version(requirement, hint)
  File "/usr/local/lib/python3.10/dist-packages/transformers/utils/versions.py", line 111, in require_version
    _compare_versions(op, got_ver, want_ver, requirement, pkg, hint)
  File "/usr/local/lib/python3.10/dist-packages/transformers/utils/versions.py", line 44, in _compare_versions
    raise ImportError(
ImportError: tokenizers>=0.19,<0.20 is required for a normal functioning of this module, but found tokenizers==0.14.1.
Try: `pip install transformers -U` or `pip install -e '.[dev]'` if you're working with git main

System Info

Google colab
flocked commented 5 months ago

Adding pip install transformers -U solves this problem.