Update src/streamlit_app.py
Browse files- src/streamlit_app.py +5 -13
src/streamlit_app.py
CHANGED
|
@@ -208,16 +208,9 @@ with col1:
|
|
| 208 |
st.markdown('<a href="#prediction-section" class="custom-btn">Start Detecting</a>', unsafe_allow_html=True)
|
| 209 |
|
| 210 |
with col2:
|
| 211 |
-
# Prefer local static image if present; fallback
|
| 212 |
hero_local = PUBLIC_DIR / "1.png"
|
| 213 |
-
|
| 214 |
-
st.image(str(hero_local), use_column_width=True, width=500)
|
| 215 |
-
else:
|
| 216 |
-
st.image(
|
| 217 |
-
"https://images.unsplash.com/photo-1587502537745-84b86da1204c",
|
| 218 |
-
use_column_width=True,
|
| 219 |
-
width=500,
|
| 220 |
-
)
|
| 221 |
|
| 222 |
# --- INFO SECTION ---
|
| 223 |
st.divider()
|
|
@@ -306,10 +299,9 @@ with st.sidebar:
|
|
| 306 |
("loss.png", "Loss"),
|
| 307 |
]:
|
| 308 |
img_path = PUBLIC_DIR / rel
|
| 309 |
-
|
| 310 |
-
|
| 311 |
-
|
| 312 |
-
shown_any = True
|
| 313 |
|
| 314 |
if not shown_any:
|
| 315 |
st.caption("Place images like public/acc.png and public/loss.png to display here.")
|
|
|
|
| 208 |
st.markdown('<a href="#prediction-section" class="custom-btn">Start Detecting</a>', unsafe_allow_html=True)
|
| 209 |
|
| 210 |
with col2:
|
| 211 |
+
# Prefer local static image if present; fallback to remote URL
|
| 212 |
hero_local = PUBLIC_DIR / "1.png"
|
| 213 |
+
st.image(str(hero_local), use_column_width=True, width=500)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 214 |
|
| 215 |
# --- INFO SECTION ---
|
| 216 |
st.divider()
|
|
|
|
| 299 |
("loss.png", "Loss"),
|
| 300 |
]:
|
| 301 |
img_path = PUBLIC_DIR / rel
|
| 302 |
+
st.caption(f"{label} (from {img_path.name})")
|
| 303 |
+
st.image(str(img_path), use_column_width=True)
|
| 304 |
+
shown_any = True
|
|
|
|
| 305 |
|
| 306 |
if not shown_any:
|
| 307 |
st.caption("Place images like public/acc.png and public/loss.png to display here.")
|