mirror of
https://github.com/storytold/storyteller-ml.git
synced 2026-10-29 09:18:21 +00:00
inference-job to send null or sentinel values for unused vocoders
This commit is contained in:
@@ -234,6 +234,9 @@ class FakeYouTt2Pipeline:
|
|||||||
self.hifigan_super_resolution_filename = None
|
self.hifigan_super_resolution_filename = None
|
||||||
|
|
||||||
def maybe_load_hifigan(self, checkpoint_path):
|
def maybe_load_hifigan(self, checkpoint_path):
|
||||||
|
if not checkpoint_path or checkpoint_path == 'BOGUS_NOT_USED':
|
||||||
|
# Requests no longer have to specify a hifigan to use (if using waveglow)
|
||||||
|
return
|
||||||
if self.hifigan_filename == checkpoint_path:
|
if self.hifigan_filename == checkpoint_path:
|
||||||
LOGGER.info('Hifi-gan model already loaded into memory: {}'.format(checkpoint_path))
|
LOGGER.info('Hifi-gan model already loaded into memory: {}'.format(checkpoint_path))
|
||||||
return
|
return
|
||||||
@@ -246,6 +249,9 @@ class FakeYouTt2Pipeline:
|
|||||||
self.hifigan_filename = checkpoint_path
|
self.hifigan_filename = checkpoint_path
|
||||||
|
|
||||||
def maybe_load_hifigan_super_resolution(self, checkpoint_path):
|
def maybe_load_hifigan_super_resolution(self, checkpoint_path):
|
||||||
|
if not checkpoint_path or checkpoint_path == 'BOGUS_NOT_USED':
|
||||||
|
# Requests no longer have to specify a hifigan to use (if using waveglow)
|
||||||
|
return
|
||||||
if self.hifigan_super_resolution_filename == checkpoint_path:
|
if self.hifigan_super_resolution_filename == checkpoint_path:
|
||||||
LOGGER.info('Hifi-gan (SuperRes) model already loaded into memory: {}'.format(checkpoint_path))
|
LOGGER.info('Hifi-gan (SuperRes) model already loaded into memory: {}'.format(checkpoint_path))
|
||||||
return
|
return
|
||||||
@@ -258,6 +264,9 @@ class FakeYouTt2Pipeline:
|
|||||||
self.hifigan_super_resolution_filename = checkpoint_path
|
self.hifigan_super_resolution_filename = checkpoint_path
|
||||||
|
|
||||||
def maybe_load_waveglow_model(self, checkpoint_path):
|
def maybe_load_waveglow_model(self, checkpoint_path):
|
||||||
|
if not checkpoint_path or checkpoint_path == 'BOGUS_NOT_USED':
|
||||||
|
# Requests no longer have to specify a waveglow to use (if using hifigan)
|
||||||
|
return
|
||||||
if self.waveglow_filename == checkpoint_path:
|
if self.waveglow_filename == checkpoint_path:
|
||||||
LOGGER.info('Waveglow model already loaded into memory: {}'.format(checkpoint_path))
|
LOGGER.info('Waveglow model already loaded into memory: {}'.format(checkpoint_path))
|
||||||
return
|
return
|
||||||
|
|||||||
Reference in New Issue
Block a user