Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -69,27 +69,28 @@ with gr.Blocks() as demo:
|
|
| 69 |
|
| 70 |
image_1 = gr.Image(
|
| 71 |
label = "Fixed Image",
|
| 72 |
-
source = "upload",
|
| 73 |
type = "filepath",
|
| 74 |
elem_id = "image-in",
|
| 75 |
)
|
| 76 |
image_2 = gr.Image(
|
| 77 |
label = "Moving Image",
|
| 78 |
-
source = "upload",
|
| 79 |
type = "filepath",
|
| 80 |
elem_id = "image-in",
|
| 81 |
)
|
| 82 |
|
|
|
|
| 83 |
model_list = gr.Dropdown(
|
| 84 |
["Imagenet-wild", "Imagenet-affine"], label="Model", info="select a model"
|
| 85 |
)
|
| 86 |
-
|
| 87 |
out_image = gr.Image(placeholder='Output', label = "ٌRegistered image",
|
| 88 |
#source = "upload",
|
| 89 |
#type = "filepath",
|
| 90 |
elem_id = "image-out"
|
| 91 |
)
|
| 92 |
-
inputs = [image_1, image_2
|
| 93 |
iface = gr.Interface(fn=imgnt_reg, inputs=inputs,outputs=out_image,
|
| 94 |
title="Imagenet registration V2",
|
| 95 |
description="Upload 2 images to generate a registered one:",
|
|
|
|
| 69 |
|
| 70 |
image_1 = gr.Image(
|
| 71 |
label = "Fixed Image",
|
| 72 |
+
#source = "upload",
|
| 73 |
type = "filepath",
|
| 74 |
elem_id = "image-in",
|
| 75 |
)
|
| 76 |
image_2 = gr.Image(
|
| 77 |
label = "Moving Image",
|
| 78 |
+
#source = "upload",
|
| 79 |
type = "filepath",
|
| 80 |
elem_id = "image-in",
|
| 81 |
)
|
| 82 |
|
| 83 |
+
'''
|
| 84 |
model_list = gr.Dropdown(
|
| 85 |
["Imagenet-wild", "Imagenet-affine"], label="Model", info="select a model"
|
| 86 |
)
|
| 87 |
+
'''
|
| 88 |
out_image = gr.Image(placeholder='Output', label = "ٌRegistered image",
|
| 89 |
#source = "upload",
|
| 90 |
#type = "filepath",
|
| 91 |
elem_id = "image-out"
|
| 92 |
)
|
| 93 |
+
inputs = [image_1, image_2]#, model_list]
|
| 94 |
iface = gr.Interface(fn=imgnt_reg, inputs=inputs,outputs=out_image,
|
| 95 |
title="Imagenet registration V2",
|
| 96 |
description="Upload 2 images to generate a registered one:",
|