Jim Dowling
commited on
Commit
·
c401e7f
1
Parent(s):
ad21bf1
update defaults
Browse files
app.py
CHANGED
@@ -26,17 +26,17 @@ def show_image(img):
|
|
26 |
img_path = f"Models/{name}/{version}/images/{img}.png"
|
27 |
|
28 |
# Upload the Python script to the "Models", and overwrite if it already exists
|
29 |
-
downloaded_file_path = dataset_api.download(img_path, overwrite=
|
30 |
image = Image.open(f"{img}.png")
|
31 |
return image
|
32 |
|
33 |
# Define the Gradio interface
|
34 |
iface = gr.Interface(
|
35 |
fn=show_image,
|
36 |
-
inputs=gr.Textbox(
|
37 |
outputs="image",
|
38 |
title="Display PNG Image",
|
39 |
)
|
40 |
|
41 |
# Launch the interface
|
42 |
-
iface.launch()
|
|
|
26 |
img_path = f"Models/{name}/{version}/images/{img}.png"
|
27 |
|
28 |
# Upload the Python script to the "Models", and overwrite if it already exists
|
29 |
+
downloaded_file_path = dataset_api.download(img_path, overwrite=False)
|
30 |
image = Image.open(f"{img}.png")
|
31 |
return image
|
32 |
|
33 |
# Define the Gradio interface
|
34 |
iface = gr.Interface(
|
35 |
fn=show_image,
|
36 |
+
inputs=gr.Textbox(label="Image Name"),
|
37 |
outputs="image",
|
38 |
title="Display PNG Image",
|
39 |
)
|
40 |
|
41 |
# Launch the interface
|
42 |
+
iface.launch(share=True, inputs=["fig1","fig2"])
|