c-walls commited on
Commit
cff7c7c
·
1 Parent(s): 2eaa416

fix dict indexing again...

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -6,8 +6,9 @@ import tensorflow as tf
6
  def mnist_classifier(img):
7
  #img = tf.image.resize(img, [28, 28])
8
  #img = tf.cast(img, tf.float32)
9
- print(img.keys())
10
- return "returned: " + img.keys()
 
11
 
12
  demo = gr.Interface(fn=mnist_classifier, inputs="sketchpad", outputs="text", title="MNIST Checker", description="Draw a number 0-9 to see if the model can classify it.")
13
  demo.launch()
 
6
  def mnist_classifier(img):
7
  #img = tf.image.resize(img, [28, 28])
8
  #img = tf.cast(img, tf.float32)
9
+ print(img['background'])
10
+ print(img['composite'])
11
+ return "returned: " + img['layers']
12
 
13
  demo = gr.Interface(fn=mnist_classifier, inputs="sketchpad", outputs="text", title="MNIST Checker", description="Draw a number 0-9 to see if the model can classify it.")
14
  demo.launch()