alrab222 commited on
Commit
7f2faca
1 Parent(s): 010b144

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -8
app.py CHANGED
@@ -21,11 +21,12 @@ def inference(gr_input):
21
  text = "\n".join(idols)
22
  return text
23
 
24
-
25
- inputs = gr.inputs.Image()
26
- gr.Markdown(
27
- "# <center> デレマス画像分類器\n"
28
- "## <center> シンデレラガールズのキャラの画像を貼ると、機械学習で判別できるモデルです\n"
29
- )
30
- interface = gr.Interface(fn=inference, inputs=inputs, outputs="text")
31
- interface.launch()
 
 
21
  text = "\n".join(idols)
22
  return text
23
 
24
+ with gr.Blocks() as app:
25
+ inputs = gr.inputs.Image()
26
+ output = gr.Textbox()
27
+ gr.Markdown(
28
+ "# <center> デレマス画像分類器\n"
29
+ "## <center> シンデレラガールズのキャラの画像を貼ると、機械学習で判別できるモデルです\n"
30
+ )
31
+ inputs.change(inference, inputs, out)
32
+ demo.launch()