Zakia commited on
Commit
6d2c26e
1 Parent(s): 8f428af

change theme and added bold for output

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -17,7 +17,7 @@ def predict(model, input_df):
17
  predictions_df = predict_model(estimator=model, data=input_df)
18
  predict_label = predictions_df["Label"][0] # either 1 (amputation yes) or 0 (amputation no)
19
  predict_score = predictions_df["Score"][0] # the prediction (accuracy)
20
- return "AMPUTATION RISK: " + str(predict_label) + " SCORE: "+str(predict_score)
21
 
22
 
23
 
@@ -71,7 +71,7 @@ iface = gr.Interface(
71
  article=article,
72
  inputs=[gr.inputs.Slider(minimum=0,maximum=100, step=1, default=0, label="Age"), gr.inputs.Dropdown(["Female", "Male"], default="Female", label="Gender"), gr.inputs.Dropdown(["Asian", "Black", "Coloured", "White", "Other"], default="Asian", label="Race"), gr.inputs.Dropdown(["1", "2"], default="1", label="Diabetes Type")],
73
  outputs="text",
74
- theme="grass",
75
  examples=[
76
  [50, "Male", "Black", 2],
77
  [76, "Female", "Asian", 2],
 
17
  predictions_df = predict_model(estimator=model, data=input_df)
18
  predict_label = predictions_df["Label"][0] # either 1 (amputation yes) or 0 (amputation no)
19
  predict_score = predictions_df["Score"][0] # the prediction (accuracy)
20
+ return "<b>AMPUTATION RISK: " + str(predict_label) + " SCORE: "+str(predict_score)+"</b>"
21
 
22
 
23
 
 
71
  article=article,
72
  inputs=[gr.inputs.Slider(minimum=0,maximum=100, step=1, default=0, label="Age"), gr.inputs.Dropdown(["Female", "Male"], default="Female", label="Gender"), gr.inputs.Dropdown(["Asian", "Black", "Coloured", "White", "Other"], default="Asian", label="Race"), gr.inputs.Dropdown(["1", "2"], default="1", label="Diabetes Type")],
73
  outputs="text",
74
+ theme="darkhuggingface",
75
  examples=[
76
  [50, "Male", "Black", 2],
77
  [76, "Female", "Asian", 2],