Spaces:
Running
Error
main.py:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("translation", model="issai/tilmash")
C:\Users\User\Desktop\Kokoro TTS>huggingface-cli login
_| _| _| _| _|_|_| _|_|_| _|_|_| _| _| _|_|_| _|_|_|_| _|_| _|_|_| _|_|_|_|
_| _| _| _| _| _| _| _|_| _| _| _| _| _| _| _|
_|_|_|_| _| _| _| _|_| _| _|_| _| _| _| _| _| _|_| _|_|_| _|_|_|_| _| _|_|_|
_| _| _| _| _| _| _| _| _| _| _|_| _| _| _| _| _| _| _|
_| _| _|_| _|_|_| _|_|_| _|_|_| _| _| _|_|_| _| _| _| _|_|_| _|_|_|_|
A token is already saved on your machine. Run `huggingface-cli whoami` to get more information or `huggingface-cli logout` if you want to log out.
Setting a new token will erase the existing one.
To log in, `huggingface_hub` requires a token generated from https://huggingface.co./settings/tokens .
Token can be pasted using 'Right-Click'.
Enter your token (input will not be visible):
Add token as git credential? (Y/n) y
Token is valid (permission: fineGrained).
The token for_kaz_llm
has been saved to C:\Users\User.cache\huggingface\stored_tokens
Your token has been saved in your configured git credential helpers (manager).
Your token has been saved to C:\Users\User.cache\huggingface\token
Login successful.
The current active token is: for_kaz_llm
C:\Users\User\Desktop\Kokoro TTS>py main.py
Traceback (most recent call last):
File "C:\Users\User\AppData\Local\Programs\Python\Python311\Lib\site-packages\transformers\utils\import_utils.py", line 1793, in get_module
return importlib.import_module("." + module_name, self.name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\User\AppData\Local\Programs\Python\Python311\Lib\importlib_init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "", line 1204, in _gcd_import
File "", line 1176, in _find_and_load
File "", line 1147, in _find_and_load_unlocked
File "", line 690, in load_unlocked
File "", line 940, in exec_module
File "", line 241, in call_with_frames_removed
File "C:\Users\User\AppData\Local\Programs\Python\Python311\Lib\site-packages\transformers\pipelines_init.py", line 26, in
from ..image_processing_utils import BaseImageProcessor
File "C:\Users\User\AppData\Local\Programs\Python\Python311\Lib\site-packages\transformers\image_processing_utils.py", line 21, in
from .image_transforms import center_crop, normalize, rescale
File "C:\Users\User\AppData\Local\Programs\Python\Python311\Lib\site-packages\transformers\image_transforms.py", line 22, in
from .image_utils import (
File "C:\Users\User\AppData\Local\Programs\Python\Python311\Lib\site-packages\transformers\image_utils.py", line 59, in
from torchvision.transforms import InterpolationMode
File "C:\Users\User\AppData\Local\Programs\Python\Python311\Lib\site-packages\torchvision_init.py", line 10, in
from torchvision import _meta_registrations, datasets, io, models, ops, transforms, utils # usort:skip
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\User\AppData\Local\Programs\Python\Python311\Lib\site-packages\torchvision_meta_registrations.py", line 163, in
@torch
.library.register_fake("torchvision::nms")
^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: module 'torch.library' has no attribute 'register_fake'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "C:\Users\User\Desktop\Kokoro TTS\main.py", line 2, in
from transformers import pipeline
File "", line 1229, in _handle_fromlist
File "C:\Users\User\AppData\Local\Programs\Python\Python311\Lib\site-packages\transformers\utils\import_utils.py", line 1781, in getattr
module = self._get_module(self._class_to_module[name])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\User\AppData\Local\Programs\Python\Python311\Lib\site-packages\transformers\utils\import_utils.py", line 1795, in _get_module
raise RuntimeError(
RuntimeError: Failed to import transformers.pipelines because of the following error (look up to see its traceback):
module 'torch.library' has no attribute 'register_fake'
C:\Users\User\Desktop\Kokoro TTS>
How to run it? Even Jan.ai couldn't run it!