Update app.py
Browse files
app.py
CHANGED
|
@@ -234,7 +234,29 @@ def process_audio(selected_label, selected_device):
|
|
| 234 |
outputs += [""] * (total_outputs_needed - len(outputs))
|
| 235 |
return outputs
|
| 236 |
|
|
|
|
|
|
|
| 237 |
def gradio_interface():
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 238 |
interface = gr.Interface(
|
| 239 |
fn=process_audio,
|
| 240 |
inputs=[
|
|
@@ -277,9 +299,11 @@ def gradio_interface():
|
|
| 277 |
<li><strong>Mobile Device:</strong> a, b, c, s1, s2, s3</li>
|
| 278 |
</ul>
|
| 279 |
""",
|
|
|
|
| 280 |
live=True,
|
| 281 |
allow_flagging="never"
|
| 282 |
)
|
| 283 |
interface.launch()
|
| 284 |
|
| 285 |
gradio_interface()
|
|
|
|
|
|
| 234 |
outputs += [""] * (total_outputs_needed - len(outputs))
|
| 235 |
return outputs
|
| 236 |
|
| 237 |
+
import gradio as gr
|
| 238 |
+
|
| 239 |
def gradio_interface():
|
| 240 |
+
|
| 241 |
+
theme = gr.themes.Base(
|
| 242 |
+
primary_hue="blue",
|
| 243 |
+
secondary_hue="blue",
|
| 244 |
+
neutral_hue="gray"
|
| 245 |
+
)
|
| 246 |
+
theme.set(
|
| 247 |
+
body_background_fill="*primary_50",
|
| 248 |
+
body_background_fill_dark="*checkbox_background_color_focus",
|
| 249 |
+
body_text_color_dark="white",
|
| 250 |
+
body_text_color="*neutral_800",
|
| 251 |
+
background_fill_secondary_dark="*checkbox_border_color_hover",
|
| 252 |
+
block_background_fill="*background_fill_primary",
|
| 253 |
+
block_background_fill_dark="*neutral_800",
|
| 254 |
+
block_border_color_dark="*primary_100",
|
| 255 |
+
block_border_width_dark="4px",
|
| 256 |
+
block_border_width="4px",
|
| 257 |
+
block_border_color="*secondary_200"
|
| 258 |
+
)
|
| 259 |
+
|
| 260 |
interface = gr.Interface(
|
| 261 |
fn=process_audio,
|
| 262 |
inputs=[
|
|
|
|
| 299 |
<li><strong>Mobile Device:</strong> a, b, c, s1, s2, s3</li>
|
| 300 |
</ul>
|
| 301 |
""",
|
| 302 |
+
theme=theme,
|
| 303 |
live=True,
|
| 304 |
allow_flagging="never"
|
| 305 |
)
|
| 306 |
interface.launch()
|
| 307 |
|
| 308 |
gradio_interface()
|
| 309 |
+
|