Asib27 commited on
Commit
f307000
·
1 Parent(s): a4bffea

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -5,7 +5,7 @@ import tensorflow as tf
5
  import keras
6
  from keras import layers, models
7
 
8
- model = model = tf.keras.models.load_model('model/ocr_model.h5')
9
 
10
  def preprocessImage(img, shape):
11
  img = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY)
@@ -78,4 +78,4 @@ def greet(name):
78
  return "Hello " + name + "!!"
79
 
80
  iface = gr.Interface(fn=predict, inputs="image", outputs="text")
81
- iface.launch()
 
5
  import keras
6
  from keras import layers, models
7
 
8
+ model = model = tf.keras.models.load_model('model/ocr_model.h5', compile=False)
9
 
10
  def preprocessImage(img, shape):
11
  img = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY)
 
78
  return "Hello " + name + "!!"
79
 
80
  iface = gr.Interface(fn=predict, inputs="image", outputs="text")
81
+ iface.launch(sharing=True)