{
  "nbformat": 4,
  "nbformat_minor": 0,
  "metadata": {
    "colab": {
      "name": "DDC-TTS_and_MultiBand-MelGAN_TFLite_Example.ipynb",
      "provenance": [],
      "collapsed_sections": [],
      "toc_visible": true
    },
    "kernelspec": {
      "name": "python3",
      "display_name": "Python 3"
    }
  },
  "cells": [
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "6LWsNd3_M3MP",
        "colab_type": "text"
      },
      "source": [
        "# Mozilla TTS on CPU Real-Time Speech Synthesis with TFLite"
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "FAqrSIWgLyP0",
        "colab_type": "text"
      },
      "source": [
        "**These models are converted from released [PyTorch models](https://colab.research.google.com/drive/1u_16ZzHjKYFn1HNVuA4Qf_i2MMFB9olY?usp=sharing) using our TF utilities provided in Mozilla TTS.**\n",
        "\n",
        "#### **Notebook Details**\n",
        "These TFLite models support TF 2.3rc0 and for different versions you might need to regenerate them. \n",
        "\n",
        "TFLite optimizations degrades the TTS model performance and we do not apply\n",
        "any optimization for the vocoder model due to the same reason. If you like to\n",
        "keep the quality, consider to regenerate TFLite model accordingly.\n",
        "\n",
        "Models optimized with TFLite can be slow on a regular CPU since it is optimized\n",
        "specifically for lower-end systems.\n",
        "\n",
        "---\n",
        "\n",
        "\n",
        "\n",
        "#### **Model Details** \n",
        "We use Tacotron2 and MultiBand-Melgan models and LJSpeech dataset.\n",
        "\n",
        "Tacotron2 is trained using [Double Decoder Consistency](https://erogol.com/solving-attention-problems-of-tts-models-with-double-decoder-consistency/) (DDC) only for 130K steps (3 days) with a single GPU.\n",
        "\n",
        "MultiBand-Melgan is trained  1.45M steps with real spectrograms.\n",
        "\n",
        "Note that both model performances can be improved with more training.\n"
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "Ku-dA4DKoeXk",
        "colab_type": "text"
      },
      "source": [
        "### Download TF Models and configs"
      ]
    },
    {
      "cell_type": "code",
      "metadata": {
        "id": "jGIgnWhGsxU1",
        "colab_type": "code",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 162
        },
        "outputId": "57af701e-77ec-400d-fee5-64aa7603d357"
      },
      "source": [
        "!gdown --id 17PYXCmTe0el_SLTwznrt3vOArNGMGo5v -O tts_model.tflite\n",
        "!gdown --id 18CQ6G6tBEOfvCHlPqP8EBI4xWbrr9dBc -O config.json"
      ],
      "execution_count": null,
      "outputs": [
        {
          "output_type": "stream",
          "text": [
            "Downloading...\n",
            "From: https://drive.google.com/uc?id=17PYXCmTe0el_SLTwznrt3vOArNGMGo5v\n",
            "To: /content/tts_model.tflite\n",
            "30.1MB [00:00, 36.8MB/s]\n",
            "Downloading...\n",
            "From: https://drive.google.com/uc?id=18CQ6G6tBEOfvCHlPqP8EBI4xWbrr9dBc\n",
            "To: /content/config.json\n",
            "100% 9.53k/9.53k [00:00<00:00, 7.38MB/s]\n"
          ],
          "name": "stdout"
        }
      ]
    },
    {
      "cell_type": "code",
      "metadata": {
        "id": "4dnpE0-kvTsu",
        "colab_type": "code",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 235
        },
        "outputId": "6aab0622-9add-4ee4-b9f8-177d6ddc0e86"
      },
      "source": [
        "!gdown --id 1aXveT-NjOM1mUr6tM4JfWjshq67GvVIO -O vocoder_model.tflite\n",
        "!gdown --id 1Rd0R_nRCrbjEdpOwq6XwZAktvugiBvmu -O config_vocoder.json\n",
        "!gdown --id 11oY3Tv0kQtxK_JPgxrfesa99maVXHNxU -O scale_stats.npy"
      ],
      "execution_count": null,
      "outputs": [
        {
          "output_type": "stream",
          "text": [
            "Downloading...\n",
            "From: https://drive.google.com/uc?id=1aXveT-NjOM1mUr6tM4JfWjshq67GvVIO\n",
            "To: /content/vocoder_model.tflite\n",
            "10.2MB [00:00, 16.5MB/s]\n",
            "Downloading...\n",
            "From: https://drive.google.com/uc?id=1Rd0R_nRCrbjEdpOwq6XwZAktvugiBvmu\n",
            "To: /content/config_vocoder.json\n",
            "100% 6.76k/6.76k [00:00<00:00, 11.4MB/s]\n",
            "Downloading...\n",
            "From: https://drive.google.com/uc?id=11oY3Tv0kQtxK_JPgxrfesa99maVXHNxU\n",
            "To: /content/scale_stats.npy\n",
            "100% 10.5k/10.5k [00:00<00:00, 16.6MB/s]\n"
          ],
          "name": "stdout"
        }
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "_ZuDrj_ioqHE",
        "colab_type": "text"
      },
      "source": [
        "### Setup Libraries"
      ]
    },
    {
      "cell_type": "code",
      "metadata": {
        "id": "X2axt5BYq7gv",
        "colab_type": "code",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 964
        },
        "outputId": "aa53986f-f218-4d17-8667-0d74bb90c927"
      },
      "source": [
        "# need it for char to phoneme conversion\n",
        "! sudo apt-get install espeak"
      ],
      "execution_count": null,
      "outputs": [
        {
          "output_type": "stream",
          "text": [
            "Reading package lists... Done\n",
            "Building dependency tree       \n",
            "Reading state information... Done\n",
            "The following package was automatically installed and is no longer required:\n",
            "  libnvidia-common-440\n",
            "Use 'sudo apt autoremove' to remove it.\n",
            "The following additional packages will be installed:\n",
            "  espeak-data libespeak1 libportaudio2 libsonic0\n",
            "The following NEW packages will be installed:\n",
            "  espeak espeak-data libespeak1 libportaudio2 libsonic0\n",
            "0 upgraded, 5 newly installed, 0 to remove and 35 not upgraded.\n",
            "Need to get 1,219 kB of archives.\n",
            "After this operation, 3,031 kB of additional disk space will be used.\n",
            "Get:1 http://archive.ubuntu.com/ubuntu bionic/universe amd64 libportaudio2 amd64 19.6.0-1 [64.6 kB]\n",
            "Get:2 http://archive.ubuntu.com/ubuntu bionic/main amd64 libsonic0 amd64 0.2.0-6 [13.4 kB]\n",
            "Get:3 http://archive.ubuntu.com/ubuntu bionic/universe amd64 espeak-data amd64 1.48.04+dfsg-5 [934 kB]\n",
            "Get:4 http://archive.ubuntu.com/ubuntu bionic/universe amd64 libespeak1 amd64 1.48.04+dfsg-5 [145 kB]\n",
            "Get:5 http://archive.ubuntu.com/ubuntu bionic/universe amd64 espeak amd64 1.48.04+dfsg-5 [61.6 kB]\n",
            "Fetched 1,219 kB in 2s (498 kB/s)\n",
            "debconf: unable to initialize frontend: Dialog\n",
            "debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76, <> line 5.)\n",
            "debconf: falling back to frontend: Readline\n",
            "debconf: unable to initialize frontend: Readline\n",
            "debconf: (This frontend requires a controlling tty.)\n",
            "debconf: falling back to frontend: Teletype\n",
            "dpkg-preconfigure: unable to re-open stdin: \n",
            "Selecting previously unselected package libportaudio2:amd64.\n",
            "(Reading database ... 144465 files and directories currently installed.)\n",
            "Preparing to unpack .../libportaudio2_19.6.0-1_amd64.deb ...\n",
            "Unpacking libportaudio2:amd64 (19.6.0-1) ...\n",
            "Selecting previously unselected package libsonic0:amd64.\n",
            "Preparing to unpack .../libsonic0_0.2.0-6_amd64.deb ...\n",
            "Unpacking libsonic0:amd64 (0.2.0-6) ...\n",
            "Selecting previously unselected package espeak-data:amd64.\n",
            "Preparing to unpack .../espeak-data_1.48.04+dfsg-5_amd64.deb ...\n",
            "Unpacking espeak-data:amd64 (1.48.04+dfsg-5) ...\n",
            "Selecting previously unselected package libespeak1:amd64.\n",
            "Preparing to unpack .../libespeak1_1.48.04+dfsg-5_amd64.deb ...\n",
            "Unpacking libespeak1:amd64 (1.48.04+dfsg-5) ...\n",
            "Selecting previously unselected package espeak.\n",
            "Preparing to unpack .../espeak_1.48.04+dfsg-5_amd64.deb ...\n",
            "Unpacking espeak (1.48.04+dfsg-5) ...\n",
            "Setting up libportaudio2:amd64 (19.6.0-1) ...\n",
            "Setting up espeak-data:amd64 (1.48.04+dfsg-5) ...\n",
            "Setting up libsonic0:amd64 (0.2.0-6) ...\n",
            "Setting up libespeak1:amd64 (1.48.04+dfsg-5) ...\n",
            "Setting up espeak (1.48.04+dfsg-5) ...\n",
            "Processing triggers for man-db (2.8.3-2ubuntu0.1) ...\n",
            "Processing triggers for libc-bin (2.27-3ubuntu1) ...\n",
            "/sbin/ldconfig.real: /usr/local/lib/python3.6/dist-packages/ideep4py/lib/libmkldnn.so.0 is not a symbolic link\n",
            "\n"
          ],
          "name": "stdout"
        }
      ]
    },
    {
      "cell_type": "code",
      "metadata": {
        "id": "ZduAf-qYYEIT",
        "colab_type": "code",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 144
        },
        "outputId": "c1fcac0d-b8f8-442c-d598-4f549c42b698"
      },
      "source": [
        "!git clone https://github.com/mozilla/TTS"
      ],
      "execution_count": null,
      "outputs": [
        {
          "output_type": "stream",
          "text": [
            "Cloning into 'TTS'...\n",
            "remote: Enumerating objects: 107, done.\u001b[K\n",
            "remote: Counting objects: 100% (107/107), done.\u001b[K\n",
            "remote: Compressing objects: 100% (79/79), done.\u001b[K\n",
            "remote: Total 7252 (delta 51), reused 68 (delta 28), pack-reused 7145\u001b[K\n",
            "Receiving objects: 100% (7252/7252), 115.36 MiB | 11.38 MiB/s, done.\n",
            "Resolving deltas: 100% (4892/4892), done.\n"
          ],
          "name": "stdout"
        }
      ]
    },
    {
      "cell_type": "code",
      "metadata": {
        "id": "ofPCvPyjZEcT",
        "colab_type": "code",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 1000
        },
        "outputId": "f3d3ea73-eae5-473c-db19-276bd0e721cc"
      },
      "source": [
        "%cd TTS\n",
        "!git checkout c7296b3\n",
        "!pip install -r requirements.txt\n",
        "!python setup.py install\n",
        "!pip install tensorflow==2.3.0rc0\n",
        "%cd .."
      ],
      "execution_count": null,
      "outputs": [
        {
          "output_type": "stream",
          "text": [
            "/content/TTS\n",
            "Note: checking out 'c7296b3'.\n",
            "\n",
            "You are in 'detached HEAD' state. You can look around, make experimental\n",
            "changes and commit them, and you can discard any commits you make in this\n",
            "state without impacting any branches by performing another checkout.\n",
            "\n",
            "If you want to create a new branch to retain commits you create, you may\n",
            "do so (now or later) by using -b with the checkout command again. Example:\n",
            "\n",
            "  git checkout -b <new-branch-name>\n",
            "\n",
            "HEAD is now at c7296b3 add module requirement\n",
            "Requirement already satisfied: numpy>=1.16.0 in /usr/local/lib/python3.6/dist-packages (from -r requirements.txt (line 1)) (1.18.5)\n",
            "Requirement already satisfied: torch>=1.5 in /usr/local/lib/python3.6/dist-packages (from -r requirements.txt (line 2)) (1.5.1+cu101)\n",
            "Requirement already satisfied: librosa>=0.5.1 in /usr/local/lib/python3.6/dist-packages (from -r requirements.txt (line 3)) (0.6.3)\n",
            "Collecting Unidecode>=0.4.20\n",
            "\u001b[?25l  Downloading https://files.pythonhosted.org/packages/d0/42/d9edfed04228bacea2d824904cae367ee9efd05e6cce7ceaaedd0b0ad964/Unidecode-1.1.1-py2.py3-none-any.whl (238kB)\n",
            "\u001b[K     |████████████████████████████████| 245kB 2.7MB/s \n",
            "\u001b[?25hRequirement already satisfied: tensorboard in /usr/local/lib/python3.6/dist-packages (from -r requirements.txt (line 5)) (2.2.2)\n",
            "Collecting tensorboardX\n",
            "\u001b[?25l  Downloading https://files.pythonhosted.org/packages/af/0c/4f41bcd45db376e6fe5c619c01100e9b7531c55791b7244815bac6eac32c/tensorboardX-2.1-py2.py3-none-any.whl (308kB)\n",
            "\u001b[K     |████████████████████████████████| 317kB 11.6MB/s \n",
            "\u001b[?25hRequirement already satisfied: matplotlib in /usr/local/lib/python3.6/dist-packages (from -r requirements.txt (line 7)) (3.2.2)\n",
            "Requirement already satisfied: Pillow in /usr/local/lib/python3.6/dist-packages (from -r requirements.txt (line 8)) (7.0.0)\n",
            "Requirement already satisfied: flask in /usr/local/lib/python3.6/dist-packages (from -r requirements.txt (line 9)) (1.1.2)\n",
            "Requirement already satisfied: scipy in /usr/local/lib/python3.6/dist-packages (from -r requirements.txt (line 10)) (1.4.1)\n",
            "Requirement already satisfied: tqdm in /usr/local/lib/python3.6/dist-packages (from -r requirements.txt (line 11)) (4.41.1)\n",
            "Collecting soundfile\n",
            "  Downloading https://files.pythonhosted.org/packages/eb/f2/3cbbbf3b96fb9fa91582c438b574cff3f45b29c772f94c400e2c99ef5db9/SoundFile-0.10.3.post1-py2.py3-none-any.whl\n",
            "Collecting phonemizer\n",
            "\u001b[?25l  Downloading https://files.pythonhosted.org/packages/14/93/b24323b7b7d99d65c41188685f423c66b2e53d0fd959851ac224c2aa2bfb/phonemizer-2.2-py3-none-any.whl (47kB)\n",
            "\u001b[K     |████████████████████████████████| 51kB 6.0MB/s \n",
            "\u001b[?25hRequirement already satisfied: bokeh==1.4.0 in /usr/local/lib/python3.6/dist-packages (from -r requirements.txt (line 14)) (1.4.0)\n",
            "Requirement already satisfied: inflect in /usr/local/lib/python3.6/dist-packages (from -r requirements.txt (line 15)) (2.1.0)\n",
            "Requirement already satisfied: future in /usr/local/lib/python3.6/dist-packages (from torch>=1.5->-r requirements.txt (line 2)) (0.16.0)\n",
            "Requirement already satisfied: numba>=0.38.0 in /usr/local/lib/python3.6/dist-packages (from librosa>=0.5.1->-r requirements.txt (line 3)) (0.48.0)\n",
            "Requirement already satisfied: decorator>=3.0.0 in /usr/local/lib/python3.6/dist-packages (from librosa>=0.5.1->-r requirements.txt (line 3)) (4.4.2)\n",
            "Requirement already satisfied: joblib>=0.12 in /usr/local/lib/python3.6/dist-packages (from librosa>=0.5.1->-r requirements.txt (line 3)) (0.16.0)\n",
            "Requirement already satisfied: audioread>=2.0.0 in /usr/local/lib/python3.6/dist-packages (from librosa>=0.5.1->-r requirements.txt (line 3)) (2.1.8)\n",
            "Requirement already satisfied: six>=1.3 in /usr/local/lib/python3.6/dist-packages (from librosa>=0.5.1->-r requirements.txt (line 3)) (1.12.0)\n",
            "Requirement already satisfied: scikit-learn!=0.19.0,>=0.14.0 in /usr/local/lib/python3.6/dist-packages (from librosa>=0.5.1->-r requirements.txt (line 3)) (0.22.2.post1)\n",
            "Requirement already satisfied: resampy>=0.2.0 in /usr/local/lib/python3.6/dist-packages (from librosa>=0.5.1->-r requirements.txt (line 3)) (0.2.2)\n",
            "Requirement already satisfied: wheel>=0.26; python_version >= \"3\" in /usr/local/lib/python3.6/dist-packages (from tensorboard->-r requirements.txt (line 5)) (0.34.2)\n",
            "Requirement already satisfied: protobuf>=3.6.0 in /usr/local/lib/python3.6/dist-packages (from tensorboard->-r requirements.txt (line 5)) (3.10.0)\n",
            "Requirement already satisfied: markdown>=2.6.8 in /usr/local/lib/python3.6/dist-packages (from tensorboard->-r requirements.txt (line 5)) (3.2.2)\n",
            "Requirement already satisfied: requests<3,>=2.21.0 in /usr/local/lib/python3.6/dist-packages (from tensorboard->-r requirements.txt (line 5)) (2.23.0)\n",
            "Requirement already satisfied: absl-py>=0.4 in /usr/local/lib/python3.6/dist-packages (from tensorboard->-r requirements.txt (line 5)) (0.9.0)\n",
            "Requirement already satisfied: google-auth<2,>=1.6.3 in /usr/local/lib/python3.6/dist-packages (from tensorboard->-r requirements.txt (line 5)) (1.17.2)\n",
            "Requirement already satisfied: grpcio>=1.24.3 in /usr/local/lib/python3.6/dist-packages (from tensorboard->-r requirements.txt (line 5)) (1.30.0)\n",
            "Requirement already satisfied: setuptools>=41.0.0 in /usr/local/lib/python3.6/dist-packages (from tensorboard->-r requirements.txt (line 5)) (49.1.0)\n",
            "Requirement already satisfied: tensorboard-plugin-wit>=1.6.0 in /usr/local/lib/python3.6/dist-packages (from tensorboard->-r requirements.txt (line 5)) (1.7.0)\n",
            "Requirement already satisfied: werkzeug>=0.11.15 in /usr/local/lib/python3.6/dist-packages (from tensorboard->-r requirements.txt (line 5)) (1.0.1)\n",
            "Requirement already satisfied: google-auth-oauthlib<0.5,>=0.4.1 in /usr/local/lib/python3.6/dist-packages (from tensorboard->-r requirements.txt (line 5)) (0.4.1)\n",
            "Requirement already satisfied: pyparsing!=2.0.4,!=2.1.2,!=2.1.6,>=2.0.1 in /usr/local/lib/python3.6/dist-packages (from matplotlib->-r requirements.txt (line 7)) (2.4.7)\n",
            "Requirement already satisfied: cycler>=0.10 in /usr/local/lib/python3.6/dist-packages (from matplotlib->-r requirements.txt (line 7)) (0.10.0)\n",
            "Requirement already satisfied: python-dateutil>=2.1 in /usr/local/lib/python3.6/dist-packages (from matplotlib->-r requirements.txt (line 7)) (2.8.1)\n",
            "Requirement already satisfied: kiwisolver>=1.0.1 in /usr/local/lib/python3.6/dist-packages (from matplotlib->-r requirements.txt (line 7)) (1.2.0)\n",
            "Requirement already satisfied: click>=5.1 in /usr/local/lib/python3.6/dist-packages (from flask->-r requirements.txt (line 9)) (7.1.2)\n",
            "Requirement already satisfied: Jinja2>=2.10.1 in /usr/local/lib/python3.6/dist-packages (from flask->-r requirements.txt (line 9)) (2.11.2)\n",
            "Requirement already satisfied: itsdangerous>=0.24 in /usr/local/lib/python3.6/dist-packages (from flask->-r requirements.txt (line 9)) (1.1.0)\n",
            "Requirement already satisfied: cffi>=1.0 in /usr/local/lib/python3.6/dist-packages (from soundfile->-r requirements.txt (line 12)) (1.14.0)\n",
            "Requirement already satisfied: attrs>=18.1 in /usr/local/lib/python3.6/dist-packages (from phonemizer->-r requirements.txt (line 13)) (19.3.0)\n",
            "Collecting segments\n",
            "  Downloading https://files.pythonhosted.org/packages/5b/a0/0c3fe64787745c39eb3f2f5f5f9ed8d008d9ef22e9d7f9f52f71ea4712f7/segments-2.1.3-py2.py3-none-any.whl\n",
            "Requirement already satisfied: packaging>=16.8 in /usr/local/lib/python3.6/dist-packages (from bokeh==1.4.0->-r requirements.txt (line 14)) (20.4)\n",
            "Requirement already satisfied: tornado>=4.3 in /usr/local/lib/python3.6/dist-packages (from bokeh==1.4.0->-r requirements.txt (line 14)) (4.5.3)\n",
            "Requirement already satisfied: PyYAML>=3.10 in /usr/local/lib/python3.6/dist-packages (from bokeh==1.4.0->-r requirements.txt (line 14)) (3.13)\n",
            "Requirement already satisfied: llvmlite<0.32.0,>=0.31.0dev0 in /usr/local/lib/python3.6/dist-packages (from numba>=0.38.0->librosa>=0.5.1->-r requirements.txt (line 3)) (0.31.0)\n",
            "Requirement already satisfied: importlib-metadata; python_version < \"3.8\" in /usr/local/lib/python3.6/dist-packages (from markdown>=2.6.8->tensorboard->-r requirements.txt (line 5)) (1.7.0)\n",
            "Requirement already satisfied: urllib3!=1.25.0,!=1.25.1,<1.26,>=1.21.1 in /usr/local/lib/python3.6/dist-packages (from requests<3,>=2.21.0->tensorboard->-r requirements.txt (line 5)) (1.24.3)\n",
            "Requirement already satisfied: certifi>=2017.4.17 in /usr/local/lib/python3.6/dist-packages (from requests<3,>=2.21.0->tensorboard->-r requirements.txt (line 5)) (2020.6.20)\n",
            "Requirement already satisfied: idna<3,>=2.5 in /usr/local/lib/python3.6/dist-packages (from requests<3,>=2.21.0->tensorboard->-r requirements.txt (line 5)) (2.10)\n",
            "Requirement already satisfied: chardet<4,>=3.0.2 in /usr/local/lib/python3.6/dist-packages (from requests<3,>=2.21.0->tensorboard->-r requirements.txt (line 5)) (3.0.4)\n",
            "Requirement already satisfied: rsa<5,>=3.1.4; python_version >= \"3\" in /usr/local/lib/python3.6/dist-packages (from google-auth<2,>=1.6.3->tensorboard->-r requirements.txt (line 5)) (4.6)\n",
            "Requirement already satisfied: cachetools<5.0,>=2.0.0 in /usr/local/lib/python3.6/dist-packages (from google-auth<2,>=1.6.3->tensorboard->-r requirements.txt (line 5)) (4.1.1)\n",
            "Requirement already satisfied: pyasn1-modules>=0.2.1 in /usr/local/lib/python3.6/dist-packages (from google-auth<2,>=1.6.3->tensorboard->-r requirements.txt (line 5)) (0.2.8)\n",
            "Requirement already satisfied: requests-oauthlib>=0.7.0 in /usr/local/lib/python3.6/dist-packages (from google-auth-oauthlib<0.5,>=0.4.1->tensorboard->-r requirements.txt (line 5)) (1.3.0)\n",
            "Requirement already satisfied: MarkupSafe>=0.23 in /usr/local/lib/python3.6/dist-packages (from Jinja2>=2.10.1->flask->-r requirements.txt (line 9)) (1.1.1)\n",
            "Requirement already satisfied: pycparser in /usr/local/lib/python3.6/dist-packages (from cffi>=1.0->soundfile->-r requirements.txt (line 12)) (2.20)\n",
            "Collecting clldutils>=1.7.3\n",
            "\u001b[?25l  Downloading https://files.pythonhosted.org/packages/7b/b3/05882a8d5c8a7f7c69a47500334ac99623928edca930278d6ab88ee6d99b/clldutils-3.5.2-py2.py3-none-any.whl (189kB)\n",
            "\u001b[K     |████████████████████████████████| 194kB 13.2MB/s \n",
            "\u001b[?25hCollecting csvw>=1.5.6\n",
            "  Downloading https://files.pythonhosted.org/packages/d1/b6/8fef6788b8f05b21424a17ae3881eff916d42e5c7e87f57a85d9d7abf0a1/csvw-1.7.0-py2.py3-none-any.whl\n",
            "Requirement already satisfied: regex in /usr/local/lib/python3.6/dist-packages (from segments->phonemizer->-r requirements.txt (line 13)) (2019.12.20)\n",
            "Requirement already satisfied: zipp>=0.5 in /usr/local/lib/python3.6/dist-packages (from importlib-metadata; python_version < \"3.8\"->markdown>=2.6.8->tensorboard->-r requirements.txt (line 5)) (3.1.0)\n",
            "Requirement already satisfied: pyasn1>=0.1.3 in /usr/local/lib/python3.6/dist-packages (from rsa<5,>=3.1.4; python_version >= \"3\"->google-auth<2,>=1.6.3->tensorboard->-r requirements.txt (line 5)) (0.4.8)\n",
            "Requirement already satisfied: oauthlib>=3.0.0 in /usr/local/lib/python3.6/dist-packages (from requests-oauthlib>=0.7.0->google-auth-oauthlib<0.5,>=0.4.1->tensorboard->-r requirements.txt (line 5)) (3.1.0)\n",
            "Requirement already satisfied: tabulate>=0.7.7 in /usr/local/lib/python3.6/dist-packages (from clldutils>=1.7.3->segments->phonemizer->-r requirements.txt (line 13)) (0.8.7)\n",
            "Collecting colorlog\n",
            "  Downloading https://files.pythonhosted.org/packages/00/0d/22c73c2eccb21dd3498df7d22c0b1d4a30f5a5fb3feb64e1ce06bc247747/colorlog-4.1.0-py2.py3-none-any.whl\n",
            "Requirement already satisfied: uritemplate>=3.0.0 in /usr/local/lib/python3.6/dist-packages (from csvw>=1.5.6->segments->phonemizer->-r requirements.txt (line 13)) (3.0.1)\n",
            "Collecting isodate\n",
            "\u001b[?25l  Downloading https://files.pythonhosted.org/packages/9b/9f/b36f7774ff5ea8e428fdcfc4bb332c39ee5b9362ddd3d40d9516a55221b2/isodate-0.6.0-py2.py3-none-any.whl (45kB)\n",
            "\u001b[K     |████████████████████████████████| 51kB 6.7MB/s \n",
            "\u001b[?25hCollecting rfc3986\n",
            "  Downloading https://files.pythonhosted.org/packages/78/be/7b8b99fd74ff5684225f50dd0e865393d2265656ef3b4ba9eaaaffe622b8/rfc3986-1.4.0-py2.py3-none-any.whl\n",
            "Installing collected packages: Unidecode, tensorboardX, soundfile, isodate, rfc3986, csvw, colorlog, clldutils, segments, phonemizer\n",
            "Successfully installed Unidecode-1.1.1 clldutils-3.5.2 colorlog-4.1.0 csvw-1.7.0 isodate-0.6.0 phonemizer-2.2 rfc3986-1.4.0 segments-2.1.3 soundfile-0.10.3.post1 tensorboardX-2.1\n",
            "running install\n",
            "running bdist_egg\n",
            "running egg_info\n",
            "creating tts_namespace/TTS.egg-info\n",
            "writing tts_namespace/TTS.egg-info/PKG-INFO\n",
            "writing dependency_links to tts_namespace/TTS.egg-info/dependency_links.txt\n",
            "writing entry points to tts_namespace/TTS.egg-info/entry_points.txt\n",
            "writing requirements to tts_namespace/TTS.egg-info/requires.txt\n",
            "writing top-level names to tts_namespace/TTS.egg-info/top_level.txt\n",
            "writing manifest file 'tts_namespace/TTS.egg-info/SOURCES.txt'\n",
            "writing manifest file 'tts_namespace/TTS.egg-info/SOURCES.txt'\n",
            "installing library code to build/bdist.linux-x86_64/egg\n",
            "running install_lib\n",
            "running build_py\n",
            "-- Building version 0.0.3+c7296b3\n",
            "creating temp_build\n",
            "creating temp_build/TTS\n",
            "copying tts_namespace/TTS/distribute.py -> temp_build/TTS\n",
            "copying tts_namespace/TTS/train.py -> temp_build/TTS\n",
            "copying tts_namespace/TTS/version.py -> temp_build/TTS\n",
            "copying tts_namespace/TTS/compute_statistics.py -> temp_build/TTS\n",
            "copying tts_namespace/TTS/__init__.py -> temp_build/TTS\n",
            "copying tts_namespace/TTS/setup.py -> temp_build/TTS\n",
            "copying tts_namespace/TTS/synthesize.py -> temp_build/TTS\n",
            "creating temp_build/TTS/tests\n",
            "copying tts_namespace/TTS/tests/test_demo_server.py -> temp_build/TTS/tests\n",
            "copying tts_namespace/TTS/tests/test_text_processing.py -> temp_build/TTS/tests\n",
            "copying tts_namespace/TTS/tests/test_preprocessors.py -> temp_build/TTS/tests\n",
            "copying tts_namespace/TTS/tests/test_loader.py -> temp_build/TTS/tests\n",
            "copying tts_namespace/TTS/tests/test_audio.py -> temp_build/TTS/tests\n",
            "copying tts_namespace/TTS/tests/__init__.py -> temp_build/TTS/tests\n",
            "copying tts_namespace/TTS/tests/test_tacotron2_model.py -> temp_build/TTS/tests\n",
            "copying tts_namespace/TTS/tests/generic_utils_text.py -> temp_build/TTS/tests\n",
            "copying tts_namespace/TTS/tests/test_tacotron_model.py -> temp_build/TTS/tests\n",
            "copying tts_namespace/TTS/tests/symbols_tests.py -> temp_build/TTS/tests\n",
            "copying tts_namespace/TTS/tests/test_layers.py -> temp_build/TTS/tests\n",
            "creating temp_build/TTS/utils\n",
            "copying tts_namespace/TTS/utils/data.py -> temp_build/TTS/utils\n",
            "copying tts_namespace/TTS/utils/radam.py -> temp_build/TTS/utils\n",
            "copying tts_namespace/TTS/utils/training.py -> temp_build/TTS/utils\n",
            "copying tts_namespace/TTS/utils/console_logger.py -> temp_build/TTS/utils\n",
            "copying tts_namespace/TTS/utils/__init__.py -> temp_build/TTS/utils\n",
            "copying tts_namespace/TTS/utils/visual.py -> temp_build/TTS/utils\n",
            "copying tts_namespace/TTS/utils/audio.py -> temp_build/TTS/utils\n",
            "copying tts_namespace/TTS/utils/tensorboard_logger.py -> temp_build/TTS/utils\n",
            "copying tts_namespace/TTS/utils/speakers.py -> temp_build/TTS/utils\n",
            "copying tts_namespace/TTS/utils/measures.py -> temp_build/TTS/utils\n",
            "copying tts_namespace/TTS/utils/generic_utils.py -> temp_build/TTS/utils\n",
            "copying tts_namespace/TTS/utils/io.py -> temp_build/TTS/utils\n",
            "copying tts_namespace/TTS/utils/synthesis.py -> temp_build/TTS/utils\n",
            "creating temp_build/TTS/vocoder\n",
            "copying tts_namespace/TTS/vocoder/train.py -> temp_build/TTS/vocoder\n",
            "copying tts_namespace/TTS/vocoder/__init__.py -> temp_build/TTS/vocoder\n",
            "copying tts_namespace/TTS/vocoder/compute_tts_features.py -> temp_build/TTS/vocoder\n",
            "creating temp_build/TTS/speaker_encoder\n",
            "copying tts_namespace/TTS/speaker_encoder/compute_embeddings.py -> temp_build/TTS/speaker_encoder\n",
            "copying tts_namespace/TTS/speaker_encoder/loss.py -> temp_build/TTS/speaker_encoder\n",
            "copying tts_namespace/TTS/speaker_encoder/train.py -> temp_build/TTS/speaker_encoder\n",
            "copying tts_namespace/TTS/speaker_encoder/dataset.py -> temp_build/TTS/speaker_encoder\n",
            "copying tts_namespace/TTS/speaker_encoder/__init__.py -> temp_build/TTS/speaker_encoder\n",
            "copying tts_namespace/TTS/speaker_encoder/visual.py -> temp_build/TTS/speaker_encoder\n",
            "copying tts_namespace/TTS/speaker_encoder/model.py -> temp_build/TTS/speaker_encoder\n",
            "copying tts_namespace/TTS/speaker_encoder/tests.py -> temp_build/TTS/speaker_encoder\n",
            "copying tts_namespace/TTS/speaker_encoder/generic_utils.py -> temp_build/TTS/speaker_encoder\n",
            "creating temp_build/TTS/models\n",
            "copying tts_namespace/TTS/models/tacotron.py -> temp_build/TTS/models\n",
            "copying tts_namespace/TTS/models/__init__.py -> temp_build/TTS/models\n",
            "copying tts_namespace/TTS/models/tacotron_abstract.py -> temp_build/TTS/models\n",
            "copying tts_namespace/TTS/models/tacotron2.py -> temp_build/TTS/models\n",
            "creating temp_build/TTS/layers\n",
            "copying tts_namespace/TTS/layers/tacotron.py -> temp_build/TTS/layers\n",
            "copying tts_namespace/TTS/layers/gst_layers.py -> temp_build/TTS/layers\n",
            "copying tts_namespace/TTS/layers/losses.py -> temp_build/TTS/layers\n",
            "copying tts_namespace/TTS/layers/__init__.py -> temp_build/TTS/layers\n",
            "copying tts_namespace/TTS/layers/common_layers.py -> temp_build/TTS/layers\n",
            "copying tts_namespace/TTS/layers/tacotron2.py -> temp_build/TTS/layers\n",
            "creating temp_build/TTS/server\n",
            "copying tts_namespace/TTS/server/server.py -> temp_build/TTS/server\n",
            "copying tts_namespace/TTS/server/__init__.py -> temp_build/TTS/server\n",
            "copying tts_namespace/TTS/server/synthesizer.py -> temp_build/TTS/server\n",
            "creating temp_build/TTS/datasets\n",
            "copying tts_namespace/TTS/datasets/TTSDataset.py -> temp_build/TTS/datasets\n",
            "copying tts_namespace/TTS/datasets/preprocess.py -> temp_build/TTS/datasets\n",
            "copying tts_namespace/TTS/datasets/__init__.py -> temp_build/TTS/datasets\n",
            "creating temp_build/TTS/utils/text\n",
            "copying tts_namespace/TTS/utils/text/symbols.py -> temp_build/TTS/utils/text\n",
            "copying tts_namespace/TTS/utils/text/number_norm.py -> temp_build/TTS/utils/text\n",
            "copying tts_namespace/TTS/utils/text/cmudict.py -> temp_build/TTS/utils/text\n",
            "copying tts_namespace/TTS/utils/text/__init__.py -> temp_build/TTS/utils/text\n",
            "copying tts_namespace/TTS/utils/text/cleaners.py -> temp_build/TTS/utils/text\n",
            "creating temp_build/TTS/vocoder/tests\n",
            "copying tts_namespace/TTS/vocoder/tests/test_losses.py -> temp_build/TTS/vocoder/tests\n",
            "copying tts_namespace/TTS/vocoder/tests/test_pqmf.py -> temp_build/TTS/vocoder/tests\n",
            "copying tts_namespace/TTS/vocoder/tests/test_datasets.py -> temp_build/TTS/vocoder/tests\n",
            "copying tts_namespace/TTS/vocoder/tests/test_melgan_discriminator.py -> temp_build/TTS/vocoder/tests\n",
            "copying tts_namespace/TTS/vocoder/tests/test_melgan_generator.py -> temp_build/TTS/vocoder/tests\n",
            "copying tts_namespace/TTS/vocoder/tests/__init__.py -> temp_build/TTS/vocoder/tests\n",
            "copying tts_namespace/TTS/vocoder/tests/test_rwd.py -> temp_build/TTS/vocoder/tests\n",
            "creating temp_build/TTS/vocoder/utils\n",
            "copying tts_namespace/TTS/vocoder/utils/console_logger.py -> temp_build/TTS/vocoder/utils\n",
            "copying tts_namespace/TTS/vocoder/utils/__init__.py -> temp_build/TTS/vocoder/utils\n",
            "copying tts_namespace/TTS/vocoder/utils/generic_utils.py -> temp_build/TTS/vocoder/utils\n",
            "copying tts_namespace/TTS/vocoder/utils/io.py -> temp_build/TTS/vocoder/utils\n",
            "creating temp_build/TTS/vocoder/models\n",
            "copying tts_namespace/TTS/vocoder/models/melgan_discriminator.py -> temp_build/TTS/vocoder/models\n",
            "copying tts_namespace/TTS/vocoder/models/random_window_discriminator.py -> temp_build/TTS/vocoder/models\n",
            "copying tts_namespace/TTS/vocoder/models/__init__.py -> temp_build/TTS/vocoder/models\n",
            "copying tts_namespace/TTS/vocoder/models/multiband_melgan_generator.py -> temp_build/TTS/vocoder/models\n",
            "copying tts_namespace/TTS/vocoder/models/melgan_multiscale_discriminator.py -> temp_build/TTS/vocoder/models\n",
            "copying tts_namespace/TTS/vocoder/models/melgan_generator.py -> temp_build/TTS/vocoder/models\n",
            "creating temp_build/TTS/vocoder/layers\n",
            "copying tts_namespace/TTS/vocoder/layers/pqmf.py -> temp_build/TTS/vocoder/layers\n",
            "copying tts_namespace/TTS/vocoder/layers/losses.py -> temp_build/TTS/vocoder/layers\n",
            "copying tts_namespace/TTS/vocoder/layers/__init__.py -> temp_build/TTS/vocoder/layers\n",
            "copying tts_namespace/TTS/vocoder/layers/melgan.py -> temp_build/TTS/vocoder/layers\n",
            "creating temp_build/TTS/vocoder/datasets\n",
            "copying tts_namespace/TTS/vocoder/datasets/preprocess.py -> temp_build/TTS/vocoder/datasets\n",
            "copying tts_namespace/TTS/vocoder/datasets/__init__.py -> temp_build/TTS/vocoder/datasets\n",
            "copying tts_namespace/TTS/vocoder/datasets/gan_dataset.py -> temp_build/TTS/vocoder/datasets\n",
            "creating temp_build/TTS/server/templates\n",
            "copying tts_namespace/TTS/server/templates/index.html -> temp_build/TTS/server/templates\n",
            "creating build\n",
            "creating build/bdist.linux-x86_64\n",
            "creating build/bdist.linux-x86_64/egg\n",
            "creating build/bdist.linux-x86_64/egg/TTS\n",
            "creating build/bdist.linux-x86_64/egg/TTS/tests\n",
            "copying temp_build/TTS/tests/test_demo_server.py -> build/bdist.linux-x86_64/egg/TTS/tests\n",
            "copying temp_build/TTS/tests/test_text_processing.py -> build/bdist.linux-x86_64/egg/TTS/tests\n",
            "copying temp_build/TTS/tests/test_preprocessors.py -> build/bdist.linux-x86_64/egg/TTS/tests\n",
            "copying temp_build/TTS/tests/test_loader.py -> build/bdist.linux-x86_64/egg/TTS/tests\n",
            "copying temp_build/TTS/tests/test_audio.py -> build/bdist.linux-x86_64/egg/TTS/tests\n",
            "copying temp_build/TTS/tests/__init__.py -> build/bdist.linux-x86_64/egg/TTS/tests\n",
            "copying temp_build/TTS/tests/test_tacotron2_model.py -> build/bdist.linux-x86_64/egg/TTS/tests\n",
            "copying temp_build/TTS/tests/generic_utils_text.py -> build/bdist.linux-x86_64/egg/TTS/tests\n",
            "copying temp_build/TTS/tests/test_tacotron_model.py -> build/bdist.linux-x86_64/egg/TTS/tests\n",
            "copying temp_build/TTS/tests/symbols_tests.py -> build/bdist.linux-x86_64/egg/TTS/tests\n",
            "copying temp_build/TTS/tests/test_layers.py -> build/bdist.linux-x86_64/egg/TTS/tests\n",
            "creating build/bdist.linux-x86_64/egg/TTS/utils\n",
            "creating build/bdist.linux-x86_64/egg/TTS/utils/text\n",
            "copying temp_build/TTS/utils/text/symbols.py -> build/bdist.linux-x86_64/egg/TTS/utils/text\n",
            "copying temp_build/TTS/utils/text/number_norm.py -> build/bdist.linux-x86_64/egg/TTS/utils/text\n",
            "copying temp_build/TTS/utils/text/cmudict.py -> build/bdist.linux-x86_64/egg/TTS/utils/text\n",
            "copying temp_build/TTS/utils/text/__init__.py -> build/bdist.linux-x86_64/egg/TTS/utils/text\n",
            "copying temp_build/TTS/utils/text/cleaners.py -> build/bdist.linux-x86_64/egg/TTS/utils/text\n",
            "copying temp_build/TTS/utils/data.py -> build/bdist.linux-x86_64/egg/TTS/utils\n",
            "copying temp_build/TTS/utils/radam.py -> build/bdist.linux-x86_64/egg/TTS/utils\n",
            "copying temp_build/TTS/utils/training.py -> build/bdist.linux-x86_64/egg/TTS/utils\n",
            "copying temp_build/TTS/utils/console_logger.py -> build/bdist.linux-x86_64/egg/TTS/utils\n",
            "copying temp_build/TTS/utils/__init__.py -> build/bdist.linux-x86_64/egg/TTS/utils\n",
            "copying temp_build/TTS/utils/visual.py -> build/bdist.linux-x86_64/egg/TTS/utils\n",
            "copying temp_build/TTS/utils/audio.py -> build/bdist.linux-x86_64/egg/TTS/utils\n",
            "copying temp_build/TTS/utils/tensorboard_logger.py -> build/bdist.linux-x86_64/egg/TTS/utils\n",
            "copying temp_build/TTS/utils/speakers.py -> build/bdist.linux-x86_64/egg/TTS/utils\n",
            "copying temp_build/TTS/utils/measures.py -> build/bdist.linux-x86_64/egg/TTS/utils\n",
            "copying temp_build/TTS/utils/generic_utils.py -> build/bdist.linux-x86_64/egg/TTS/utils\n",
            "copying temp_build/TTS/utils/io.py -> build/bdist.linux-x86_64/egg/TTS/utils\n",
            "copying temp_build/TTS/utils/synthesis.py -> build/bdist.linux-x86_64/egg/TTS/utils\n",
            "copying temp_build/TTS/distribute.py -> build/bdist.linux-x86_64/egg/TTS\n",
            "copying temp_build/TTS/train.py -> build/bdist.linux-x86_64/egg/TTS\n",
            "copying temp_build/TTS/version.py -> build/bdist.linux-x86_64/egg/TTS\n",
            "copying temp_build/TTS/compute_statistics.py -> build/bdist.linux-x86_64/egg/TTS\n",
            "copying temp_build/TTS/__init__.py -> build/bdist.linux-x86_64/egg/TTS\n",
            "creating build/bdist.linux-x86_64/egg/TTS/vocoder\n",
            "creating build/bdist.linux-x86_64/egg/TTS/vocoder/tests\n",
            "copying temp_build/TTS/vocoder/tests/test_losses.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/tests\n",
            "copying temp_build/TTS/vocoder/tests/test_pqmf.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/tests\n",
            "copying temp_build/TTS/vocoder/tests/test_datasets.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/tests\n",
            "copying temp_build/TTS/vocoder/tests/test_melgan_discriminator.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/tests\n",
            "copying temp_build/TTS/vocoder/tests/test_melgan_generator.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/tests\n",
            "copying temp_build/TTS/vocoder/tests/__init__.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/tests\n",
            "copying temp_build/TTS/vocoder/tests/test_rwd.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/tests\n",
            "creating build/bdist.linux-x86_64/egg/TTS/vocoder/utils\n",
            "copying temp_build/TTS/vocoder/utils/console_logger.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/utils\n",
            "copying temp_build/TTS/vocoder/utils/__init__.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/utils\n",
            "copying temp_build/TTS/vocoder/utils/generic_utils.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/utils\n",
            "copying temp_build/TTS/vocoder/utils/io.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/utils\n",
            "copying temp_build/TTS/vocoder/train.py -> build/bdist.linux-x86_64/egg/TTS/vocoder\n",
            "copying temp_build/TTS/vocoder/__init__.py -> build/bdist.linux-x86_64/egg/TTS/vocoder\n",
            "creating build/bdist.linux-x86_64/egg/TTS/vocoder/models\n",
            "copying temp_build/TTS/vocoder/models/melgan_discriminator.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/models\n",
            "copying temp_build/TTS/vocoder/models/random_window_discriminator.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/models\n",
            "copying temp_build/TTS/vocoder/models/__init__.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/models\n",
            "copying temp_build/TTS/vocoder/models/multiband_melgan_generator.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/models\n",
            "copying temp_build/TTS/vocoder/models/melgan_multiscale_discriminator.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/models\n",
            "copying temp_build/TTS/vocoder/models/melgan_generator.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/models\n",
            "copying temp_build/TTS/vocoder/compute_tts_features.py -> build/bdist.linux-x86_64/egg/TTS/vocoder\n",
            "creating build/bdist.linux-x86_64/egg/TTS/vocoder/layers\n",
            "copying temp_build/TTS/vocoder/layers/pqmf.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/layers\n",
            "copying temp_build/TTS/vocoder/layers/losses.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/layers\n",
            "copying temp_build/TTS/vocoder/layers/__init__.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/layers\n",
            "copying temp_build/TTS/vocoder/layers/melgan.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/layers\n",
            "creating build/bdist.linux-x86_64/egg/TTS/vocoder/datasets\n",
            "copying temp_build/TTS/vocoder/datasets/preprocess.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/datasets\n",
            "copying temp_build/TTS/vocoder/datasets/__init__.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/datasets\n",
            "copying temp_build/TTS/vocoder/datasets/gan_dataset.py -> build/bdist.linux-x86_64/egg/TTS/vocoder/datasets\n",
            "creating build/bdist.linux-x86_64/egg/TTS/speaker_encoder\n",
            "copying temp_build/TTS/speaker_encoder/compute_embeddings.py -> build/bdist.linux-x86_64/egg/TTS/speaker_encoder\n",
            "copying temp_build/TTS/speaker_encoder/loss.py -> build/bdist.linux-x86_64/egg/TTS/speaker_encoder\n",
            "copying temp_build/TTS/speaker_encoder/train.py -> build/bdist.linux-x86_64/egg/TTS/speaker_encoder\n",
            "copying temp_build/TTS/speaker_encoder/dataset.py -> build/bdist.linux-x86_64/egg/TTS/speaker_encoder\n",
            "copying temp_build/TTS/speaker_encoder/__init__.py -> build/bdist.linux-x86_64/egg/TTS/speaker_encoder\n",
            "copying temp_build/TTS/speaker_encoder/visual.py -> build/bdist.linux-x86_64/egg/TTS/speaker_encoder\n",
            "copying temp_build/TTS/speaker_encoder/model.py -> build/bdist.linux-x86_64/egg/TTS/speaker_encoder\n",
            "copying temp_build/TTS/speaker_encoder/tests.py -> build/bdist.linux-x86_64/egg/TTS/speaker_encoder\n",
            "copying temp_build/TTS/speaker_encoder/generic_utils.py -> build/bdist.linux-x86_64/egg/TTS/speaker_encoder\n",
            "copying temp_build/TTS/setup.py -> build/bdist.linux-x86_64/egg/TTS\n",
            "copying temp_build/TTS/synthesize.py -> build/bdist.linux-x86_64/egg/TTS\n",
            "creating build/bdist.linux-x86_64/egg/TTS/models\n",
            "copying temp_build/TTS/models/tacotron.py -> build/bdist.linux-x86_64/egg/TTS/models\n",
            "copying temp_build/TTS/models/__init__.py -> build/bdist.linux-x86_64/egg/TTS/models\n",
            "copying temp_build/TTS/models/tacotron_abstract.py -> build/bdist.linux-x86_64/egg/TTS/models\n",
            "copying temp_build/TTS/models/tacotron2.py -> build/bdist.linux-x86_64/egg/TTS/models\n",
            "creating build/bdist.linux-x86_64/egg/TTS/layers\n",
            "copying temp_build/TTS/layers/tacotron.py -> build/bdist.linux-x86_64/egg/TTS/layers\n",
            "copying temp_build/TTS/layers/gst_layers.py -> build/bdist.linux-x86_64/egg/TTS/layers\n",
            "copying temp_build/TTS/layers/losses.py -> build/bdist.linux-x86_64/egg/TTS/layers\n",
            "copying temp_build/TTS/layers/__init__.py -> build/bdist.linux-x86_64/egg/TTS/layers\n",
            "copying temp_build/TTS/layers/common_layers.py -> build/bdist.linux-x86_64/egg/TTS/layers\n",
            "copying temp_build/TTS/layers/tacotron2.py -> build/bdist.linux-x86_64/egg/TTS/layers\n",
            "creating build/bdist.linux-x86_64/egg/TTS/server\n",
            "copying temp_build/TTS/server/server.py -> build/bdist.linux-x86_64/egg/TTS/server\n",
            "creating build/bdist.linux-x86_64/egg/TTS/server/templates\n",
            "copying temp_build/TTS/server/templates/index.html -> build/bdist.linux-x86_64/egg/TTS/server/templates\n",
            "copying temp_build/TTS/server/__init__.py -> build/bdist.linux-x86_64/egg/TTS/server\n",
            "copying temp_build/TTS/server/synthesizer.py -> build/bdist.linux-x86_64/egg/TTS/server\n",
            "creating build/bdist.linux-x86_64/egg/TTS/datasets\n",
            "copying temp_build/TTS/datasets/TTSDataset.py -> build/bdist.linux-x86_64/egg/TTS/datasets\n",
            "copying temp_build/TTS/datasets/preprocess.py -> build/bdist.linux-x86_64/egg/TTS/datasets\n",
            "copying temp_build/TTS/datasets/__init__.py -> build/bdist.linux-x86_64/egg/TTS/datasets\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/tests/test_demo_server.py to test_demo_server.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/tests/test_text_processing.py to test_text_processing.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/tests/test_preprocessors.py to test_preprocessors.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/tests/test_loader.py to test_loader.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/tests/test_audio.py to test_audio.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/tests/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/tests/test_tacotron2_model.py to test_tacotron2_model.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/tests/generic_utils_text.py to generic_utils_text.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/tests/test_tacotron_model.py to test_tacotron_model.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/tests/symbols_tests.py to symbols_tests.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/tests/test_layers.py to test_layers.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/text/symbols.py to symbols.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/text/number_norm.py to number_norm.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/text/cmudict.py to cmudict.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/text/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/text/cleaners.py to cleaners.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/data.py to data.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/radam.py to radam.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/training.py to training.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/console_logger.py to console_logger.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/visual.py to visual.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/audio.py to audio.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/tensorboard_logger.py to tensorboard_logger.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/speakers.py to speakers.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/measures.py to measures.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/generic_utils.py to generic_utils.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/io.py to io.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/utils/synthesis.py to synthesis.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/distribute.py to distribute.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/train.py to train.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/version.py to version.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/compute_statistics.py to compute_statistics.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/tests/test_losses.py to test_losses.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/tests/test_pqmf.py to test_pqmf.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/tests/test_datasets.py to test_datasets.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/tests/test_melgan_discriminator.py to test_melgan_discriminator.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/tests/test_melgan_generator.py to test_melgan_generator.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/tests/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/tests/test_rwd.py to test_rwd.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/utils/console_logger.py to console_logger.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/utils/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/utils/generic_utils.py to generic_utils.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/utils/io.py to io.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/train.py to train.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/models/melgan_discriminator.py to melgan_discriminator.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/models/random_window_discriminator.py to random_window_discriminator.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/models/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/models/multiband_melgan_generator.py to multiband_melgan_generator.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/models/melgan_multiscale_discriminator.py to melgan_multiscale_discriminator.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/models/melgan_generator.py to melgan_generator.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/compute_tts_features.py to compute_tts_features.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/layers/pqmf.py to pqmf.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/layers/losses.py to losses.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/layers/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/layers/melgan.py to melgan.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/datasets/preprocess.py to preprocess.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/datasets/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/vocoder/datasets/gan_dataset.py to gan_dataset.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/speaker_encoder/compute_embeddings.py to compute_embeddings.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/speaker_encoder/loss.py to loss.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/speaker_encoder/train.py to train.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/speaker_encoder/dataset.py to dataset.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/speaker_encoder/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/speaker_encoder/visual.py to visual.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/speaker_encoder/model.py to model.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/speaker_encoder/tests.py to tests.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/speaker_encoder/generic_utils.py to generic_utils.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/setup.py to setup.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/synthesize.py to synthesize.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/models/tacotron.py to tacotron.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/models/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/models/tacotron_abstract.py to tacotron_abstract.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/models/tacotron2.py to tacotron2.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/layers/tacotron.py to tacotron.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/layers/gst_layers.py to gst_layers.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/layers/losses.py to losses.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/layers/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/layers/common_layers.py to common_layers.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/layers/tacotron2.py to tacotron2.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/server/server.py to server.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/server/__init__.py to __init__.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/server/synthesizer.py to synthesizer.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/datasets/TTSDataset.py to TTSDataset.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/datasets/preprocess.py to preprocess.cpython-36.pyc\n",
            "byte-compiling build/bdist.linux-x86_64/egg/TTS/datasets/__init__.py to __init__.cpython-36.pyc\n",
            "creating build/bdist.linux-x86_64/egg/EGG-INFO\n",
            "copying tts_namespace/TTS.egg-info/PKG-INFO -> build/bdist.linux-x86_64/egg/EGG-INFO\n",
            "copying tts_namespace/TTS.egg-info/SOURCES.txt -> build/bdist.linux-x86_64/egg/EGG-INFO\n",
            "copying tts_namespace/TTS.egg-info/dependency_links.txt -> build/bdist.linux-x86_64/egg/EGG-INFO\n",
            "copying tts_namespace/TTS.egg-info/entry_points.txt -> build/bdist.linux-x86_64/egg/EGG-INFO\n",
            "copying tts_namespace/TTS.egg-info/requires.txt -> build/bdist.linux-x86_64/egg/EGG-INFO\n",
            "copying tts_namespace/TTS.egg-info/top_level.txt -> build/bdist.linux-x86_64/egg/EGG-INFO\n",
            "zip_safe flag not set; analyzing archive contents...\n",
            "TTS.__pycache__.setup.cpython-36: module references __file__\n",
            "TTS.__pycache__.train.cpython-36: module references __file__\n",
            "TTS.server.__pycache__.server.cpython-36: module references __file__\n",
            "TTS.speaker_encoder.__pycache__.tests.cpython-36: module references __file__\n",
            "TTS.speaker_encoder.__pycache__.train.cpython-36: module references __file__\n",
            "TTS.tests.__pycache__.__init__.cpython-36: module references __file__\n",
            "TTS.tests.__pycache__.test_loader.cpython-36: module references __file__\n",
            "TTS.tests.__pycache__.test_tacotron2_model.cpython-36: module references __file__\n",
            "TTS.tests.__pycache__.test_tacotron_model.cpython-36: module references __file__\n",
            "TTS.vocoder.__pycache__.train.cpython-36: module references __file__\n",
            "TTS.vocoder.tests.__pycache__.test_datasets.cpython-36: module references __file__\n",
            "TTS.vocoder.tests.__pycache__.test_losses.cpython-36: module references __file__\n",
            "creating dist\n",
            "creating 'dist/TTS-0.0.3+c7296b3-py3.6.egg' and adding 'build/bdist.linux-x86_64/egg' to it\n",
            "removing 'build/bdist.linux-x86_64/egg' (and everything under it)\n",
            "Processing TTS-0.0.3+c7296b3-py3.6.egg\n",
            "creating /usr/local/lib/python3.6/dist-packages/TTS-0.0.3+c7296b3-py3.6.egg\n",
            "Extracting TTS-0.0.3+c7296b3-py3.6.egg to /usr/local/lib/python3.6/dist-packages\n",
            "Adding TTS 0.0.3+c7296b3 to easy-install.pth file\n",
            "Installing tts-server script to /usr/local/bin\n",
            "\n",
            "Installed /usr/local/lib/python3.6/dist-packages/TTS-0.0.3+c7296b3-py3.6.egg\n",
            "Processing dependencies for TTS==0.0.3+c7296b3\n",
            "Searching for attrdict\n",
            "Reading https://pypi.org/simple/attrdict/\n",
            "Downloading https://files.pythonhosted.org/packages/ef/97/28fe7e68bc7adfce67d4339756e85e9fcf3c6fd7f0c0781695352b70472c/attrdict-2.0.1-py2.py3-none-any.whl#sha256=9432e3498c74ff7e1b20b3d93b45d766b71cbffa90923496f82c4ae38b92be34\n",
            "Best match: attrdict 2.0.1\n",
            "Processing attrdict-2.0.1-py2.py3-none-any.whl\n",
            "Installing attrdict-2.0.1-py2.py3-none-any.whl to /usr/local/lib/python3.6/dist-packages\n",
            "Adding attrdict 2.0.1 to easy-install.pth file\n",
            "\n",
            "Installed /usr/local/lib/python3.6/dist-packages/attrdict-2.0.1-py3.6.egg\n",
            "Searching for unidecode==0.4.20\n",
            "Reading https://pypi.org/simple/unidecode/\n",
            "Downloading https://files.pythonhosted.org/packages/c3/6f/05f5deb753d0594583aa1cc0d2fe9d631d9a00e9b28d0da49f8d3763755b/Unidecode-0.04.20-py2.py3-none-any.whl#sha256=eedac7bfd886f43484787206f6a141b232e2b2a58652c54d06499b187fd84660\n",
            "Best match: Unidecode 0.4.20\n",
            "Processing Unidecode-0.04.20-py2.py3-none-any.whl\n",
            "Installing Unidecode-0.04.20-py2.py3-none-any.whl to /usr/local/lib/python3.6/dist-packages\n",
            "Adding Unidecode 0.4.20 to easy-install.pth file\n",
            "Installing unidecode script to /usr/local/bin\n",
            "\n",
            "Installed /usr/local/lib/python3.6/dist-packages/Unidecode-0.4.20-py3.6.egg\n",
            "Searching for librosa==0.6.2\n",
            "Reading https://pypi.org/simple/librosa/\n",
            "Downloading https://files.pythonhosted.org/packages/09/b4/5b411f19de48f8fc1a0ff615555aa9124952e4156e94d4803377e50cfa4c/librosa-0.6.2.tar.gz#sha256=2aa868b8aade749b9904eeb7034fcf44115601c367969b6d01f5e1b4b9b6031d\n",
            "Best match: librosa 0.6.2\n",
            "Processing librosa-0.6.2.tar.gz\n",
            "Writing /tmp/easy_install-3oxyyk5x/librosa-0.6.2/setup.cfg\n",
            "Running librosa-0.6.2/setup.py -q bdist_egg --dist-dir /tmp/easy_install-3oxyyk5x/librosa-0.6.2/egg-dist-tmp-ky3tcqa8\n",
            "zip_safe flag not set; analyzing archive contents...\n",
            "librosa.util.__pycache__.deprecation.cpython-36: module MAY be using inspect.stack\n",
            "creating /usr/local/lib/python3.6/dist-packages/librosa-0.6.2-py3.6.egg\n",
            "Extracting librosa-0.6.2-py3.6.egg to /usr/local/lib/python3.6/dist-packages\n",
            "Adding librosa 0.6.2 to easy-install.pth file\n",
            "\n",
            "Installed /usr/local/lib/python3.6/dist-packages/librosa-0.6.2-py3.6.egg\n",
            "Searching for phonemizer==2.2\n",
            "Best match: phonemizer 2.2\n",
            "Adding phonemizer 2.2 to easy-install.pth file\n",
            "Installing phonemize script to /usr/local/bin\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for SoundFile==0.10.3.post1\n",
            "Best match: SoundFile 0.10.3.post1\n",
            "Adding SoundFile 0.10.3.post1 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for bokeh==1.4.0\n",
            "Best match: bokeh 1.4.0\n",
            "Adding bokeh 1.4.0 to easy-install.pth file\n",
            "Installing bokeh script to /usr/local/bin\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for inflect==2.1.0\n",
            "Best match: inflect 2.1.0\n",
            "Adding inflect 2.1.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for tqdm==4.41.1\n",
            "Best match: tqdm 4.41.1\n",
            "Adding tqdm 4.41.1 to easy-install.pth file\n",
            "Installing tqdm script to /usr/local/bin\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for Flask==1.1.2\n",
            "Best match: Flask 1.1.2\n",
            "Adding Flask 1.1.2 to easy-install.pth file\n",
            "Installing flask script to /usr/local/bin\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for Pillow==7.0.0\n",
            "Best match: Pillow 7.0.0\n",
            "Adding Pillow 7.0.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for matplotlib==3.2.2\n",
            "Best match: matplotlib 3.2.2\n",
            "Adding matplotlib 3.2.2 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for tensorboardX==2.1\n",
            "Best match: tensorboardX 2.1\n",
            "Adding tensorboardX 2.1 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for numpy==1.18.5\n",
            "Best match: numpy 1.18.5\n",
            "Adding numpy 1.18.5 to easy-install.pth file\n",
            "Installing f2py script to /usr/local/bin\n",
            "Installing f2py3 script to /usr/local/bin\n",
            "Installing f2py3.6 script to /usr/local/bin\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for torch==1.5.1+cu101\n",
            "Best match: torch 1.5.1+cu101\n",
            "Adding torch 1.5.1+cu101 to easy-install.pth file\n",
            "Installing convert-caffe2-to-onnx script to /usr/local/bin\n",
            "Installing convert-onnx-to-caffe2 script to /usr/local/bin\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for scipy==1.4.1\n",
            "Best match: scipy 1.4.1\n",
            "Adding scipy 1.4.1 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for attrs==19.3.0\n",
            "Best match: attrs 19.3.0\n",
            "Adding attrs 19.3.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for segments==2.1.3\n",
            "Best match: segments 2.1.3\n",
            "Adding segments 2.1.3 to easy-install.pth file\n",
            "Installing segments script to /usr/local/bin\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for joblib==0.16.0\n",
            "Best match: joblib 0.16.0\n",
            "Adding joblib 0.16.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for cffi==1.14.0\n",
            "Best match: cffi 1.14.0\n",
            "Adding cffi 1.14.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for python-dateutil==2.8.1\n",
            "Best match: python-dateutil 2.8.1\n",
            "Adding python-dateutil 2.8.1 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for packaging==20.4\n",
            "Best match: packaging 20.4\n",
            "Adding packaging 20.4 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for Jinja2==2.11.2\n",
            "Best match: Jinja2 2.11.2\n",
            "Adding Jinja2 2.11.2 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for PyYAML==3.13\n",
            "Best match: PyYAML 3.13\n",
            "Adding PyYAML 3.13 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for six==1.12.0\n",
            "Best match: six 1.12.0\n",
            "Adding six 1.12.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for tornado==4.5.3\n",
            "Best match: tornado 4.5.3\n",
            "Adding tornado 4.5.3 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for Werkzeug==1.0.1\n",
            "Best match: Werkzeug 1.0.1\n",
            "Adding Werkzeug 1.0.1 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for itsdangerous==1.1.0\n",
            "Best match: itsdangerous 1.1.0\n",
            "Adding itsdangerous 1.1.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for click==7.1.2\n",
            "Best match: click 7.1.2\n",
            "Adding click 7.1.2 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for pyparsing==2.4.7\n",
            "Best match: pyparsing 2.4.7\n",
            "Adding pyparsing 2.4.7 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for cycler==0.10.0\n",
            "Best match: cycler 0.10.0\n",
            "Adding cycler 0.10.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for kiwisolver==1.2.0\n",
            "Best match: kiwisolver 1.2.0\n",
            "Adding kiwisolver 1.2.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for protobuf==3.10.0\n",
            "Best match: protobuf 3.10.0\n",
            "Adding protobuf 3.10.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for numba==0.48.0\n",
            "Best match: numba 0.48.0\n",
            "Adding numba 0.48.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for resampy==0.2.2\n",
            "Best match: resampy 0.2.2\n",
            "Adding resampy 0.2.2 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for decorator==4.4.2\n",
            "Best match: decorator 4.4.2\n",
            "Adding decorator 4.4.2 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for scikit-learn==0.22.2.post1\n",
            "Best match: scikit-learn 0.22.2.post1\n",
            "Adding scikit-learn 0.22.2.post1 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for audioread==2.1.8\n",
            "Best match: audioread 2.1.8\n",
            "Adding audioread 2.1.8 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for future==0.16.0\n",
            "Best match: future 0.16.0\n",
            "Adding future 0.16.0 to easy-install.pth file\n",
            "Installing futurize script to /usr/local/bin\n",
            "Installing pasteurize script to /usr/local/bin\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for clldutils==3.5.2\n",
            "Best match: clldutils 3.5.2\n",
            "Adding clldutils 3.5.2 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for regex==2019.12.20\n",
            "Best match: regex 2019.12.20\n",
            "Adding regex 2019.12.20 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for csvw==1.7.0\n",
            "Best match: csvw 1.7.0\n",
            "Adding csvw 1.7.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for pycparser==2.20\n",
            "Best match: pycparser 2.20\n",
            "Adding pycparser 2.20 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for MarkupSafe==1.1.1\n",
            "Best match: MarkupSafe 1.1.1\n",
            "Adding MarkupSafe 1.1.1 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for setuptools==49.1.0\n",
            "Best match: setuptools 49.1.0\n",
            "Adding setuptools 49.1.0 to easy-install.pth file\n",
            "Installing easy_install script to /usr/local/bin\n",
            "Installing easy_install-3.8 script to /usr/local/bin\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for llvmlite==0.31.0\n",
            "Best match: llvmlite 0.31.0\n",
            "Adding llvmlite 0.31.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for tabulate==0.8.7\n",
            "Best match: tabulate 0.8.7\n",
            "Adding tabulate 0.8.7 to easy-install.pth file\n",
            "Installing tabulate script to /usr/local/bin\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for colorlog==4.1.0\n",
            "Best match: colorlog 4.1.0\n",
            "Adding colorlog 4.1.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for rfc3986==1.4.0\n",
            "Best match: rfc3986 1.4.0\n",
            "Adding rfc3986 1.4.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for isodate==0.6.0\n",
            "Best match: isodate 0.6.0\n",
            "Adding isodate 0.6.0 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Searching for uritemplate==3.0.1\n",
            "Best match: uritemplate 3.0.1\n",
            "Adding uritemplate 3.0.1 to easy-install.pth file\n",
            "\n",
            "Using /usr/local/lib/python3.6/dist-packages\n",
            "Finished processing dependencies for TTS==0.0.3+c7296b3\n",
            "Collecting tensorflow==2.3.0rc0\n",
            "\u001b[?25l  Downloading https://files.pythonhosted.org/packages/8b/68/7c6c8e2b65ad4a3ff5ef658c04a6c2802ff7fe55fc7eecacb6efee1abc40/tensorflow-2.3.0rc0-cp36-cp36m-manylinux2010_x86_64.whl (320.3MB)\n",
            "\u001b[K     |████████████████████████████████| 320.3MB 49kB/s \n",
            "\u001b[?25hRequirement already satisfied: astunparse==1.6.3 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (1.6.3)\n",
            "Requirement already satisfied: tensorboard<2.3.0,>=2.2.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (2.2.2)\n",
            "Requirement already satisfied: wheel>=0.26 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (0.34.2)\n",
            "Requirement already satisfied: numpy<1.19.0,>=1.16.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (1.18.5)\n",
            "Requirement already satisfied: grpcio>=1.8.6 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (1.30.0)\n",
            "Requirement already satisfied: absl-py>=0.7.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (0.9.0)\n",
            "Requirement already satisfied: keras-preprocessing<1.2,>=1.1.1 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (1.1.2)\n",
            "Requirement already satisfied: termcolor>=1.1.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (1.1.0)\n",
            "Requirement already satisfied: six>=1.12.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (1.12.0)\n",
            "Requirement already satisfied: gast==0.3.3 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (0.3.3)\n",
            "Requirement already satisfied: h5py<2.11.0,>=2.10.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (2.10.0)\n",
            "Requirement already satisfied: wrapt>=1.11.1 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (1.12.1)\n",
            "Requirement already satisfied: scipy==1.4.1 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (1.4.1)\n",
            "Collecting tf-estimator-nightly<2.3.0.dev2020062302,>=2.3.0.dev2020062301\n",
            "\u001b[?25l  Downloading https://files.pythonhosted.org/packages/17/3b/fb9aafd734da258411bff2a600cabff65c7d201782318791b72422bd973d/tf_estimator_nightly-2.3.0.dev2020062301-py2.py3-none-any.whl (459kB)\n",
            "\u001b[K     |████████████████████████████████| 460kB 35.1MB/s \n",
            "\u001b[?25hRequirement already satisfied: google-pasta>=0.1.8 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (0.2.0)\n",
            "Requirement already satisfied: protobuf>=3.9.2 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (3.10.0)\n",
            "Requirement already satisfied: opt-einsum>=2.3.2 in /usr/local/lib/python3.6/dist-packages (from tensorflow==2.3.0rc0) (3.2.1)\n",
            "Requirement already satisfied: requests<3,>=2.21.0 in /usr/local/lib/python3.6/dist-packages (from tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (2.23.0)\n",
            "Requirement already satisfied: werkzeug>=0.11.15 in /usr/local/lib/python3.6/dist-packages (from tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (1.0.1)\n",
            "Requirement already satisfied: google-auth-oauthlib<0.5,>=0.4.1 in /usr/local/lib/python3.6/dist-packages (from tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (0.4.1)\n",
            "Requirement already satisfied: markdown>=2.6.8 in /usr/local/lib/python3.6/dist-packages (from tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (3.2.2)\n",
            "Requirement already satisfied: setuptools>=41.0.0 in /usr/local/lib/python3.6/dist-packages (from tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (49.1.0)\n",
            "Requirement already satisfied: tensorboard-plugin-wit>=1.6.0 in /usr/local/lib/python3.6/dist-packages (from tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (1.7.0)\n",
            "Requirement already satisfied: google-auth<2,>=1.6.3 in /usr/local/lib/python3.6/dist-packages (from tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (1.17.2)\n",
            "Requirement already satisfied: certifi>=2017.4.17 in /usr/local/lib/python3.6/dist-packages (from requests<3,>=2.21.0->tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (2020.6.20)\n",
            "Requirement already satisfied: idna<3,>=2.5 in /usr/local/lib/python3.6/dist-packages (from requests<3,>=2.21.0->tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (2.10)\n",
            "Requirement already satisfied: urllib3!=1.25.0,!=1.25.1,<1.26,>=1.21.1 in /usr/local/lib/python3.6/dist-packages (from requests<3,>=2.21.0->tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (1.24.3)\n",
            "Requirement already satisfied: chardet<4,>=3.0.2 in /usr/local/lib/python3.6/dist-packages (from requests<3,>=2.21.0->tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (3.0.4)\n",
            "Requirement already satisfied: requests-oauthlib>=0.7.0 in /usr/local/lib/python3.6/dist-packages (from google-auth-oauthlib<0.5,>=0.4.1->tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (1.3.0)\n",
            "Requirement already satisfied: importlib-metadata; python_version < \"3.8\" in /usr/local/lib/python3.6/dist-packages (from markdown>=2.6.8->tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (1.7.0)\n",
            "Requirement already satisfied: rsa<5,>=3.1.4; python_version >= \"3\" in /usr/local/lib/python3.6/dist-packages (from google-auth<2,>=1.6.3->tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (4.6)\n",
            "Requirement already satisfied: pyasn1-modules>=0.2.1 in /usr/local/lib/python3.6/dist-packages (from google-auth<2,>=1.6.3->tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (0.2.8)\n",
            "Requirement already satisfied: cachetools<5.0,>=2.0.0 in /usr/local/lib/python3.6/dist-packages (from google-auth<2,>=1.6.3->tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (4.1.1)\n",
            "Requirement already satisfied: oauthlib>=3.0.0 in /usr/local/lib/python3.6/dist-packages (from requests-oauthlib>=0.7.0->google-auth-oauthlib<0.5,>=0.4.1->tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (3.1.0)\n",
            "Requirement already satisfied: zipp>=0.5 in /usr/local/lib/python3.6/dist-packages (from importlib-metadata; python_version < \"3.8\"->markdown>=2.6.8->tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (3.1.0)\n",
            "Requirement already satisfied: pyasn1>=0.1.3 in /usr/local/lib/python3.6/dist-packages (from rsa<5,>=3.1.4; python_version >= \"3\"->google-auth<2,>=1.6.3->tensorboard<2.3.0,>=2.2.0->tensorflow==2.3.0rc0) (0.4.8)\n",
            "Installing collected packages: tf-estimator-nightly, tensorflow\n",
            "  Found existing installation: tensorflow 2.2.0\n",
            "    Uninstalling tensorflow-2.2.0:\n",
            "      Successfully uninstalled tensorflow-2.2.0\n",
            "Successfully installed tensorflow-2.3.0rc0 tf-estimator-nightly-2.3.0.dev2020062301\n",
            "/content\n"
          ],
          "name": "stdout"
        }
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "Zlgi8fPdpRF0",
        "colab_type": "text"
      },
      "source": [
        "### Define TTS function"
      ]
    },
    {
      "cell_type": "code",
      "metadata": {
        "id": "f-Yc42nQZG5A",
        "colab_type": "code",
        "colab": {}
      },
      "source": [
        "def run_vocoder(mel_spec):\n",
        "  vocoder_inputs = mel_spec[None, :, :]\n",
        "  # get input and output details\n",
        "  input_details = vocoder_model.get_input_details()\n",
        "  # reshape input tensor for the new input shape\n",
        "  vocoder_model.resize_tensor_input(input_details[0]['index'], vocoder_inputs.shape)\n",
        "  vocoder_model.allocate_tensors()\n",
        "  detail = input_details[0]\n",
        "  vocoder_model.set_tensor(detail['index'], vocoder_inputs)\n",
        "  # run the model\n",
        "  vocoder_model.invoke()\n",
        "  # collect outputs\n",
        "  output_details = vocoder_model.get_output_details()\n",
        "  waveform = vocoder_model.get_tensor(output_details[0]['index'])\n",
        "  return waveform \n",
        "\n",
        "\n",
        "def tts(model, text, CONFIG, p):\n",
        "    t_1 = time.time()\n",
        "    waveform, alignment, mel_spec, mel_postnet_spec, stop_tokens, inputs = synthesis(model, text, CONFIG, use_cuda, ap, speaker_id, style_wav=None,\n",
        "                                                                             truncated=False, enable_eos_bos_chars=CONFIG.enable_eos_bos_chars,\n",
        "                                                                             backend='tflite')\n",
        "    waveform = run_vocoder(mel_postnet_spec.T)\n",
        "    waveform = waveform[0, 0]\n",
        "    rtf = (time.time() - t_1) / (len(waveform) / ap.sample_rate)\n",
        "    tps = (time.time() - t_1) / len(waveform)\n",
        "    print(waveform.shape)\n",
        "    print(\" > Run-time: {}\".format(time.time() - t_1))\n",
        "    print(\" > Real-time factor: {}\".format(rtf))\n",
        "    print(\" > Time per step: {}\".format(tps))\n",
        "    IPython.display.display(IPython.display.Audio(waveform, rate=CONFIG.audio['sample_rate']))  \n",
        "    return alignment, mel_postnet_spec, stop_tokens, waveform"
      ],
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "ZksegYQepkFg",
        "colab_type": "text"
      },
      "source": [
        "### Load TF Models"
      ]
    },
    {
      "cell_type": "code",
      "metadata": {
        "id": "oVa0kOamprgj",
        "colab_type": "code",
        "colab": {}
      },
      "source": [
        "import os\n",
        "import torch\n",
        "import time\n",
        "import IPython\n",
        "\n",
        "from TTS.tf.utils.tflite import load_tflite_model\n",
        "from TTS.tf.utils.io import load_checkpoint\n",
        "from TTS.utils.io import load_config\n",
        "from TTS.utils.text.symbols import symbols, phonemes\n",
        "from TTS.utils.audio import AudioProcessor\n",
        "from TTS.tts.utils.synthesis import synthesis"
      ],
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "code",
      "metadata": {
        "id": "EY-sHVO8IFSH",
        "colab_type": "code",
        "colab": {}
      },
      "source": [
        "# runtime settings\n",
        "use_cuda = False"
      ],
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "code",
      "metadata": {
        "id": "_1aIUp2FpxOQ",
        "colab_type": "code",
        "colab": {}
      },
      "source": [
        "# model paths\n",
        "TTS_MODEL = \"tts_model.tflite\"\n",
        "TTS_CONFIG = \"config.json\"\n",
        "VOCODER_MODEL = \"vocoder_model.tflite\"\n",
        "VOCODER_CONFIG = \"config_vocoder.json\""
      ],
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "code",
      "metadata": {
        "id": "CpgmdBVQplbv",
        "colab_type": "code",
        "colab": {}
      },
      "source": [
        "# load configs\n",
        "TTS_CONFIG = load_config(TTS_CONFIG)\n",
        "VOCODER_CONFIG = load_config(VOCODER_CONFIG)"
      ],
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "code",
      "metadata": {
        "id": "zmrQxiozIUVE",
        "colab_type": "code",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 471
        },
        "outputId": "ca7e9016-4c28-4cef-efe7-0613d399aa4c"
      },
      "source": [
        "# load the audio processor\n",
        "ap = AudioProcessor(**TTS_CONFIG.audio)         "
      ],
      "execution_count": null,
      "outputs": [
        {
          "output_type": "stream",
          "text": [
            " > Setting up Audio Processor...\n",
            " | > sample_rate:22050\n",
            " | > num_mels:80\n",
            " | > min_level_db:-100\n",
            " | > frame_shift_ms:None\n",
            " | > frame_length_ms:None\n",
            " | > ref_level_db:0\n",
            " | > fft_size:1024\n",
            " | > power:1.5\n",
            " | > preemphasis:0.0\n",
            " | > griffin_lim_iters:60\n",
            " | > signal_norm:True\n",
            " | > symmetric_norm:True\n",
            " | > mel_fmin:50.0\n",
            " | > mel_fmax:7600.0\n",
            " | > spec_gain:1.0\n",
            " | > stft_pad_mode:reflect\n",
            " | > max_norm:4.0\n",
            " | > clip_norm:True\n",
            " | > do_trim_silence:True\n",
            " | > trim_db:60\n",
            " | > do_sound_norm:False\n",
            " | > stats_path:./scale_stats.npy\n",
            " | > hop_length:256\n",
            " | > win_length:1024\n"
          ],
          "name": "stdout"
        }
      ]
    },
    {
      "cell_type": "code",
      "metadata": {
        "id": "8fLoI4ipqMeS",
        "colab_type": "code",
        "colab": {}
      },
      "source": [
        "# LOAD TTS MODEL\n",
        "# multi speaker \n",
        "speaker_id = None\n",
        "speakers = []\n",
        "\n",
        "# load the models\n",
        "model = load_tflite_model(TTS_MODEL)\n",
        "vocoder_model = load_tflite_model(VOCODER_MODEL)"
      ],
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "Ws_YkPKsLgo-",
        "colab_type": "text"
      },
      "source": [
        "## Run Inference"
      ]
    },
    {
      "cell_type": "code",
      "metadata": {
        "id": "FuWxZ9Ey5Puj",
        "colab_type": "code",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 134
        },
        "outputId": "d1888ebd-3208-42a4-aaf9-78d0e3ec987d"
      },
      "source": [
        "sentence =  \"Bill got in the habit of asking himself “Is that thought true?” and if he wasn’t absolutely certain it was, he just let it go.\"\n",
        "align, spec, stop_tokens, wav = tts(model, sentence, TTS_CONFIG, ap)"
      ],
      "execution_count": null,
      "outputs": [
        {
          "output_type": "stream",
          "text": [
            "(185856,)\n",
            " > Run-time: 3.8069238662719727\n",
            " > Real-time factor: 0.45162849859449977\n",
            " > Time per step: 2.048206938938661e-05\n"
          ],
          "name": "stdout"
        },
        {
          "output_type": "display_data",
          "data": {
            "text/html": [
              "\n",
              "                <audio controls=\"controls\" >\n",
              "                    <source src=\"data:audio/wav;base64,[encoded data, 495676 characters]\" type=\"audio/wav\" />\n",
              "                    Your browser does not support the audio element.\n",
              "                </audio>\n",
              "              "
            ],
            "text/plain": [
              "<IPython.lib.display.Audio object>"
            ]
          },
          "metadata": {
            "tags": []
          }
        }
      ]
    }
  ]
}