mirror of https://github.com/coqui-ai/TTS.git
Fix style
This commit is contained in:
parent
8c7af4764d
commit
c42369af5f
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -56,11 +56,11 @@ continue_restore_path, _ = get_last_checkpoint(continue_path)
|
|||
out_wav_path = os.path.join(get_tests_output_path(), "output.wav")
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example.' --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -76,11 +76,11 @@ speaker_id = "ljspeech-1"
|
|||
continue_speakers_path = os.path.join(continue_path, "speakers.json")
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example.' --speaker_idx {speaker_id} --speakers_file_path {continue_speakers_path} --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -75,11 +75,11 @@ continue_restore_path, _ = get_last_checkpoint(continue_path)
|
|||
out_wav_path = os.path.join(get_tests_output_path(), "output.wav")
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example.' --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -63,11 +63,11 @@ speaker_id = "ljspeech-1"
|
|||
continue_speakers_path = config.d_vector_file
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example.' --speaker_idx {speaker_id} --speakers_file_path {continue_speakers_path} --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -60,11 +60,11 @@ speaker_id = "ljspeech-1"
|
|||
continue_speakers_path = os.path.join(continue_path, "speakers.json")
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example.' --speaker_idx {speaker_id} --speakers_file_path {continue_speakers_path} --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -57,11 +57,11 @@ continue_restore_path, _ = get_last_checkpoint(continue_path)
|
|||
out_wav_path = os.path.join(get_tests_output_path(), "output.wav")
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example.' --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -56,11 +56,11 @@ continue_restore_path, _ = get_last_checkpoint(continue_path)
|
|||
out_wav_path = os.path.join(get_tests_output_path(), "output.wav")
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example for it.' --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -63,11 +63,11 @@ speaker_id = "ljspeech-1"
|
|||
continue_speakers_path = config.d_vector_file
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example.' --speaker_idx {speaker_id} --speakers_file_path {continue_speakers_path} --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -61,11 +61,11 @@ speaker_id = "ljspeech-1"
|
|||
continue_speakers_path = os.path.join(continue_path, "speakers.json")
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example.' --speaker_idx {speaker_id} --speakers_file_path {continue_speakers_path} --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -56,11 +56,11 @@ continue_restore_path, _ = get_last_checkpoint(continue_path)
|
|||
out_wav_path = os.path.join(get_tests_output_path(), "output.wav")
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example.' --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -94,11 +94,11 @@ continue_speakers_path = os.path.join(continue_path, "speakers.json")
|
|||
continue_languages_path = os.path.join(continue_path, "language_ids.json")
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example.' --speaker_idx {speaker_id} --speakers_file_path {continue_speakers_path} --language_ids_file_path {continue_languages_path} --language_idx {languae_id} --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -101,11 +101,11 @@ continue_speakers_path = config.d_vector_file
|
|||
continue_languages_path = os.path.join(continue_path, "language_ids.json")
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example.' --speaker_idx {speaker_id} --speakers_file_path {continue_speakers_path} --language_ids_file_path {continue_languages_path} --language_idx {languae_id} --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -67,11 +67,11 @@ speaker_id = "ljspeech-1"
|
|||
continue_speakers_path = os.path.join(continue_path, "speakers.json")
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example.' --speaker_idx {speaker_id} --speakers_file_path {continue_speakers_path} --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import glob
|
||||
import json
|
||||
import os
|
||||
import shutil
|
||||
import json
|
||||
|
||||
from trainer import get_last_checkpoint
|
||||
|
||||
|
@ -56,11 +56,11 @@ continue_restore_path, _ = get_last_checkpoint(continue_path)
|
|||
out_wav_path = os.path.join(get_tests_output_path(), "output.wav")
|
||||
|
||||
# Check integrity of the config
|
||||
with open(continue_config_path, "r") as f:
|
||||
with open(continue_config_path, "r", encoding="utf-8") as f:
|
||||
config_loaded = json.load(f)
|
||||
assert config_loaded['characters'] != None
|
||||
assert config_loaded['output_path'] in continue_path
|
||||
assert config_loaded['test_delay_epochs'] == 0
|
||||
assert config_loaded["characters"] is not None
|
||||
assert config_loaded["output_path"] in continue_path
|
||||
assert config_loaded["test_delay_epochs"] == 0
|
||||
|
||||
# Load the model and run inference
|
||||
inference_command = f"CUDA_VISIBLE_DEVICES='{get_device_id()}' tts --text 'This is an example.' --config_path {continue_config_path} --model_path {continue_restore_path} --out_path {out_wav_path}"
|
||||
|
|
Loading…
Reference in New Issue