samplemodel01 / app.py
gitshiva's picture
added debug statement
39f2ae9
raw
history blame contribute delete
384 Bytes
import tensorflow as tf
from tensorflow import keras
import gradio as gr
model = tf.keras.models.load_model('samplemodel01.keras')
def prediction(x):
a2 = [[int(x)]]
print (a2)
a2 = tf.convert_to_tensor(a2)
return model.predict(a2)
demo = gr.Interface(
fn=prediction,
inputs=["text"],
outputs=["text"]
)
demo.launch(server_name="0.0.0.0", share=True)