MarkDaniel212 commited on
Commit
9ef4867
·
verified ·
1 Parent(s): 2c4c098

Perf: upgrade gradio 5.46->5.50, tune queue/launch flags

Browse files
Files changed (2) hide show
  1. app.py +8 -2
  2. requirements.txt +1 -1
app.py CHANGED
@@ -84,7 +84,11 @@ class MiMoV25ASRInterface:
84
  return "", error_msg
85
 
86
  def create_interface(self):
87
- with gr.Blocks(title="MiMo-V2.5-ASR Speech Recognition", theme=gr.themes.Soft()) as iface:
 
 
 
 
88
  gr.Markdown("# 🎙️ MiMo-V2.5-ASR: Robust Speech Recognition")
89
  gr.Markdown(
90
  "Upload an audio file **or** record directly from your microphone. "
@@ -171,9 +175,11 @@ def main():
171
  host = os.environ.get("GRADIO_SERVER_NAME", "0.0.0.0")
172
  port = int(os.environ.get("GRADIO_SERVER_PORT", "7898"))
173
  print(f"🌐 Launch service - {host}:{port}")
174
- iface.queue().launch(
175
  server_name=host,
176
  server_port=port,
 
 
177
  )
178
 
179
 
 
84
  return "", error_msg
85
 
86
  def create_interface(self):
87
+ with gr.Blocks(
88
+ title="MiMo-V2.5-ASR Speech Recognition",
89
+ theme=gr.themes.Soft(),
90
+ fill_height=True,
91
+ ) as iface:
92
  gr.Markdown("# 🎙️ MiMo-V2.5-ASR: Robust Speech Recognition")
93
  gr.Markdown(
94
  "Upload an audio file **or** record directly from your microphone. "
 
175
  host = os.environ.get("GRADIO_SERVER_NAME", "0.0.0.0")
176
  port = int(os.environ.get("GRADIO_SERVER_PORT", "7898"))
177
  print(f"🌐 Launch service - {host}:{port}")
178
+ iface.queue(default_concurrency_limit=4, max_size=20).launch(
179
  server_name=host,
180
  server_port=port,
181
+ show_api=False,
182
+ analytics_enabled=False,
183
  )
184
 
185
 
requirements.txt CHANGED
@@ -6,6 +6,6 @@ torchaudio @ https://download.pytorch.org/whl/cu126/torchaudio-2.6.0%2Bcu126-cp3
6
  flash-attn @ https://github.com/Dao-AILab/flash-attention/releases/download/v2.8.2/flash_attn-2.8.2%2Bcu12torch2.6cxx11abiTRUE-cp312-cp312-linux_x86_64.whl
7
  transformers==4.49.0
8
  triton==3.2.0
9
- gradio==5.46.1
10
  zhon==2.1.1
11
  huggingface_hub>=0.26.0
 
6
  flash-attn @ https://github.com/Dao-AILab/flash-attention/releases/download/v2.8.2/flash_attn-2.8.2%2Bcu12torch2.6cxx11abiTRUE-cp312-cp312-linux_x86_64.whl
7
  transformers==4.49.0
8
  triton==3.2.0
9
+ gradio==5.50.0
10
  zhon==2.1.1
11
  huggingface_hub>=0.26.0