krushna commited on
Commit
6cc75ef
·
1 Parent(s): e464666

Creat app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -0
app.py ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
 
1
+ from fastai.text.all import *
2
+ import gradio as gr
3
+ learn = load_learner('imdb10epoch.pth')
4
+ def predict(text): return learn.predict(text, n_words=30)
5
+ intr = gr.Interface(predict, "text", "text")
6
+ intr.launch(inline =False)