Magpie TTS - Saudi Arabic (Fine-Tuned)

This model is a fine-tuned version of the NVIDIA Magpie TTS Multilingual (357M) model, specifically adapted for Saudi Arabic text-to-speech generation.

Audio Comparison: Base vs. Fine-Tuned

Below are raw, unedited audio samples demonstrating the dialect adaptation.

Text Prompt Base Model
magpie_tts_multilingual_357m
Fine-Tuned Model
ุชุฑู‰ ุงู„ุทุฑูŠู‚ ุฌู‡ุฉ ุงู„ุฑูŠุงุถ ุงู„ูŠูˆู… ู…ุฑุฉ ุฒุญู…ุฉุŒ ูุฅุฐุง ู…ุณุชุนุฌู„ูŠู† ุฃุญุณู† ู†ุทู„ุน ู…ู† ุงู„ุญูŠู† ุนุดุงู† ู†ูˆุตู„ ู‚ุจู„ ุงู„ู…ูˆุนุฏ ูˆู…ุง ู†ุชุฃุฎุฑ.
ุญูŠุงูƒู… ุงู„ู„ู‡ ููŠ ุฃูŠ ูˆู‚ุชุŒ ูˆุฅุฐุง ูˆุตู„ุชูˆุง ุนู„ู…ูˆู†ูŠุŒ ูˆุจุฌู‡ุฒ ู„ูƒู… ุงู„ู‚ู‡ูˆุฉ ูˆุงู„ุญู„ุง ูˆู†ุฌู„ุณ ูƒู„ู†ุง ู…ุน ุจุนุถ ูˆู†ุณูˆู„ู ู„ูŠู† ูˆู‚ุช ู…ุชุฃุฎุฑ.
ู…ู† ูƒุซุฑ ู…ุง ูŠุชุบูŠุฑ ุงู„ุฌูˆ ู‡ุงู„ุฃูŠุงู…ุŒ ุงู„ูˆุงุญุฏ ู…ุง ูŠุฏุฑูŠ ูˆุด ูŠู„ุจุณุŒ ุงู„ุตุจุญ ูŠูƒูˆู† ุงู„ุฌูˆ ุจุงุฑุฏ ุดูˆูŠ ูˆุงู„ุนุตุฑ ูŠุฑุฌุน ุงู„ุญุฑ ู…ุฑุฉ ุซุงู†ูŠุฉ.
ุฃู†ุง ุฃุดูˆู ู†ุฎู„ูŠ ุงู„ู…ุดูˆุงุฑ ุจุนุฏ ุงู„ู…ุบุฑุจุŒ ู„ุฃู† ุงู„ุฌูˆ ุจูŠูƒูˆู† ุฃุญุณู† ูˆุงู„ู†ุงุณ ุชุฎู ู…ู† ุงู„ุดูˆุงุฑุนุŒ ูˆู†ู‚ุฏุฑ ู†ุงุฎุฐ ุฑุงุญุชู†ุง ููŠ ุงู„ุทู„ุนุฉ.

Model Details

  • Architecture: Magpie TTS (Encoder-Decoder Transformer with Audio Codec)
  • Base Model: nvidia/magpie_tts_multilingual_357m
  • Language: Arabic (Saudi Arabia) ar-SA
  • Framework: NVIDIA NeMo (v2.8.0rc0)
  • Codec: nvidia/nemo-nano-codec-22khz-1.89kbps-21.5fps

Training Dataset

The model was fine-tuned using the AhmedEladl/saudi-voice-dataset dataset.

  • Audio Processing: Resampled to 22,050 Hz to match the NanoCodec requirements.
  • Filtering: Utterances under 0.5 seconds were removed to ensure training stability.
  • Context Selection: Randomized context reference audio from within the dataset to provide target voice conditioning.

Training Configuration

  • Hardware: NVIDIA L4 / T4 GPU
  • Epochs: 10
  • Batch Size: 2 (with gradient accumulation steps = 2)
  • Learning Rate: 5e-6 (AdamW)
  • Precision: 32-bit float
  • Context Duration: 2.0s to 12.0s

๐Ÿ“ฆ Dependencies & Installation

To run inference with this model, ensure you have the correct versions of the NeMo toolkit and audio handling libraries installed.

pip install torch>=2.1.0
pip install soundfile>=0.12.1
pip install librosa>=0.10.1
pip install huggingface_hub>=0.23.0
pip install nemo_toolkit[all]==2.8.0rc0

Inference Code Example

import soundfile as sf
from huggingface_hub import hf_hub_download
from nemo.collections.tts.modules.magpietts_inference.utils import ModelLoadConfig, load_magpie_model

# 1. Download Model & Codec from Hugging Face Hub
print("Downloading models...")
model_path = hf_hub_download(repo_id="AhmedEladl/Magpie-TTS-Saudi-Arabic", filename="Magpie-TTS-Saudi-Female.nemo")
codec_path = hf_hub_download(repo_id="nvidia/nemo-nano-codec-22khz-1.89kbps-21.5fps", filename="nemo-nano-codec-22khz-1.89kbps-21.5fps.nemo")

# 2. Load the fine-tuned model and codec
config = ModelLoadConfig(nemo_file=model_path, codecmodel_path=codec_path)
model, _ = load_magpie_model(config)
model.eval().cuda()

# 3. Generate Audio
prompt = "ุงู„ุฐูƒุงุก ุงู„ุงุตุทู†ุงุนูŠ ุตุงุฑ ุฌุฒุก ุฃุณุงุณูŠ ู…ู† ุญูŠุงุชู†ุง ุงู„ูŠูˆู…ูŠุฉุŒ ูˆุชุทูˆูŠุฑ ู†ู…ุงุฐุฌ ุชุฏุนู… ู„ู‡ุฌุชู†ุง ุฎุทูˆุฉ ุฌุฏุงู‹ ู…ู‡ู…ุฉ."
print("Generating audio...")
res = model.do_tts(transcript=prompt, language="ar-SA", apply_TN=False)

# 4. Save the output
audio = res[0].cpu().numpy()
if len(audio.shape) == 2:
    audio = audio[0]
    
sf.write("output.wav", audio, 22050)
print("โœ… Audio saved successfully to output.wav")

๐Ÿ“œ Citation

If you use this model in your research or projects, please cite it as follows:

@misc{magpie_tts_sa-ar_arabic,
  author       = {Ahmed Eladl},
  title        = {Magpie TTS - Saudi Arabic (Fine-Tuned)},
  year         = {2026},
  publisher    = {Hugging Face},
  url          = {https://huggingface.co/AhmedEladl/Magpie-TTS-Saudi-Arabic}
}

๐Ÿ“ง Contact

For any questions, issues, or inquiries regarding this model, please reach out:

Downloads last month
168
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for AhmedEladl/Magpie-TTS-Saudi-Arabic

Finetuned
(11)
this model

Dataset used to train AhmedEladl/Magpie-TTS-Saudi-Arabic

Space using AhmedEladl/Magpie-TTS-Saudi-Arabic 1