Spaces:
Sleeping
Sleeping
Sathwikchowdary
commited on
Update pages/Life_cycle_of_ML.py
Browse files- pages/Life_cycle_of_ML.py +58 -60
pages/Life_cycle_of_ML.py
CHANGED
@@ -1,69 +1,67 @@
|
|
1 |
import streamlit as st
|
2 |
|
3 |
-
#
|
4 |
-
st.title("Machine Learning Life Cycle")
|
5 |
-
|
6 |
-
# HTML content inside a string for correct SVG rendering
|
7 |
html_content = """
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
<polygon points="0,0 10,5 0,10" fill="#000" />
|
62 |
-
</marker>
|
63 |
-
</defs>
|
64 |
</svg>
|
65 |
"""
|
66 |
|
|
|
|
|
|
|
|
|
67 |
# Render the SVG
|
68 |
st.markdown(html_content, unsafe_allow_html=True)
|
69 |
|
|
|
1 |
import streamlit as st
|
2 |
|
3 |
+
# HTML content inside a string for correct syntax
|
|
|
|
|
|
|
4 |
html_content = """
|
5 |
+
# Life Cycle of ML
|
6 |
+
|
7 |
+
The life cycle of Machine Learning (ML) involves several stages, from defining the problem to deploying the model. Here's an overview of each stage:
|
8 |
+
|
9 |
+
1. **Problem Definition:** Understanding the problem to define the goals and objectives of the ML model.
|
10 |
+
2. **Data Collection:** Gathering relevant data required to train the model.
|
11 |
+
3. **Data Preprocessing:** Cleaning and transforming the data into a usable format.
|
12 |
+
4. **Model Building:** Building and training machine learning models using the processed data.
|
13 |
+
5. **Evaluation:** Evaluating the performance of the model and adjusting it as needed.
|
14 |
+
6. **Deployment:** Deploying the model into a production environment.
|
15 |
+
|
16 |
+
---
|
17 |
+
|
18 |
+
## Shapes Representing the ML Life Cycle
|
19 |
+
|
20 |
+
<svg width="600" height="300">
|
21 |
+
<!-- Problem Definition (Rectangle) -->
|
22 |
+
<rect x="50" y="50" width="150" height="50" fill="#FFB6C1" stroke="#000" />
|
23 |
+
<text x="75" y="80" fill="#000" font-size="14">Problem Definition</text>
|
24 |
+
|
25 |
+
<!-- Data Collection (Circle) -->
|
26 |
+
<circle cx="300" cy="75" r="40" fill="#ADD8E6" stroke="#000" />
|
27 |
+
<text x="270" y="80" fill="#000" font-size="14">Data Collection</text>
|
28 |
+
|
29 |
+
<!-- Data Preprocessing (Ellipse) -->
|
30 |
+
<ellipse cx="500" cy="75" rx="80" ry="40" fill="#90EE90" stroke="#000" />
|
31 |
+
<text x="445" y="80" fill="#000" font-size="14">Data Preprocessing</text>
|
32 |
+
|
33 |
+
<!-- Arrows between Problem Definition and Data Collection -->
|
34 |
+
<line x1="200" y1="75" x2="260" y2="75" stroke="#000" marker-end="url(#arrow)" />
|
35 |
+
|
36 |
+
<!-- Model Building (Rectangle) -->
|
37 |
+
<rect x="50" y="200" width="150" height="50" fill="#FFD700" stroke="#000" />
|
38 |
+
<text x="75" y="230" fill="#000" font-size="14">Model Building</text>
|
39 |
+
|
40 |
+
<!-- Evaluation (Circle) -->
|
41 |
+
<circle cx="300" cy="225" r="40" fill="#FF7F50" stroke="#000" />
|
42 |
+
<text x="275" y="230" fill="#000" font-size="14">Evaluation</text>
|
43 |
+
|
44 |
+
<!-- Deployment (Rectangle) -->
|
45 |
+
<rect x="450" y="200" width="150" height="50" fill="#9370DB" stroke="#000" />
|
46 |
+
<text x="475" y="230" fill="#000" font-size="14">Deployment</text>
|
47 |
+
|
48 |
+
<!-- Arrows between Model Building, Evaluation, and Deployment -->
|
49 |
+
<line x1="125" y1="250" x2="260" y2="225" stroke="#000" marker-end="url(#arrow)" />
|
50 |
+
<line x1="340" y1="225" x2="450" y2="225" stroke="#000" marker-end="url(#arrow)" />
|
51 |
+
|
52 |
+
<!-- Define arrow marker -->
|
53 |
+
<defs>
|
54 |
+
<marker id="arrow" viewBox="0 0 10 10" refX="5" refY="5" markerWidth="4" markerHeight="4" orient="auto">
|
55 |
+
<polygon points="0,0 10,5 0,10" fill="#000" />
|
56 |
+
</marker>
|
57 |
+
</defs>
|
|
|
|
|
|
|
58 |
</svg>
|
59 |
"""
|
60 |
|
61 |
+
# Render HTML content in Streamlit
|
62 |
+
st.markdown(html_content, unsafe_allow_html=True)
|
63 |
+
|
64 |
+
|
65 |
# Render the SVG
|
66 |
st.markdown(html_content, unsafe_allow_html=True)
|
67 |
|