Spaces:
Sleeping
Sleeping
Update pages/1_Introduction.py
Browse files- pages/1_Introduction.py +6 -13
pages/1_Introduction.py
CHANGED
|
@@ -1,19 +1,12 @@
|
|
| 1 |
import streamlit as st
|
| 2 |
from PIL import Image
|
| 3 |
-
import base64
|
| 4 |
import io
|
| 5 |
|
| 6 |
-
#
|
|
|
|
| 7 |
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
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"
|
| 11 |
-
|
| 12 |
-
try:
|
| 13 |
-
image = Image.open(image_path)
|
| 14 |
-
image.show() # To display the image
|
| 15 |
-
except Exception as e:
|
| 16 |
-
print(f"Error opening image: {e}")
|
| 17 |
|
| 18 |
# Title and introduction
|
| 19 |
st.title('Understanding Machine Learning: Teaching Machines Like Children')
|
|
@@ -25,8 +18,7 @@ In this app, we'll use the analogy of a father teaching his child to explain the
|
|
| 25 |
""")
|
| 26 |
|
| 27 |
# Display the image
|
| 28 |
-
|
| 29 |
-
st.image(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", caption='A father teaching his child by showing dog and cat pictures')
|
| 30 |
|
| 31 |
# Supervised Learning Explanation
|
| 32 |
st.header('Supervised Learning')
|
|
@@ -56,3 +48,4 @@ Unsupervised learning helps the machine find structure in data without needing l
|
|
| 56 |
st.write("""
|
| 57 |
Machine Learning mirrors how humans, especially children, learn by observing and being guided. This analogy helps simplify the complex concepts behind teaching machines to recognize patterns and make decisions. Just like the child learns over time, machines improve as they are exposed to more data.
|
| 58 |
""")
|
|
|
|
|
|
| 1 |
import streamlit as st
|
| 2 |
from PIL import Image
|
|
|
|
| 3 |
import io
|
| 4 |
|
| 5 |
+
# Path to the image generated by DALL-E
|
| 6 |
+
image_path = "/mnt/data/A_scene_showing_a_father_sitting_with_his_child_in.png"
|
| 7 |
|
| 8 |
+
# Open the image
|
| 9 |
+
image = Image.open(image_path)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 10 |
|
| 11 |
# Title and introduction
|
| 12 |
st.title('Understanding Machine Learning: Teaching Machines Like Children')
|
|
|
|
| 18 |
""")
|
| 19 |
|
| 20 |
# Display the image
|
| 21 |
+
st.image(image, caption="A father teaching his child by showing dog and cat pictures")
|
|
|
|
| 22 |
|
| 23 |
# Supervised Learning Explanation
|
| 24 |
st.header('Supervised Learning')
|
|
|
|
| 48 |
st.write("""
|
| 49 |
Machine Learning mirrors how humans, especially children, learn by observing and being guided. This analogy helps simplify the complex concepts behind teaching machines to recognize patterns and make decisions. Just like the child learns over time, machines improve as they are exposed to more data.
|
| 50 |
""")
|
| 51 |
+
|