nornorr commited on
Commit
e7e09b0
·
1 Parent(s): 001f537

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -1,11 +1,11 @@
1
  import streamlit as st
2
  from transformers import pipeline
3
 
4
- classifier = pipeline("image-to-text", model="vit-gpt2-image-captioning")
5
  def main():
6
  st.title("image-to-text")
7
 
8
- with st.form("image_field"):
9
  image = st.file_uploader('Choose a file')
10
  # clicked==True only when the button is clicked
11
  clicked = st.form_submit_button("Submit")
 
1
  import streamlit as st
2
  from transformers import pipeline
3
 
4
+ classifier = pipeline("image-to-text", model="nlpconnect/vit-gpt2-image-captioning")
5
  def main():
6
  st.title("image-to-text")
7
 
8
+ with st.form("image"):
9
  image = st.file_uploader('Choose a file')
10
  # clicked==True only when the button is clicked
11
  clicked = st.form_submit_button("Submit")