Instructions to use microsoft/speecht5_tts with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use microsoft/speecht5_tts with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-to-speech", model="microsoft/speecht5_tts")# Load model directly from transformers import AutoProcessor, AutoModelForTextToSpectrogram processor = AutoProcessor.from_pretrained("microsoft/speecht5_tts") model = AutoModelForTextToSpectrogram.from_pretrained("microsoft/speecht5_tts") - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -71,7 +71,7 @@ embeddings_dataset = load_dataset("Matthijs/cmu-arctic-xvectors", split="validat
|
|
| 71 |
speaker_embedding = torch.tensor(embeddings_dataset[7306]["xvector"]).unsqueeze(0)
|
| 72 |
# You can replace this embedding with your own as well.
|
| 73 |
|
| 74 |
-
speech =
|
| 75 |
|
| 76 |
sf.write("speech.wav", speech["audio"], samplerate=speech["sampling_rate"])
|
| 77 |
```
|
|
|
|
| 71 |
speaker_embedding = torch.tensor(embeddings_dataset[7306]["xvector"]).unsqueeze(0)
|
| 72 |
# You can replace this embedding with your own as well.
|
| 73 |
|
| 74 |
+
speech = synthesiser("Hello, my dog is cooler than you!", forward_params={"speaker_embeddings": speaker_embedding})
|
| 75 |
|
| 76 |
sf.write("speech.wav", speech["audio"], samplerate=speech["sampling_rate"])
|
| 77 |
```
|