Forgot I need to use the DAC's 44K model because 24K model has 32 codebooks instead of 9.

This commit is contained in:
mrq 2024-04-17 20:59:25 -05:00
parent 5ff2b4aab5
commit 2e9e6e68f7
2 changed files with 3 additions and 0 deletions

BIN
data/qnt.dac.pt Normal file

Binary file not shown.

View File

@ -146,6 +146,8 @@ def _load_vocos_model(device="cuda", levels=cfg.model.max_levels):
def _load_dac_model(device="cuda", levels=cfg.model.max_levels):
kwargs = dict(model_type="44khz",model_bitrate="8kbps",tag="latest")
# just use the 44K model, the 24K model has 32 codebooks...
"""
# yes there's a better way, something like f'{cfg.sample.rate//1000}hz'
if cfg.sample_rate == 44_000:
kwargs["model_type"] = "44kz"
@ -155,6 +157,7 @@ def _load_dac_model(device="cuda", levels=cfg.model.max_levels):
kwargs["model_type"] = "16khz"
else:
raise Exception(f'unsupported sample rate: {cfg.sample_rate}')
"""
model = __load_dac_model(**kwargs)
model = model.to(device)