how to use this model by transformers.js
#1
by
tianzhaotong
- opened
can u give a example code?
import { pipeline } from '@xenova/transformers';
import { pinyin } from 'pinyin-pro'; // Our use-case, using `pinyin-pro`
const synthesizer = await pipeline('text-to-audio', 'BricksDisplay/vits-cmn', { quantized: false })
console.log(await synthesizer(pinyin('ζε')))
// {
// audio: Float32Array(?) [ ... ],
// sampling_rate: 16000
// }
Note: Transformers.js (ONNX) version does not support speaker_id, so it will fixed in 0
hans00
changed discussion status to
closed