File size: 3,852 Bytes
43708ce
 
 
 
 
 
 
 
 
 
 
 
 
 
 
cddff6d
43708ce
 
 
 
 
cddff6d
43708ce
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
6d4d013
 
43708ce
 
 
 
 
cddff6d
 
43708ce
 
 
cddff6d
 
43708ce
 
cddff6d
 
41406da
cddff6d
 
 
 
 
43708ce
 
 
cddff6d
 
43708ce
 
 
cddff6d
 
43708ce
 
 
cddff6d
 
43708ce
 
 
 
 
 
 
 
1
2
3
4
5
6
7
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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
import streamlit as st

# Set the page configuration
st.set_page_config(page_title="ML vs DL", page_icon="🤖")

# Custom CSS for styling
st.markdown("""
    <style>
    body {
        font-family: 'Arial', sans-serif;
        background-color: #f4f4f4;
    }
    .title {
        text-align: center;
        font-size: 2.5rem;
        color: black;
        margin-bottom: 10px;
    }
    .subtitle {
        text-align: center;
        font-size: 1.2rem;
        color: violet;
        margin-bottom: 30px;
    }
    .table-container {
        margin: 0 auto;
        width: 80%;
        background-color: #fff;
        border-radius: 10px;
        box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
        padding: 20px;
    }
    .styled-table {
        width: 100%;
        border-collapse: collapse;
        font-size: 1rem;
    }
    .styled-table thead tr {
        background-color: #4CAF50;
        color: #ffffff;
        text-align: left;
    }
    .styled-table th, .styled-table td {
        padding: 12px 15px;
    }
    .styled-table tbody tr {
        border-bottom: 1px solid #dddddd;
    }
    .styled-table tbody tr:nth-of-type(even) {
        background-color: #f3f3f3;
    }
    .styled-table tbody tr:last-of-type {
        border-bottom: 2px solid #4CAF50;
    }
    </style>
""", unsafe_allow_html=True)

# Title and subtitle
st.markdown('<div class="title">Machine Learning vs Deep Learning</div>', unsafe_allow_html=True)
st.markdown('<div class="subtitle">Understanding the key differences</div>', unsafe_allow_html=True)

# HTML table for differences
html_table = """
<div class="table-container">
    <table class="styled-table">
        <thead>
            <tr>
                <th>Aspect</th>
                <th>Machine Learning</th>
                <th>Deep Learning</th>
            </tr>
        </thead>
        <tbody>
            <tr>
                <td>Definition</td>
                <td>Machine Learning is a tool which needs statistical concepts to copy / mimic the learning ability in natural intelligence </td>
                <td>Deep Learning is a tool which needs logical structure known as neural network to copy / mimic the learning ability in natural intelligence</td>
            </tr>
            <tr>
                <td>Data Dependency</td>
                <td>ML performs well with structured data (**tabular data**) and smaller datasets</td>
                <td>DL is hungry of data as it requires large amounts of unstructured data and also structured data to perform well</td>
            </tr>
            <tr>
                <td>Performance</td>
                <td>ML have treshold as the data increases the performance becomes stable</td>
                <td>DL performance increases as the data increases because DL is hungry of data</td>
            </tr>
            <tr>
                <td>Memory Management</td>
                <td>ML memory uasage is less as it uses less data</td>
                <td>DL memory usage is large as it has huge data</td>
            </tr>
            <tr>
                <td>Hardware Requirements</td>
                <td>ML works on standard CPUs; lower hardware demands</td>
                <td>DL requires GPUs for efficient computation.</td>
            </tr>
            <tr>
                <td>Interpretability</td>
                <td>ML is more interpretable as it works on smaller datasets </td>
                <td>DL is less interpretable as it works on complex neural networks</td>
            </tr>
            <tr>
                <td>Training Time</td>
                <td>ML is relatively faster to train models as it uses less data</td>
                <td>DL training can take significantly longer</td>
            </tr>
        </tbody>
    </table>
</div>
"""

# Render the HTML table
st.markdown(html_table, unsafe_allow_html=True)