c-walls commited on
Commit
999fa11
·
1 Parent(s): a954d15

new main function

Browse files
Files changed (1) hide show
  1. app.py +8 -3
app.py CHANGED
@@ -1,7 +1,12 @@
1
  import gradio as gr
 
2
 
3
- def greet(name):
4
- return "Hi " + name + "!!"
5
 
6
- demo = gr.Interface(fn=greet, inputs="sketchpad", outputs="label")
 
 
 
 
 
7
  demo.launch()
 
1
  import gradio as gr
2
+ import tensorflow as tf
3
 
4
+ model = tf.keras.models.load_model("mnist_checker/model/saved_model.pb")
 
5
 
6
+ def mnist_classifier(img):
7
+ #img = tf.image.resize(img, [28, 28])
8
+ #img = tf.cast(img, tf.float32)
9
+ return img
10
+
11
+ demo = gr.Interface(fn=mnist_classifier, inputs="sketchpad", outputs="image")
12
  demo.launch()