Update app.py
Browse files
app.py
CHANGED
|
@@ -202,7 +202,7 @@ import time # To simulate delays during processing
|
|
| 202 |
|
| 203 |
def page_1():
|
| 204 |
add_background_image("bg.png")
|
| 205 |
-
#st.set_page_config(layout='wide', page_title="Virtual Tutor")
|
| 206 |
st.markdown("""
|
| 207 |
<svg width="600" height="100">
|
| 208 |
<text x="50%" y="50%" font-family="San serif" font-size="42px" fill="Black" text-anchor="middle" stroke="white"
|
|
@@ -224,7 +224,10 @@ def page_1():
|
|
| 224 |
time.sleep(1) # Simulate a step in the processing
|
| 225 |
|
| 226 |
# Step 1: Process images, texts, and videos
|
| 227 |
-
st.
|
|
|
|
|
|
|
|
|
|
| 228 |
image_collection, text_collection, video_collection = process_pdf(pdf_path)
|
| 229 |
st.session_state.image_collection = image_collection
|
| 230 |
st.session_state.text_collection = text_collection
|
|
@@ -237,6 +240,7 @@ def page_1():
|
|
| 237 |
except Exception as e:
|
| 238 |
st.error(f"Error processing PDF: {e}")
|
| 239 |
|
|
|
|
| 240 |
def page_2():
|
| 241 |
add_background_image("bg2.jpg")
|
| 242 |
st.markdown("""
|
|
|
|
| 202 |
|
| 203 |
def page_1():
|
| 204 |
add_background_image("bg.png")
|
| 205 |
+
# st.set_page_config(layout='wide', page_title="Virtual Tutor")
|
| 206 |
st.markdown("""
|
| 207 |
<svg width="600" height="100">
|
| 208 |
<text x="50%" y="50%" font-family="San serif" font-size="42px" fill="Black" text-anchor="middle" stroke="white"
|
|
|
|
| 224 |
time.sleep(1) # Simulate a step in the processing
|
| 225 |
|
| 226 |
# Step 1: Process images, texts, and videos
|
| 227 |
+
st.markdown(
|
| 228 |
+
"<p style='color: white; font-weight: bold;'>Extracting content from PDF...</p>",
|
| 229 |
+
unsafe_allow_html=True
|
| 230 |
+
)
|
| 231 |
image_collection, text_collection, video_collection = process_pdf(pdf_path)
|
| 232 |
st.session_state.image_collection = image_collection
|
| 233 |
st.session_state.text_collection = text_collection
|
|
|
|
| 240 |
except Exception as e:
|
| 241 |
st.error(f"Error processing PDF: {e}")
|
| 242 |
|
| 243 |
+
|
| 244 |
def page_2():
|
| 245 |
add_background_image("bg2.jpg")
|
| 246 |
st.markdown("""
|