etahamad commited on
Commit
42fdf58
·
1 Parent(s): 784d7d0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -4
app.py CHANGED
@@ -11,7 +11,6 @@ class_names = {
11
  1: 'Dyed lifted polyps'
12
  }
13
 
14
-
15
  def classify_image(image):
16
  # Preprocess the image
17
  img_array = tf.image.resize(image, [256, 256])
@@ -24,14 +23,13 @@ def classify_image(image):
24
 
25
  return class_names[predicted_class.numpy()], confidence
26
 
27
-
28
  iface = gr.Interface(
29
  fn=classify_image,
30
  inputs="image",
31
  outputs=["text", "number"],
32
- interpretation="default",
33
  examples=[
34
  ['examples/0.jpg'],
35
  ['examples/1.jpg'],
36
  ])
37
- iface.launch()
 
11
  1: 'Dyed lifted polyps'
12
  }
13
 
 
14
  def classify_image(image):
15
  # Preprocess the image
16
  img_array = tf.image.resize(image, [256, 256])
 
23
 
24
  return class_names[predicted_class.numpy()], confidence
25
 
 
26
  iface = gr.Interface(
27
  fn=classify_image,
28
  inputs="image",
29
  outputs=["text", "number"],
30
+ share=True,
31
  examples=[
32
  ['examples/0.jpg'],
33
  ['examples/1.jpg'],
34
  ])
35
+ iface.launch()