diff --git a/TTS/bin/compute_attention_masks.py b/TTS/bin/compute_attention_masks.py index 3cbf40ba1e..eb70804098 100644 --- a/TTS/bin/compute_attention_masks.py +++ b/TTS/bin/compute_attention_masks.py @@ -80,7 +80,7 @@ model.eval() # data loader - preprocessor = importlib.import_module("TTS.tts.datasets.preprocess") + preprocessor = importlib.import_module("TTS.tts.datasets.formatters") preprocessor = getattr(preprocessor, args.dataset) meta_data = preprocessor(args.data_path, args.dataset_metafile) dataset = TTSDataset( diff --git a/TTS/bin/find_unique_chars.py b/TTS/bin/find_unique_chars.py index 7891d65a91..75169569cc 100644 --- a/TTS/bin/find_unique_chars.py +++ b/TTS/bin/find_unique_chars.py @@ -3,14 +3,14 @@ import os from argparse import RawTextHelpFormatter -from TTS.tts.datasets.preprocess import get_preprocessor_by_name +from TTS.tts.datasets.formatters import get_preprocessor_by_name def main(): # pylint: disable=bad-option-value parser = argparse.ArgumentParser( description="""Find all the unique characters or phonemes in a dataset.\n\n""" - """Target dataset must be defined in TTS.tts.datasets.preprocess\n\n""" + """Target dataset must be defined in TTS.tts.datasets.formatters\n\n""" """ Example runs: @@ -20,7 +20,7 @@ def main(): ) parser.add_argument( - "--dataset", type=str, default="", help="One of the target dataset names in TTS.tts.datasets.preprocess." + "--dataset", type=str, default="", help="One of the target dataset names in TTS.tts.datasets.formatters." ) parser.add_argument("--meta_file", type=str, default=None, help="Path to the transcriptions file of the dataset.") diff --git a/notebooks/dataset_analysis/AnalyzeDataset.ipynb b/notebooks/dataset_analysis/AnalyzeDataset.ipynb index 8aa3a02558..6ff2d2caae 100644 --- a/notebooks/dataset_analysis/AnalyzeDataset.ipynb +++ b/notebooks/dataset_analysis/AnalyzeDataset.ipynb @@ -31,7 +31,7 @@ "from multiprocessing import Pool\n", "from matplotlib import pylab as plt\n", "from collections import Counter\n", - "from TTS.tts.datasets.preprocess import *\n", + "from TTS.tts.datasets.formatters import *\n", "%matplotlib inline" ] }, diff --git a/notebooks/dataset_analysis/PhonemeCoverage.ipynb b/notebooks/dataset_analysis/PhonemeCoverage.ipynb index f9540d0692..e659511aa4 100644 --- a/notebooks/dataset_analysis/PhonemeCoverage.ipynb +++ b/notebooks/dataset_analysis/PhonemeCoverage.ipynb @@ -50,7 +50,7 @@ "source": [ "# import stuff\n", "from TTS.utils.io import load_config\n", - "from TTS.tts.datasets.preprocess import load_meta_data\n", + "from TTS.tts.datasets.formatters import load_meta_data\n", "from TTS.tts.utils.text import phoneme_to_sequence, sequence_to_phoneme\n", "from tqdm import tqdm\n", "from matplotlib import pylab as plt\n", diff --git a/tests/data_tests/test_dataset_formatters.py b/tests/data_tests/test_dataset_formatters.py index 968e2a29fa..bd83002cea 100644 --- a/tests/data_tests/test_dataset_formatters.py +++ b/tests/data_tests/test_dataset_formatters.py @@ -2,7 +2,7 @@ import unittest from tests import get_tests_input_path -from TTS.tts.datasets.preprocess import common_voice +from TTS.tts.datasets.formatters import common_voice class TestPreprocessors(unittest.TestCase): diff --git a/tests/data_tests/test_loader.py b/tests/data_tests/test_loader.py index 053da51642..7f55b3783b 100644 --- a/tests/data_tests/test_loader.py +++ b/tests/data_tests/test_loader.py @@ -9,7 +9,7 @@ from tests import get_tests_output_path from TTS.tts.configs import BaseTTSConfig from TTS.tts.datasets import TTSDataset -from TTS.tts.datasets.preprocess import ljspeech +from TTS.tts.datasets.formatters import ljspeech from TTS.utils.audio import AudioProcessor # pylint: disable=unused-variable