Spaces:
Sleeping
Sleeping
Update pages/1_Introduction.py
Browse files
- pages/1_Introduction.py +0 -15
pages/1_Introduction.py
CHANGED
|
@@ -4,21 +4,6 @@ from PIL import Image
|
|
| 4 |
import streamlit as st
|
| 5 |
from PIL import Image
|
| 6 |
|
| 7 |
-
# Simplified path
|
| 8 |
-
image_path = r"C:\Users\USER\Downloads\DALL路E 2024-12-27 18.19.15 - A warm and cozy scene of a father sitting with his 3-year-old child in a living room, showing pictures of dogs and cats. The father is pointing at a p.webp" # Ensure this file is in the same directory or an accessible folder
|
| 9 |
-
|
| 10 |
-
try:
|
| 11 |
-
image = Image.open(image_path)
|
| 12 |
-
st.image(image, caption="A father teaching his child by showing dog and cat pictures", use_column_width=True)
|
| 13 |
-
except FileNotFoundError:
|
| 14 |
-
st.error("Image file not found. Please upload the image or check the file path.")
|
| 15 |
-
|
| 16 |
-
# Optionally: Allow user uploads
|
| 17 |
-
uploaded_file = st.file_uploader("Upload an image", type=["webp", "jpg", "jpeg", "png"])
|
| 18 |
-
if uploaded_file is not None:
|
| 19 |
-
image = Image.open(uploaded_file)
|
| 20 |
-
st.image(image, caption="Uploaded image", use_column_width=True)
|
| 21 |
-
|
| 22 |
# Title and introduction
|
| 23 |
st.title('Understanding Machine Learning: Teaching Machines Like Children')
|
| 24 |
|
|
|
|
| 4 |
import streamlit as st
|
| 5 |
from PIL import Image
|
| 6 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 7 |
# Title and introduction
|
| 8 |
st.title('Understanding Machine Learning: Teaching Machines Like Children')
|
| 9 |
|