erenfazlioglu/turkishvoicedataset
Viewer • Updated • 131k • 299 • 44
How to use umarigan/speecht5_tts_tr_v1.0 with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-to-speech", model="umarigan/speecht5_tts_tr_v1.0", device_map="auto") # Load model directly
from transformers import AutoProcessor, AutoModelForTextToSpectrogram
processor = AutoProcessor.from_pretrained("umarigan/speecht5_tts_tr_v1.0")
model = AutoModelForTextToSpectrogram.from_pretrained("umarigan/speecht5_tts_tr_v1.0", device_map="auto")This model is a fine-tuned version of microsoft/speecht5_tts on the turkishvoicedataset dataset. It achieves the following results on the evaluation set:
More information needed
More information needed
More information needed
The following hyperparameters were used during training:
| Training Loss | Epoch | Step | Validation Loss |
|---|---|---|---|
| 0.4436 | 1.8484 | 1000 | 0.3752 |
| 0.3822 | 3.6969 | 2000 | 0.3403 |
| 0.3729 | 5.5453 | 3000 | 0.3233 |
| 0.3451 | 7.3937 | 4000 | 0.3153 |
| 0.3315 | 9.2421 | 5000 | 0.3099 |
| 0.3492 | 11.0906 | 6000 | 0.3079 |
installs
!pip install datasets soundfile speechbrain
inference
from transformers import pipeline
from datasets import load_dataset
import soundfile as sf
import torch
from IPython.display import Audio
synthesiser = pipeline("text-to-speech", "umarigan/speecht5_tts_tr_v1.0")
embeddings_dataset = load_dataset("umarigan/turkish_voice_dataset_embedded", split="train")
speaker_embedding = torch.tensor(embeddings_dataset[736]["speaker_embeddings"]).unsqueeze(0)
# Synthesize speech using the embedding
speech = synthesiser("Bir berber bir berbere gel beraber bir berber kuralım demiş", forward_params={"speaker_embeddings": speaker_embedding})
# Save the generated audio to a file
sf.write("speech.wav", speech["audio"], samplerate=speech["sampling_rate"])
# Play the audio in the notebook
Audio("speech.wav")
Base model
microsoft/speecht5_tts