Instructions to use khmerttsopensource/khmer-tts with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use khmerttsopensource/khmer-tts with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-to-audio", model="khmerttsopensource/khmer-tts")# Load model directly from transformers import AutoTokenizer, AutoModelForPreTraining tokenizer = AutoTokenizer.from_pretrained("khmerttsopensource/khmer-tts") model = AutoModelForPreTraining.from_pretrained("khmerttsopensource/khmer-tts") - Notebooks
- Google Colab
- Kaggle
File size: 598 Bytes
c9380a9 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | # Upload To Hugging Face
Install and authenticate the Hugging Face CLI:
```bash
curl -LsSf https://hf.co/cli/install.sh | bash -s
hf auth login
```
Upload this folder as a model repository:
```bash
cd huggingface/khmer-tts
hf upload khmerttsopensource/khmer-tts . .
```
For a private first upload:
```bash
hf upload khmerttsopensource/khmer-tts . . --private
```
After upload, test loading from the Hub:
```bash
python examples/inference.py \
--model khmerttsopensource/khmer-tts \
--text "សួស្តីអ្នកទាំងអស់គ្នា" \
--output khmer_tts.wav
```
|