Spaces:
Runtime error
Runtime error
Commit
Β·
afa2b54
1
Parent(s):
d1b7b0f
Update app.py
Browse files
app.py
CHANGED
@@ -15,12 +15,13 @@ def infer(original_image):
|
|
15 |
image = image.astype("float32") / 255.0
|
16 |
image = np.expand_dims(image, axis=0)
|
17 |
output_image = model.predict(image)
|
|
|
|
|
|
|
|
|
18 |
output_image = tf.cast((output_image[0, :, :, :] * 255), dtype=np.uint8)
|
19 |
-
|
20 |
-
|
21 |
-
(np.shape(output_image)[0], np.shape(output_image)[1], 3)
|
22 |
-
)
|
23 |
-
output_image = np.uint32(output_image)
|
24 |
return output_image
|
25 |
|
26 |
iface = gr.Interface(
|
|
|
15 |
image = image.astype("float32") / 255.0
|
16 |
image = np.expand_dims(image, axis=0)
|
17 |
output_image = model.predict(image)
|
18 |
+
|
19 |
+
|
20 |
+
|
21 |
+
|
22 |
output_image = tf.cast((output_image[0, :, :, :] * 255), dtype=np.uint8)
|
23 |
+
|
24 |
+
|
|
|
|
|
|
|
25 |
return output_image
|
26 |
|
27 |
iface = gr.Interface(
|