Spaces:
Runtime error
Runtime error
File size: 433 Bytes
7ea49cd |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
import gradio as gr
import sklearn
import joblib
model = joblib.load("snare_kick_classifier.joblib")
def classify(audio):
return model.predict([audio])[0]
gr.Interface(fn=classify,
inputs=gr.inputs.Audio(source="microphone", type="file", label="Audio"),
outputs="text",
title="Kick or Snare?",
description="A simple classifier that tells you whether the sound you're playing is a kick or a snare.",
).launch()
|