Soumen commited on
Commit
9f43588
·
1 Parent(s): ea6bf13

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -72,7 +72,7 @@ def bansum(text):
72
  st.success(text_output)
73
 
74
  st.title("Bangla and English Summarizer:")
75
- st.subheader("Please, Upload your PDF/Images or write texts to see the summarize options: ")
76
  #@st.cache_resource(experimental_allow_widgets=True)
77
  def main():
78
  """ NLP Based Application with Streamlit """
@@ -91,8 +91,9 @@ def main():
91
  tet = read_pdf(uploaded_photo)
92
  #tet = pytesseract.image_to_string(img, lang="ben") if st.checkbox("Mark to see Bangla Image's Text") else pytesseract.image_to_string(img)
93
  values = st.slider('Select a approximate number of lines to see and summarize',value=[0, len(tet)//(7*100)])
 
94
  text = tet[values[0]*7*10:values[1]*7*10] if values[0]!=len(tet)//(7*10) else tet[len(tet)//(7*100):]
95
- if st.checkbox("Show selected text from the pdf:")
96
  st.success(text)
97
  engsum(text)
98
  if uploaded_photo:
 
72
  st.success(text_output)
73
 
74
  st.title("Bangla and English Summarizer:")
75
+ st.subheader("Please, upload your PDF/Images or input texts to summarize: ")
76
  #@st.cache_resource(experimental_allow_widgets=True)
77
  def main():
78
  """ NLP Based Application with Streamlit """
 
91
  tet = read_pdf(uploaded_photo)
92
  #tet = pytesseract.image_to_string(img, lang="ben") if st.checkbox("Mark to see Bangla Image's Text") else pytesseract.image_to_string(img)
93
  values = st.slider('Select a approximate number of lines to see and summarize',value=[0, len(tet)//(7*100)])
94
+ st.text("Select the text from you pdf")
95
  text = tet[values[0]*7*10:values[1]*7*10] if values[0]!=len(tet)//(7*10) else tet[len(tet)//(7*100):]
96
+ if st.checkbox("Show the selected text:"):
97
  st.success(text)
98
  engsum(text)
99
  if uploaded_photo: