Spaces:
Runtime error
Runtime error
Ahsen Khaliq
commited on
Commit
·
1b12cc3
1
Parent(s):
2bb5870
Update demo_cli.py
Browse files- demo_cli.py +7 -7
demo_cli.py
CHANGED
@@ -28,13 +28,13 @@ if __name__ == '__main__':
|
|
28 |
parser.add_argument("-v", "--voc_model_fpath", type=Path,
|
29 |
default="vocpretrained.pt",
|
30 |
help="Path to a saved vocoder")
|
31 |
-
parser.add_argument("--cpu", action="store_true", help
|
32 |
-
parser.add_argument("--no_sound", action="store_true", help
|
33 |
-
parser.add_argument("--seed", type=int, default=None, help
|
34 |
-
parser.add_argument("--no_mp3_support", action="store_true", help
|
35 |
parser.add_argument("-audio", "--audio_path", type=Path, required = True,
|
36 |
help="Path to a audio file")
|
37 |
-
parser.add_argument("--text", type=str, required = True, help
|
38 |
args = parser.parse_args()
|
39 |
print_args(args, parser)
|
40 |
if not args.no_sound:
|
@@ -134,7 +134,7 @@ if __name__ == '__main__':
|
|
134 |
# while True:
|
135 |
try:
|
136 |
# Get the reference audio filepath
|
137 |
-
message = "Reference voice: enter an audio filepath of a voice to be cloned (mp3, "
|
138 |
in_fpath = args.audio_path
|
139 |
|
140 |
if in_fpath.suffix.lower() == ".mp3" and args.no_mp3_support:
|
@@ -217,4 +217,4 @@ if __name__ == '__main__':
|
|
217 |
|
218 |
except Exception as e:
|
219 |
print("Caught exception: %s" % repr(e))
|
220 |
-
print("Restarting\n")
|
|
|
28 |
parser.add_argument("-v", "--voc_model_fpath", type=Path,
|
29 |
default="vocpretrained.pt",
|
30 |
help="Path to a saved vocoder")
|
31 |
+
parser.add_argument("--cpu", action="store_true", help="If True, processing is done on CPU, even when a GPU is available.")
|
32 |
+
parser.add_argument("--no_sound", action="store_true", help="If True, audio won't be played.")
|
33 |
+
parser.add_argument("--seed", type=int, default=None, help="Optional random number seed value to make toolbox deterministic.")
|
34 |
+
parser.add_argument("--no_mp3_support", action="store_true", help="If True, disallows loading mp3 files to prevent audioread errors when ffmpeg is not installed.")
|
35 |
parser.add_argument("-audio", "--audio_path", type=Path, required = True,
|
36 |
help="Path to a audio file")
|
37 |
+
parser.add_argument("--text", type=str, required = True, help="Text Input")
|
38 |
args = parser.parse_args()
|
39 |
print_args(args, parser)
|
40 |
if not args.no_sound:
|
|
|
134 |
# while True:
|
135 |
try:
|
136 |
# Get the reference audio filepath
|
137 |
+
message = "Reference voice: enter an audio filepath of a voice to be cloned (mp3, " "wav, m4a, flac, ...):\n"
|
138 |
in_fpath = args.audio_path
|
139 |
|
140 |
if in_fpath.suffix.lower() == ".mp3" and args.no_mp3_support:
|
|
|
217 |
|
218 |
except Exception as e:
|
219 |
print("Caught exception: %s" % repr(e))
|
220 |
+
print("Restarting\n")
|