Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -47,8 +47,21 @@ def show_preds_image(image_path,model_selection):
|
|
| 47 |
|
| 48 |
conf = (classify_image(image_path,model_selection))
|
| 49 |
html = f'<p>petra</p><a href="https://www.gradio.app/docs/examples" target="_blank">"https://www.gradio.app/docs/examples"</a>'
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 50 |
|
| 51 |
-
return img,conf,html
|
| 52 |
|
| 53 |
|
| 54 |
inputs_image = gr.Image(type="filepath", label="Input Image")
|
|
@@ -57,6 +70,7 @@ model_selection = gr.Dropdown(["VGG19","ResNet50","Efficientnet"])
|
|
| 57 |
outputs_image = gr.Image(type="numpy", label="Output Image")
|
| 58 |
output_text = gr.Textbox()
|
| 59 |
link = gr.HTML()
|
|
|
|
| 60 |
|
| 61 |
interface_image = gr.Interface(
|
| 62 |
fn=show_preds_image,
|
|
|
|
| 47 |
|
| 48 |
conf = (classify_image(image_path,model_selection))
|
| 49 |
html = f'<p>petra</p><a href="https://www.gradio.app/docs/examples" target="_blank">"https://www.gradio.app/docs/examples"</a>'
|
| 50 |
+
map_link = "https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d387195.9481044243!2d-74.25908989999999!3d40.6971494!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x89c24fa5d33f083b%3A0xc80b8f06e177fe62!2sNew%20York%2C%20NY!5e0!3m2!1sen!2sus!4v1645590913133!5m2!1sen!2sus"
|
| 51 |
+
map =f'''
|
| 52 |
+
<!DOCTYPE html>
|
| 53 |
+
<html>
|
| 54 |
+
<head>
|
| 55 |
+
<title>Map Display</title>
|
| 56 |
+
</head>
|
| 57 |
+
<body>
|
| 58 |
+
<h1>Map Display</h1>
|
| 59 |
+
<iframe width="600" height="450" frameborder="0" style="border:0" src="{map_link}" allowfullscreen></iframe>
|
| 60 |
+
</body>
|
| 61 |
+
</html>
|
| 62 |
+
'''
|
| 63 |
|
| 64 |
+
return img,conf,html,map
|
| 65 |
|
| 66 |
|
| 67 |
inputs_image = gr.Image(type="filepath", label="Input Image")
|
|
|
|
| 70 |
outputs_image = gr.Image(type="numpy", label="Output Image")
|
| 71 |
output_text = gr.Textbox()
|
| 72 |
link = gr.HTML()
|
| 73 |
+
map = gr.HTML()
|
| 74 |
|
| 75 |
interface_image = gr.Interface(
|
| 76 |
fn=show_preds_image,
|