This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.
"下面让我们来系统地学习语音方面的知识,看看怎样使用 **PaddleSpeech** 实现基本的语音功能,以及怎样结合光学字符识别(Optical Character Recognition,OCR)、自然语言处理(Natural Language Processing,NLP)等技术“听”书、让名人开口说话。"
"在第二次工业革命之前,语音的合成主要以机械式的音素合成为主。1779年,德裔丹麦科学家 Christian Gottlieb Kratzenstein 建造了人类的声道模型,使其可以产生五个长元音。1791年, Wolfgang von Kempelen 添加了唇和舌的模型,使其能够发出辅音和元音。贝尔实验室于20世纪30年代发明了声码器(Vocoder),将语音自动分解为音调和共振,此项技术由 Homer Dudley 改进为键盘式合成器并于 1939年纽约世界博览会展出。\n",
"\n",
"第一台基于计算机的语音合成系统起源于20世纪50年代。1961年,IBM 的 John Larry Kelly,以及 Louis Gerstman 使用 IBM 704 计算机合成语音,成为贝尔实验室最著名的成就之一。1975年,第一代语音合成系统之一 —— MUSA(MUltichannel Speaking Automation)问世,其由一个独立的硬件和配套的软件组成。1978年发行的第二个版本也可以进行无伴奏演唱。90 年代的主流是采用 MIT 和贝尔实验室的系统,并结合自然语言处理模型。\n",
"\u001b[K |████████████████████████████████| 1.2 MB 468 kB/s eta 0:00:01\n",
"\u001b[?25hRequirement already satisfied: kaldiio in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (2.17.2)\n",
"Requirement already satisfied: nltk in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (3.6.2)\n",
"Requirement already satisfied: sox in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (1.4.1)\n",
"Requirement already satisfied: pypinyin in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (0.42.0)\n",
"Requirement already satisfied: praatio~=4.1 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (4.4.0)\n",
"Requirement already satisfied: librosa in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (0.8.1)\n",
"Requirement already satisfied: paddlespeech-ctcdecoders in /home/yuantian01/yt_py37_develop/lib/python3.7/site-packages (from paddlespeech) (0.0.2a0)\n",
"Requirement already satisfied: yacs in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (0.1.8)\n",
"Requirement already satisfied: python-dateutil in /usr/local/lib/python3.7/site-packages (from paddlespeech) (2.8.1)\n",
"Requirement already satisfied: visualdl in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (2.2.0)\n",
"Requirement already satisfied: loguru in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (0.5.3)\n",
"Requirement already satisfied: resampy==0.2.2 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (0.2.2)\n",
"Requirement already satisfied: timer in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (0.2.2)\n",
"Requirement already satisfied: sacrebleu in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (2.0.0)\n",
"Requirement already satisfied: matplotlib in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (3.1.0)\n",
"Requirement already satisfied: soundfile~=0.10 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (0.10.3.post1)\n",
"Requirement already satisfied: soxbindings in /home/yuantian01/.local/lib/python3.7/site-packages (from paddlespeech) (1.2.3)\n",
"Requirement already satisfied: pyworld in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (0.2.12)\n",
"Requirement already satisfied: nara-wpe in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (0.0.7)\n",
"Requirement already satisfied: typeguard in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (2.12.1)\n",
"Requirement already satisfied: inflect in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (5.3.0)\n",
"Requirement already satisfied: g2p-en in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from paddlespeech) (2.1.0)\n",
"Requirement already satisfied: six>=1.3 in /usr/local/lib/python3.7/site-packages (from resampy==0.2.2->paddlespeech) (1.15.0)\n",
"Requirement already satisfied: numpy>=1.10 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from resampy==0.2.2->paddlespeech) (1.19.4)\n",
"Requirement already satisfied: numba>=0.32 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from resampy==0.2.2->paddlespeech) (0.53.1)\n",
"Requirement already satisfied: llvmlite<0.37,>=0.36.0rc1 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from numba>=0.32->resampy==0.2.2->paddlespeech) (0.36.0)\n",
"Requirement already satisfied: setuptools in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from numba>=0.32->resampy==0.2.2->paddlespeech) (57.4.0)\n",
"Requirement already satisfied: cffi>=1.0 in /usr/local/lib/python3.7/site-packages (from soundfile~=0.10->paddlespeech) (1.14.3)\n",
"Requirement already satisfied: pycparser in /usr/local/lib/python3.7/site-packages (from cffi>=1.0->soundfile~=0.10->paddlespeech) (2.20)\n",
"Requirement already satisfied: distance>=0.1.3 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from g2p-en->paddlespeech) (0.1.3)\n",
"Requirement already satisfied: joblib in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from nltk->paddlespeech) (1.0.1)\n",
"Requirement already satisfied: regex in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from nltk->paddlespeech) (2021.8.28)\n",
"Requirement already satisfied: click in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from nltk->paddlespeech) (8.0.1)\n",
"Requirement already satisfied: importlib-metadata in /usr/local/lib/python3.7/site-packages (from click->nltk->paddlespeech) (2.0.0)\n",
"Requirement already satisfied: cached-property in /usr/local/lib/python3.7/site-packages (from h5py->paddlespeech) (1.5.2)\n",
"Requirement already satisfied: zipp>=0.5 in /usr/local/lib/python3.7/site-packages (from importlib-metadata->click->nltk->paddlespeech) (3.4.0)\n"
]
},
{
"name": "stdout",
"output_type": "stream",
"text": [
"Requirement already satisfied: audioread>=2.0.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from librosa->paddlespeech) (2.1.9)\n",
"Requirement already satisfied: scikit-learn!=0.19.0,>=0.14.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from librosa->paddlespeech) (0.24.2)\n",
"Requirement already satisfied: decorator>=3.0.0 in /usr/local/lib/python3.7/site-packages (from librosa->paddlespeech) (4.4.2)\n",
"Requirement already satisfied: pooch>=1.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from librosa->paddlespeech) (1.5.1)\n",
"Requirement already satisfied: packaging>=20.0 in /usr/local/lib/python3.7/site-packages (from librosa->paddlespeech) (20.4)\n",
"Requirement already satisfied: pyparsing>=2.0.2 in /usr/local/lib/python3.7/site-packages (from packaging>=20.0->librosa->paddlespeech) (2.4.7)\n",
"Requirement already satisfied: requests in /usr/local/lib/python3.7/site-packages (from pooch>=1.0->librosa->paddlespeech) (2.25.0)\n",
"Requirement already satisfied: appdirs in /usr/local/lib/python3.7/site-packages (from pooch>=1.0->librosa->paddlespeech) (1.4.4)\n",
"Requirement already satisfied: threadpoolctl>=2.0.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from scikit-learn!=0.19.0,>=0.14.0->librosa->paddlespeech) (2.2.0)\n",
"Requirement already satisfied: cycler>=0.10 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from matplotlib->paddlespeech) (0.10.0)\n",
"Requirement already satisfied: kiwisolver>=1.0.1 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from matplotlib->paddlespeech) (1.3.2)\n",
"Requirement already satisfied: bottleneck in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from nara-wpe->paddlespeech) (1.2.1)\n",
"Requirement already satisfied: mock in /home/yuantian01/yt_py37_develop/lib/python3.7/site-packages (from paddlespeech-feat->paddlespeech) (4.0.3)\n",
"Requirement already satisfied: pytz>=2017.2 in /usr/local/lib/python3.7/site-packages (from pandas->paddlespeech) (2020.4)\n",
"Requirement already satisfied: cython>=0.24.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from pyworld->paddlespeech) (0.29.24)\n",
"Requirement already satisfied: certifi>=2017.4.17 in /usr/local/lib/python3.7/site-packages (from requests->pooch>=1.0->librosa->paddlespeech) (2020.11.8)\n",
"Requirement already satisfied: idna<3,>=2.5 in /usr/local/lib/python3.7/site-packages (from requests->pooch>=1.0->librosa->paddlespeech) (2.10)\n",
"Requirement already satisfied: chardet<4,>=3.0.2 in /usr/local/lib/python3.7/site-packages (from requests->pooch>=1.0->librosa->paddlespeech) (3.0.4)\n",
"Requirement already satisfied: urllib3<1.27,>=1.21.1 in /usr/local/lib/python3.7/site-packages (from requests->pooch>=1.0->librosa->paddlespeech) (1.26.2)\n",
"Requirement already satisfied: portalocker in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from sacrebleu->paddlespeech) (2.3.2)\n",
"Requirement already satisfied: colorama in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from sacrebleu->paddlespeech) (0.4.4)\n",
"Requirement already satisfied: tabulate>=0.8.9 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from sacrebleu->paddlespeech) (0.8.9)\n",
"Requirement already satisfied: protobuf>=3.11.0 in /usr/local/lib/python3.7/site-packages (from visualdl->paddlespeech) (3.13.0)\n",
"Requirement already satisfied: bce-python-sdk in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from visualdl->paddlespeech) (0.8.62)\n",
"Requirement already satisfied: flask>=1.1.1 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from visualdl->paddlespeech) (2.0.1)\n",
"Requirement already satisfied: Flask-Babel>=1.0.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from visualdl->paddlespeech) (2.0.0)\n",
"Requirement already satisfied: pre-commit in /usr/local/lib/python3.7/site-packages (from visualdl->paddlespeech) (1.10.4)\n",
"Requirement already satisfied: shellcheck-py in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from visualdl->paddlespeech) (0.7.2.1)\n",
"Requirement already satisfied: flake8>=3.7.9 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from visualdl->paddlespeech) (3.9.2)\n",
"Requirement already satisfied: Pillow>=7.0.0 in /home/yuantian01/yt_py37_develop/lib/python3.7/site-packages (from visualdl->paddlespeech) (8.4.0)\n",
"Requirement already satisfied: pyflakes<2.4.0,>=2.3.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from flake8>=3.7.9->visualdl->paddlespeech) (2.3.1)\n",
"Requirement already satisfied: pycodestyle<2.8.0,>=2.7.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from flake8>=3.7.9->visualdl->paddlespeech) (2.7.0)\n",
"Requirement already satisfied: mccabe<0.7.0,>=0.6.0 in /usr/local/lib/python3.7/site-packages (from flake8>=3.7.9->visualdl->paddlespeech) (0.6.1)\n",
"Requirement already satisfied: itsdangerous>=2.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from flask>=1.1.1->visualdl->paddlespeech) (2.0.1)\n",
"Requirement already satisfied: Jinja2>=3.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from flask>=1.1.1->visualdl->paddlespeech) (3.0.1)\n",
"Requirement already satisfied: Werkzeug>=2.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from flask>=1.1.1->visualdl->paddlespeech) (2.0.1)\n",
"Requirement already satisfied: Babel>=2.3 in /usr/local/lib/python3.7/site-packages (from Flask-Babel>=1.0.0->visualdl->paddlespeech) (2.9.0)\n",
"Requirement already satisfied: MarkupSafe>=2.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from Jinja2>=3.0->flask>=1.1.1->visualdl->paddlespeech) (2.0.1)\n",
"Requirement already satisfied: future>=0.6.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from bce-python-sdk->visualdl->paddlespeech) (0.18.2)\n",
"Requirement already satisfied: pycryptodome>=3.8.0 in /home/yuantian01/yt_py37/lib/python3.7/site-packages (from bce-python-sdk->visualdl->paddlespeech) (3.10.1)\n",
"Requirement already satisfied: nodeenv>=0.11.1 in /usr/local/lib/python3.7/site-packages (from pre-commit->visualdl->paddlespeech) (1.5.0)\n",
"Requirement already satisfied: identify>=1.0.0 in /usr/local/lib/python3.7/site-packages (from pre-commit->visualdl->paddlespeech) (1.5.9)\n",
"Requirement already satisfied: aspy.yaml in /usr/local/lib/python3.7/site-packages (from pre-commit->visualdl->paddlespeech) (1.3.0)\n",
"Requirement already satisfied: cfgv>=1.0.0 in /usr/local/lib/python3.7/site-packages (from pre-commit->visualdl->paddlespeech) (3.2.0)\n",
"Requirement already satisfied: toml in /usr/local/lib/python3.7/site-packages (from pre-commit->visualdl->paddlespeech) (0.10.2)\n",
"Requirement already satisfied: pyyaml in /usr/local/lib/python3.7/site-packages (from pre-commit->visualdl->paddlespeech) (5.3.1)\n",
"Requirement already satisfied: virtualenv in /usr/local/lib/python3.7/site-packages (from pre-commit->visualdl->paddlespeech) (20.1.0)\n",
"Requirement already satisfied: filelock<4,>=3.0.0 in /usr/local/lib/python3.7/site-packages (from virtualenv->pre-commit->visualdl->paddlespeech) (3.0.12)\n",
"Requirement already satisfied: distlib<1,>=0.3.1 in /usr/local/lib/python3.7/site-packages (from virtualenv->pre-commit->visualdl->paddlespeech) (0.3.1)\n",
"\u001b[33mWARNING: Ignoring invalid distribution -addlepaddle-gpu (/home/yuantian01/yt_py37/lib/python3.7/site-packages)\u001b[0m\n",
"Installing collected packages: sentencepiece\n",
" Attempting uninstall: sentencepiece\n",
"\u001b[33m WARNING: Ignoring invalid distribution -addlepaddle-gpu (/home/yuantian01/yt_py37/lib/python3.7/site-packages)\u001b[0m\n",
" Found existing installation: sentencepiece 0.1.86\n",
" Not uninstalling sentencepiece at /home/yuantian01/yt_py37/lib/python3.7/site-packages, outside environment /home/yuantian01/yt_py37_develop\n",
" Can't uninstall 'sentencepiece'. No files were found to uninstall.\n",
"\u001b[31mERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.\n",
"espnet 0.10.0 requires sentencepiece<0.1.90,>=0.1.82, but you have sentencepiece 0.1.96 which is incompatible.\u001b[0m\n",
"Successfully installed sentencepiece-0.1.96\n",
"\u001b[33mWARNING: Ignoring invalid distribution -addlepaddle-gpu (/home/yuantian01/yt_py37/lib/python3.7/site-packages)\u001b[0m\n",
"\u001b[33mWARNING: Ignoring invalid distribution -addlepaddle-gpu (/home/yuantian01/yt_py37/lib/python3.7/site-packages)\u001b[0m\n",
"\u001b[33mWARNING: Ignoring invalid distribution -addlepaddle-gpu (/home/yuantian01/yt_py37/lib/python3.7/site-packages)\u001b[0m\n",
"\u001b[33mWARNING: You are using pip version 21.1.3; however, version 21.3.1 is available.\n",
"You should consider upgrading via the '/home/yuantian01/yt_py37_develop/bin/python -m pip install --upgrade pip' command.\u001b[0m\n"
"/home/yuantian01/yt_py37/lib/python3.7/site-packages/paddle/framework/io.py:415: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated, and in 3.8 it will stop working\n",
" if isinstance(obj, collections.Iterable) and not isinstance(obj, (\n"
]
},
{
"name": "stdout",
"output_type": "stream",
"text": [
"FastSpeech2 done!\n"
]
}
],
"source": [
"with open(phones_dict, \"r\") as f:\n",
" phn_id = [line.strip().split() for line in f.readlines()]\n",
"/home/yuantian01/yt_py37/lib/python3.7/site-packages/paddle/fluid/dygraph/math_op_patch.py:253: UserWarning: The dtype of left and right variables are not the same, left dtype is paddle.int64, but right dtype is paddle.int32, the right dtype will convert to paddle.int64\n",
"Mel GAN |adversial loss <br> Multi-resolution STFT loss | adversial loss|\n",
"Multi-Band Mel GAN | adversial loss <br> full band Multi-resolution STFT loss <br> sub band Multi-resolution STFT loss |Multi-Scale Discriminator|\n",
"HiFi GAN |adversial loss <br> Feature Matching <br> Mel-Spectrogram Loss | Multi-Scale Discriminator <br> Multi-Period Discriminator| \n"