ModelScope中!pip install scipy
!pip install kantts
from modelscope.outputs import OutputKeys
from modelscope.pipelines import pipeline
from modelscope.utils.constant import Tasks
text = '待合成文本'
model_id = 'damo/speech_sambert-hifigan_tts_zhitian_emo_zh-cn_16k'
sambert_hifigan_tts = pipeline(task=Tasks.text_to_speech, model=model_id)
output = sambert_hifigan_tts(input=text)
wav = output[OutputKeys.OUTPUT_WAV]
with open('output.wav', 'wb') as f:
f.write(wav)
报错:
ERROR: Could not find a version that satisfies the requirement kantts (from versions: none) ERROR: No matching distribution found for kantts提示找不到Kantts库,安装不上,请教这个问题怎么解决?