File size: 6,593 Bytes
b27831c
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Student Exam Performance Indicator</title>
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet">
    <style>

        body {

            background: linear-gradient(135deg, #71b7e6, #9b59b6);

            font-family: 'Roboto', sans-serif;

            min-height: 100vh;

            display: flex;

            justify-content: center;

            align-items: center;

        }



        .login {

            background-color: white;

            padding: 40px;

            border-radius: 15px;

            box-shadow: 0px 10px 20px rgba(0, 0, 0, 0.1);

            max-width: 600px;

            width: 100%;

            

        }



        h1 {

            text-align: center;

            margin-bottom: 20px;

            font-size: 2rem;

            color: #333;

        }



        .form-label {

            font-weight: 500;

            color: #333;

        }



        .form-control {

            border: 2px solid #e3e3e3;

            border-radius: 10px;

            padding: 10px;

            transition: border-color 0.3s ease;

        }



        .form-control:focus {

            border-color: #9b59b6;

            box-shadow: 0 0 10px rgba(155, 89, 182, 0.2);

        }



        .btn-primary {

            background-color: #9b59b6;

            border-color: #9b59b6;

            width: 100%;

            padding: 10px;

            font-size: 1rem;

            border-radius: 10px;

            transition: background-color 0.3s ease;

        }



        .btn-primary:hover {

            background-color: #8e44ad;

        }



        h2 {

            text-align: center;

            margin-top: 30px;

            color: #333;

            font-size: 1.5rem;

        }



        /* Media Query for Mobile */

        @media (max-width: 768px) {

            .login {

                padding: 20px;

            }



            h1 {

                font-size: 1.5rem;

            }

        }

    </style>
</head>
<body>
    <div class="login">
       <h1>Student Exam Performance Indicator</h1>
   
       <form action="{{ url_for('predict_datapoint') }}" method="post">
            <h1>
                <legend>Student Exam Performance Prediction</legend>
            </h1>
        
            <!-- Gender -->
            <div class="mb-3">
                <label class="form-label">Gender</label>
                <select class="form-control" name="gender" required>
                    <option class="placeholder" selected disabled value="">Select your Gender</option>
                    <option value="male">Male</option>
                    <option value="female">Female</option>
                </select>
            </div>

            <!-- Race or Ethnicity -->
            <div class="mb-3">
                <label class="form-label">Race or Ethnicity</label>
                <select class="form-control" name="ethnicity" required>
                    <option class="placeholder" selected disabled value="">Select Ethnicity</option>
                    <option value="group A">Group A</option>
                    <option value="group B">Group B</option>
                    <option value="group C">Group C</option>
                    <option value="group D">Group D</option>
                    <option value="group E">Group E</option>
                </select>
            </div>

            <!-- Parental Level of Education -->
            <div class="mb-3">
                <label class="form-label">Parental Level of Education</label>
                <select class="form-control" name="parental_level_of_education" required>
                    <option class="placeholder" selected disabled value="">Select Parent Education</option>
                    <option value="associate's degree">Associate's degree</option>
                    <option value="bachelor's degree">Bachelor's degree</option>
                    <option value="high school">High school</option>
                    <option value="master's degree">Master's degree</option>
                    <option value="some college">Some college</option>
                    <option value="some high school">Some high school</option>
                </select>
            </div>

            <!-- Lunch Type -->
            <div class="mb-3">
                <label class="form-label">Lunch Type</label>
                <select class="form-control" name="lunch" required>
                    <option class="placeholder" selected disabled value="">Select Lunch Type</option>
                    <option value="free/reduced">Free/Reduced</option>
                    <option value="standard">Standard</option>
                </select>
            </div>

            <!-- Test Preparation Course -->
            <div class="mb-3">
                <label class="form-label">Test Preparation Course</label>
                <select class="form-control" name="test_preparation_course" required>
                    <option class="placeholder" selected disabled value="">Select Test Course</option>
                    <option value="none">None</option>
                    <option value="completed">Completed</option>
                </select>
            </div>

            <!-- Writing Score -->
            <div class="mb-3">
                <label class="form-label">Writing Score (out of 100)</label>
                <input class="form-control" type="number" name="writing_score" placeholder="Enter your Writing score" min="0" max="100" required />
            </div>

            <!-- Reading Score -->
            <div class="mb-3">
                <label class="form-label">Reading Score (out of 100)</label>
                <input class="form-control" type="number" name="reading_score" placeholder="Enter your Reading score" min="0" max="100" required />
            </div>

            <!-- Submit Button -->
            <div class="mb-3">
                <input class="btn btn-primary" type="submit" value="Predict your Math Score" />
            </div>
        </form>

        <!-- Display prediction result -->
        <h2>
           The prediction is: {{ results }}
        </h2>
    </div>

    <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js"></script>
</body>
</html>