Loading...
Hugging Face--有趣的Hugging Face模型HF音频

facebook/unit_hifigan_HK_layer12.km2500_frame_TAT-TTS

unit_hifigan_HK_layer12.km2...

标签:


unit_hifigan_hk_layer12.km2500_frame_TAT-TTS

Hokkien unit HiFiGAN based vocoder from Fairseq:

  • Trained with TAT-TTS data with 4 speakers in Taiwanese Hokkien accent. See here
    for more training details.


Usage

import json
import os
from pathlib import Path
import IPython.display as ipd
from fairseq import hub_utils
from fairseq.checkpoint_utils import load_model_ensemble_and_task_from_hf_hub
from fairseq.models.speech_to_text.hub_interface import S2THubInterface
from fairseq.models.text_to_speech import CodeHiFiGANVocoder
from fairseq.models.text_to_speech.hub_interface import VocoderHubInterface
from huggingface_hub import snapshot_download
import torchaudio
cache_dir = os.getenv("HUGGINGFACE_HUB_CACHE")
# speech synthesis           
library_name = "fairseq"
cache_dir = (
    cache_dir or (Path.home() / ".cache" / library_name).as_posix()
)
cache_dir = snapshot_download(
    f"facebook/unit_hifigan_HK_layer12.km2500_frame_TAT-TTS", cache_dir=cache_dir, library_name=library_name
)
x = hub_utils.from_pretrained(
    cache_dir,
    "model.pt",
    ".",
    archive_map=CodeHiFiGANVocoder.hub_models(),
    config_yaml="config.json",
    fp16=False,
    is_vocoder=True,
)
with open(f"{x['args']['data']}/config.json") as f:
    vocoder_cfg = json.load(f)
assert (
    len(x["args"]["model_path"]) == 1
), "Too many vocoder models in the input"
vocoder = CodeHiFiGANVocoder(x["args"]["model_path"][0], vocoder_cfg)
tts_model = VocoderHubInterface(vocoder_cfg, vocoder)
tts_sample = tts_model.get_model_input(unit)
wav, sr = tts_model.get_prediction(tts_sample)
ipd.Audio(wav, rate=sr)

数据统计

数据评估

facebook/unit_hifigan_HK_layer12.km2500_frame_TAT-TTS浏览人数已经达到860,如你需要查询该站的相关权重信息,可以点击"5118数据""爱站数据""Chinaz数据"进入;以目前的网站数据参考,建议大家请以爱站数据为准,更多网站价值评估因素如:facebook/unit_hifigan_HK_layer12.km2500_frame_TAT-TTS的访问速度、搜索引擎收录以及索引量、用户体验等;当然要评估一个站的价值,最主要还是需要根据您自身的需求以及需要,一些确切的数据则需要找facebook/unit_hifigan_HK_layer12.km2500_frame_TAT-TTS的站长进行洽谈提供。如该站的IP、PV、跳出率等!

关于facebook/unit_hifigan_HK_layer12.km2500_frame_TAT-TTS特别声明

本站Ai导航提供的facebook/unit_hifigan_HK_layer12.km2500_frame_TAT-TTS都来源于网络,不保证外部链接的准确性和完整性,同时,对于该外部链接的指向,不由Ai导航实际控制,在2023年5月15日 下午3:17收录时,该网页上的内容,都属于合规合法,后期网页的内容如出现违规,可以直接联系网站管理员进行删除,Ai导航不承担任何责任。

相关导航

暂无评论

暂无评论...