PaddlePaddle / PaddleSpeech

Easy-to-use Speech Toolkit including Self-Supervised Learning model, SOTA/Streaming ASR with punctuation, Streaming TTS with text frontend, Speaker Verification System, End-to-End Speech Translation and Keyword Spotting. Won NAACL2022 Best Demo Award.
https://paddlespeech.readthedocs.io
Apache License 2.0
11.16k stars 1.85k forks source link

[TTS] cannot import name 'timer' from 'timer' #3249

Closed guigenyi closed 1 year ago

guigenyi commented 1 year ago

paddlespeech tts --input "你好,欢迎使用百度飞桨深度学习框架!" --output output.wav

C:\ProgramData\anaconda3\envs\ps_env\lib\site-packages\pkg_resources__init.py:121: DeprecationWarning: pkg_resources is deprecated as an API warnings.warn("pkg_resources is deprecated as an API", DeprecationWarning) C:\ProgramData\anaconda3\envs\ps_env\lib\site-packages\pkg_resources__init.py:2870: DeprecationWarning: Deprecated call to pkg_resources.declare_namespace('mpl_toolkits'). Implementing implicit namespace packages (as specified in PEP 420) is preferred to pkg_resources.declare_namespace. See https://setuptools.pypa.io/en/latest/references/keywords.html#keyword-namespace-packages declare_namespace(pkg) C:\ProgramData\anaconda3\envs\ps_env\lib\site-packages\pkg_resources__init.py:2870: DeprecationWarning: Deprecated call to pkg_resources.declare_namespace('google'). Implementing implicit namespace packages (as specified in PEP 420) is preferred to pkg_resources.declare_namespace. See https://setuptools.pypa.io/en/latest/references/keywords.html#keyword-namespace-packages declare_namespace(pkg) [nltk_data] Downloading package averaged_perceptron_tagger to [nltk_data] C:\Users\Administrator\AppData\Roaming\nltk_data... [nltk_data] Unzipping taggers\averaged_perceptron_tagger.zip. [nltk_data] Downloading package cmudict to [nltk_data] C:\Users\Administrator\AppData\Roaming\nltk_data... [nltk_data] Unzipping corpora\cmudict.zip. C:\ProgramData\anaconda3\envs\ps_env\lib\site-packages\librosa\core\constantq.py:1059: DeprecationWarning: np.complex is a deprecated alias for the builtin complex. To silence this warning, use complex by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use np.complex128 here. Deprecated in NumPy 1.20; for more details and guidance: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations dtype=np.complex, Traceback (most recent call last): File "C:\ProgramData\anaconda3\envs\ps_env\lib\runpy.py", line 197, in _run_module_as_main return _run_code(code, main_globals, None, File "C:\ProgramData\anaconda3\envs\ps_env\lib\runpy.py", line 87, in _run_code exec(code, run_globals) File "C:\ProgramData\anaconda3\envs\ps_env\Scripts\paddlespeech.exe__main__.py", line 7, in File "C:\ProgramData\anaconda3\envs\ps_env\lib\site-packages\paddlespeech\cli\entry.py", line 40, in _execute exec("from {} import {}".format(module, cls)) File "", line 1, in File "C:\ProgramData\anaconda3\envs\ps_env\lib\site-packages\paddlespeech\cli\tts__init__.py", line 14, in from .infer import TTSExecutor File "C:\ProgramData\anaconda3\envs\ps_env\lib\site-packages\paddlespeech\cli\tts\infer.py", line 33, in from paddlespeech.t2s.exps.syn_utils import get_am_inference File "C:\ProgramData\anaconda3\envs\ps_env\lib\site-packages\paddlespeech\t2s\init__.py", line 19, in from . import models File "C:\ProgramData\anaconda3\envs\ps_env\lib\site-packages\paddlespeech\t2s\models\init__.py", line 14, in from .ernie_sat import * File "C:\ProgramData\anaconda3\envs\ps_env\lib\site-packages\paddlespeech\t2s\models\ernie_sat\init__.py", line 15, in from .ernie_sat_updater import * File "C:\ProgramData\anaconda3\envs\ps_env\lib\site-packages\paddlespeech\t2s\models\ernie_sat\ernie_sat_updater.py", line 26, in from paddlespeech.t2s.training.updaters.standard_updater import StandardUpdater File "C:\ProgramData\anaconda3\envs\ps_env\lib\site-packages\paddlespeech\t2s\training\updaters\standard_updater.py", line 25, in from timer import timer ImportError: cannot import name 'timer' from 'timer' (C:\Users\Administrator\AppData\Roaming\Python\Python39\site-packages\win32\timer.pyd) (ps_env) PS C:\Users\Administrator\Documents\ftp\qianyuhui\src\PaddleSpeech\PaddleSpeech>

guigenyi commented 1 year ago

This is a problem with the Timer library. I solved it myself.

Myhjworld commented 2 months ago

how did you resolve it?i get the same wrong.