Spaces:
Running
Running
Upload app.py with huggingface_hub
Browse files24 unmodified lines25262728293031323334353633 unmodified lines707172737424 unmodified linesreturn f"Error: {e}"# Create Gradio interfacewith gr.Blocks(title="TinyTTS Demo", theme=gr.themes.Soft()) as app:gr.Markdown("# 🗣️ TinyTTS")gr.Markdown("**Ultra-lightweight English Text-to-Speech — only 1.6M parameters, ~3.4 MB ONNX**\n\n""Synthesizes high-quality 44.1kHz audio **~53× faster** than real-time on CPU.")with gr.Row():33 unmodified linesoutputs=audio_output)if __name__ == "__main__":app.launch(server_name="0.0.0.0")24 unmodified lines252627282930313233343536373839404142434445464748495051525354555633 unmodified lines909192939495969724 unmodified linesreturn f"Error: {e}"COMPARISON_TABLE = """## ⚡ Comparison with Other TTS EnginesAll numbers are **CPU-only** on the same Intel Core laptop. Text: *"The weather is nice today, and I feel very relaxed."*| ENGINE | Params | Total (s) | Audio (s) | RTFx ||:---|---:|---:|---:|---:|| **TinyTTS (ONNX) 🚀** | **1.6M** | **0.092** | **4.88** | **~53x** || Piper (ONNX, 22kHz) | ~63M | 0.112 | 2.91 | ~26x || TinyTTS (PyTorch) | 1.6M | 0.272 | 4.88 | ~18x || KittenTTS nano | ~10M | 0.286 | 4.87 | ~17x || Supertonic (2-step) | ~82M | 0.249 | 3.69 | ~15x || Pocket-TTS | 100M | 0.928 | 3.68 | ~4x || Kokoro ONNX | 82M | 0.933 | 3.16 | ~3x || KittenTTS mini | ~25M | 2.047 | 4.17 | ~2x |> **RTFx** = Audio Duration ÷ Synthesis Time (higher = faster).> TinyTTS achieves the **best speed-to-size ratio**: only **1.6M params** / **3.4 MB** ONNX yet ~53× real-time at 44.1kHz."""# Create Gradio interfacewith gr.Blocks(title="TinyTTS Demo", theme=gr.themes.Soft()) as app:gr.Markdown("# 🗣️ TinyTTS")gr.Markdown("**Ultra-lightweight English Text-to-Speech — only 1.6M parameters, ~3.4 MB ONNX**\n\n""This space runs on CPU efficiently and synthesizes high-quality 44.1kHz audio **~53× faster** than real-time.")with gr.Row():33 unmodified linesoutputs=audio_output)# Comparison tablegr.Markdown(COMPARISON_TABLE)if __name__ == "__main__":app.launch(server_name="0.0.0.0")
app.py+24-1