M. Saad Munawar
commited on
Commit
•
33871ce
1
Parent(s):
cf4755f
https://huggingface.co/spaces/Saad123/minimal
Browse files
app.py
CHANGED
@@ -1,5 +1,12 @@
|
|
1 |
import gradio as gr
|
2 |
-
|
3 |
-
|
4 |
-
|
5 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
import gradio as gr
|
2 |
+
import numpy as np
|
3 |
+
|
4 |
+
def model(image):
|
5 |
+
im_scaled = image/255
|
6 |
+
im_reshape = np.reshape(im_scaled,[1,224,224,3])
|
7 |
+
return im_reshape
|
8 |
+
|
9 |
+
image = gr.inputs.Image(shape=(224,224))
|
10 |
+
|
11 |
+
iface = gr.Interface(fn=model, inputs=image, outputs='numpy')
|
12 |
+
iface.launch()
|