Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -12,9 +12,9 @@ def detect(inp):
|
|
12 |
r = requests.post(url='https://hf.space/gradioiframe/Sa-m/Political-Party-Symbol-Detector-V1/+/api/predict/',
|
13 |
json={"data": [bs64Data]})
|
14 |
|
15 |
-
return r
|
16 |
|
17 |
inp = gr.inputs.Image(type='file', label="Input Image")
|
18 |
-
output=gr.outputs.
|
19 |
io=gr.Interface(fn=detect, inputs=inp, outputs=output, title='Party Symbol Detector API',examples=['8.jpg','24.jpg'])
|
20 |
io.launch(debug=True,share=False)
|
|
|
12 |
r = requests.post(url='https://hf.space/gradioiframe/Sa-m/Political-Party-Symbol-Detector-V1/+/api/predict/',
|
13 |
json={"data": [bs64Data]})
|
14 |
|
15 |
+
return r.json()
|
16 |
|
17 |
inp = gr.inputs.Image(type='file', label="Input Image")
|
18 |
+
output=gr.outputs.Textbox(label='Response')
|
19 |
io=gr.Interface(fn=detect, inputs=inp, outputs=output, title='Party Symbol Detector API',examples=['8.jpg','24.jpg'])
|
20 |
io.launch(debug=True,share=False)
|