Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -108,7 +108,14 @@ def get_pdf_text(pdf_docs):
|
|
| 108 |
txt_page=page.extract_text()
|
| 109 |
text += txt_page
|
| 110 |
return text
|
| 111 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 112 |
|
| 113 |
################################33333333333333333333333333333333333333333333333333333333
|
| 114 |
def main():
|
|
@@ -142,6 +149,7 @@ def main():
|
|
| 142 |
|
| 143 |
|
| 144 |
with st.sidebar:
|
|
|
|
| 145 |
|
| 146 |
st.subheader("Your documents")
|
| 147 |
pdf_docs = st.file_uploader("Upload your PDFs here and click on 'Process'", accept_multiple_files=True)
|
|
|
|
| 108 |
txt_page=page.extract_text()
|
| 109 |
text += txt_page
|
| 110 |
return text
|
| 111 |
+
#######################################################################################################################
|
| 112 |
+
def upload():
|
| 113 |
+
st.title("آپلود و نمایش فایل اکسل")
|
| 114 |
+
uploaded_file = st.file_uploader("لطفاً فایل اکسل خود را آپلود کنید", type=["xlsx", "xls"])
|
| 115 |
+
if uploaded_file is not None:
|
| 116 |
+
df = pd.read_excel(uploaded_file)
|
| 117 |
+
st.write("دیتا فریم مربوط به فایل اکسل:")
|
| 118 |
+
st.write(df)
|
| 119 |
|
| 120 |
################################33333333333333333333333333333333333333333333333333333333
|
| 121 |
def main():
|
|
|
|
| 149 |
|
| 150 |
|
| 151 |
with st.sidebar:
|
| 152 |
+
upload()
|
| 153 |
|
| 154 |
st.subheader("Your documents")
|
| 155 |
pdf_docs = st.file_uploader("Upload your PDFs here and click on 'Process'", accept_multiple_files=True)
|