!pip install -q gradio joblib import gradio as gr import joblib # Load model model = joblib.load("dbs.jl") # Prediction function def predict_dbs(x): pred = model.predict([[x]]) pred = pred[0][0] return pred # extract single value # Gradio interface demo = gr.Interface( fn=predict_dbs, inputs=gr.Number(label="Input value"), outputs=gr.Number(label="Prediction"), title="DBS Prediction App" ) demo.launch()