Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
|
@@ -2,28 +2,33 @@
|
|
| 2 |
|
| 3 |
This repository hosts the Vui 100M base checkpoint and Fluac tokenizer used by the `fluxions/vui` project.
|
| 4 |
|
| 5 |
-
|
| 6 |
-
- `vui-100m-base.pt`: Vui TTS checkpoint.
|
| 7 |
-
- `fluac-22hz-22khz.pt`: Fluac
|
| 8 |
- `LICENSE`: MIT license from the upstream project.
|
| 9 |
|
| 10 |
-
## Quick usage (
|
| 11 |
```python
|
| 12 |
import torch
|
|
|
|
|
|
|
| 13 |
from vui.model import Vui
|
| 14 |
|
| 15 |
-
# Download
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
|
|
|
|
|
|
| 19 |
|
| 20 |
text = "Hello! This is Vui speaking from Hugging Face."
|
| 21 |
with torch.inference_mode():
|
| 22 |
-
audio =
|
|
|
|
| 23 |
```
|
| 24 |
|
| 25 |
## Notes
|
| 26 |
- This is a TTS model with a custom architecture; it is **not** a standard CausalLM.
|
| 27 |
-
- `vllm serve`
|
| 28 |
- Upstream code: https://github.com/fluxions-ai/vui
|
| 29 |
```
|
|
|
|
| 2 |
|
| 3 |
This repository hosts the Vui 100M base checkpoint and Fluac tokenizer used by the `fluxions/vui` project.
|
| 4 |
|
| 5 |
+
Contents:
|
| 6 |
+
- `vui-100m-base.pt`: Vui TTS checkpoint (100M parameters).
|
| 7 |
+
- `fluac-22hz-22khz.pt`: Fluac codec checkpoint.
|
| 8 |
- `LICENSE`: MIT license from the upstream project.
|
| 9 |
|
| 10 |
+
## Quick usage (Python)
|
| 11 |
```python
|
| 12 |
import torch
|
| 13 |
+
from huggingface_hub import hf_hub_download
|
| 14 |
+
from vui.inference import render
|
| 15 |
from vui.model import Vui
|
| 16 |
|
| 17 |
+
# Download checkpoints from this repo (returns local file paths)
|
| 18 |
+
ckpt = hf_hub_download("Endy2001/vui-tts", "vui-100m-base.pt")
|
| 19 |
+
codec_ckpt = hf_hub_download("Endy2001/vui-tts", "fluac-22hz-22khz.pt")
|
| 20 |
+
|
| 21 |
+
# Load model (pass codec checkpoint so it doesn't fetch from upstream)
|
| 22 |
+
model = Vui.from_pretrained_inf(ckpt, codec_checkpoint=codec_ckpt).to("cuda")
|
| 23 |
|
| 24 |
text = "Hello! This is Vui speaking from Hugging Face."
|
| 25 |
with torch.inference_mode():
|
| 26 |
+
audio = render(model, text)[0].cpu().numpy()
|
| 27 |
+
# `audio` is a mono waveform at 24 kHz
|
| 28 |
```
|
| 29 |
|
| 30 |
## Notes
|
| 31 |
- This is a TTS model with a custom architecture; it is **not** a standard CausalLM.
|
| 32 |
+
- `vllm serve` only supports text-generation transformer architectures, so this checkpoint cannot be served directly via `vllm serve Endy2001/vui-tts`. Use the Python API above or the scripts in the upstream repo instead.
|
| 33 |
- Upstream code: https://github.com/fluxions-ai/vui
|
| 34 |
```
|