Update app.py
#2
by
sikeaditya
- opened
app.py
CHANGED
@@ -2,6 +2,8 @@ import os
|
|
2 |
import streamlit as st
|
3 |
import pytesseract
|
4 |
from pdf2image import convert_from_bytes
|
|
|
|
|
5 |
|
6 |
# Configure Tesseract path
|
7 |
pytesseract.pytesseract.tesseract_cmd = "/usr/bin/tesseract"
|
@@ -45,8 +47,12 @@ uploaded_file = st.file_uploader("π **Upload a scanned PDF report**", type=["
|
|
45 |
if uploaded_file:
|
46 |
st.markdown('<div class="report-container"><b>π File Uploaded:</b> β
Ready for processing</div>', unsafe_allow_html=True)
|
47 |
|
48 |
-
|
49 |
-
|
|
|
|
|
|
|
|
|
50 |
### π Farmer-Friendly Soil Analysis Report
|
51 |
|
52 |
**Lawn:**
|
|
|
2 |
import streamlit as st
|
3 |
import pytesseract
|
4 |
from pdf2image import convert_from_bytes
|
5 |
+
import time
|
6 |
+
|
7 |
|
8 |
# Configure Tesseract path
|
9 |
pytesseract.pytesseract.tesseract_cmd = "/usr/bin/tesseract"
|
|
|
47 |
if uploaded_file:
|
48 |
st.markdown('<div class="report-container"><b>π File Uploaded:</b> β
Ready for processing</div>', unsafe_allow_html=True)
|
49 |
|
50 |
+
|
51 |
+
if st.button("π **Analyze Soil Report**", help="Click to start AI-powered analysis!"):
|
52 |
+
with st.spinner("π Analyzing soil report... Please wait..."):
|
53 |
+
time.sleep(3) # Simulates processing time
|
54 |
+
|
55 |
+
st.markdown("""
|
56 |
### π Farmer-Friendly Soil Analysis Report
|
57 |
|
58 |
**Lawn:**
|