Print statement on this line appears to be redundant and might not be necessary. overall, everything looks great.
Print statement on this line appears to be redundant and might not be necessary. overall, everything looks great.
try:
ifargs.use_hifigan:
gen=tts.tts(cut_text,**settings)
else:
gen,additionals=tts.tts(cut_text,**settings)
parameters['seed']=additionals[0]
exceptExceptionase:
raiseRuntimeError(f'Possible latent mismatch: click the "(Re)Compute Voice Latents" button and then try again. Error: {e}')
run_time=time.time()-start_time
print(f"Generating line took {run_time} seconds")
@ -3293,6 +3307,7 @@ def setup_args(cli=False):
'latents-lean-and-mean':True,
'voice-fixer':False,# getting tired of long initialization times in a Colab for downloading a large dataset for it
'use-deepspeed':False,
'use-hifigan':False,
'voice-fixer-use-cuda':True,
@ -3352,6 +3367,8 @@ def setup_args(cli=False):
parser.add_argument("--voice-fixer",action='store_true',default=default_arguments['voice-fixer'],help="Uses python module 'voicefixer' to improve audio quality, if available.")
parser.add_argument("--voice-fixer-use-cuda",action='store_true',default=default_arguments['voice-fixer-use-cuda'],help="Hints to voicefixer to use CUDA, if available.")
parser.add_argument("--use-deepspeed",action='store_true',default=default_arguments['use-deepspeed'],help="Use deepspeed for speed bump.")
parser.add_argument("--use-hifigan",action='store_true',default=default_arguments['use-hifigan'],help="Use Hifigan instead of Diffusion")
parser.add_argument("--force-cpu-for-conditioning-latents",default=default_arguments['force-cpu-for-conditioning-latents'],action='store_true',help="Forces computing conditional latents to be done on the CPU (if you constantyl OOM on low chunk counts)")
parser.add_argument("--prune-nonfinal-outputs",default=default_arguments['prune-nonfinal-outputs'],action='store_true',help="Deletes non-final output files on completing a generation")
EXEC_SETTINGS['voice_fixer']=gr.Checkbox(label="Use Voice Fixer on Generated Output",value=args.voice_fixer)
EXEC_SETTINGS['use_deepspeed']=gr.Checkbox(label="Use DeepSpeed for Speed Bump.",value=args.use_deepspeed)
EXEC_SETTINGS['use_hifigan']=gr.Checkbox(label="Use Hifigan instead of Diffusion.",value=args.use_hifigan)
EXEC_SETTINGS['voice_fixer_use_cuda']=gr.Checkbox(label="Use CUDA for Voice Fixer",value=args.voice_fixer_use_cuda)
EXEC_SETTINGS['force_cpu_for_conditioning_latents']=gr.Checkbox(label="Force CPU for Conditioning Latents",value=args.force_cpu_for_conditioning_latents)
EXEC_SETTINGS['defer_tts_load']=gr.Checkbox(label="Do Not Load TTS On Startup",value=args.defer_tts_load)
Print statement on this line appears to be redundant and might not be necessary. overall, everything looks great.