Spaces:
Runtime error
Runtime error
fix painter selection
Browse files
app.py
CHANGED
@@ -28,7 +28,14 @@ def predict(cg: ClimateGAN, api_key):
|
|
28 |
img_np = io.imread(static_map_url)
|
29 |
else:
|
30 |
img_np = image
|
31 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
32 |
|
33 |
input_image = output_dict["input"]
|
34 |
masked_input = output_dict["masked_input"]
|
|
|
28 |
img_np = io.imread(static_map_url)
|
29 |
else:
|
30 |
img_np = image
|
31 |
+
|
32 |
+
painters = {
|
33 |
+
"ClimateGAN Painter": "both",
|
34 |
+
"Stable Diffusion Painter": "stable_diffusion",
|
35 |
+
"Both": "climategan",
|
36 |
+
}
|
37 |
+
|
38 |
+
output_dict = cg.infer_single(img_np, painters[painter])
|
39 |
|
40 |
input_image = output_dict["input"]
|
41 |
masked_input = output_dict["masked_input"]
|