Upload 3 files
Browse files- static/css/style.css +58 -10
- templates/report.html +92 -111
static/css/style.css
CHANGED
|
@@ -51,9 +51,9 @@ canvas#canvas3d {
|
|
| 51 |
position: relative;
|
| 52 |
z-index: 20;
|
| 53 |
width: 100%;
|
| 54 |
-
max-width:
|
| 55 |
margin: 0 auto;
|
| 56 |
-
padding:
|
| 57 |
display: flex;
|
| 58 |
flex-direction: column;
|
| 59 |
min-height: 100vh;
|
|
@@ -83,7 +83,7 @@ nav {
|
|
| 83 |
|
| 84 |
/* Typography */
|
| 85 |
header {
|
| 86 |
-
margin:
|
| 87 |
text-align: left;
|
| 88 |
}
|
| 89 |
|
|
@@ -115,14 +115,15 @@ h1 .italic {
|
|
| 115 |
background: rgba(255, 255, 255, 0.03);
|
| 116 |
backdrop-filter: blur(15px);
|
| 117 |
border: 1px solid rgba(255, 255, 255, 0.05);
|
| 118 |
-
padding: clamp(
|
| 119 |
-
margin:
|
| 120 |
width: 100%;
|
| 121 |
box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
|
|
|
|
| 122 |
}
|
| 123 |
|
| 124 |
.form-group {
|
| 125 |
-
margin-bottom:
|
| 126 |
}
|
| 127 |
|
| 128 |
label {
|
|
@@ -276,11 +277,34 @@ input[type="file"]:hover::file-selector-button {
|
|
| 276 |
.table-wrapper {
|
| 277 |
width: 100%;
|
| 278 |
overflow-x: auto;
|
| 279 |
-
|
|
|
|
| 280 |
background: rgba(255, 255, 255, 0.03);
|
| 281 |
backdrop-filter: blur(10px);
|
| 282 |
border: 1px solid rgba(255, 255, 255, 0.08);
|
| 283 |
border-radius: 4px;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 284 |
}
|
| 285 |
|
| 286 |
table {
|
|
@@ -573,10 +597,34 @@ td {
|
|
| 573 |
}
|
| 574 |
}
|
| 575 |
|
| 576 |
-
/*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 577 |
.flush-section {
|
| 578 |
-
margin-top:
|
| 579 |
-
padding-top:
|
| 580 |
border-top: 1px solid rgba(255, 255, 255, 0.05);
|
| 581 |
}
|
| 582 |
|
|
|
|
| 51 |
position: relative;
|
| 52 |
z-index: 20;
|
| 53 |
width: 100%;
|
| 54 |
+
max-width: 1300px;
|
| 55 |
margin: 0 auto;
|
| 56 |
+
padding: 1rem 2rem;
|
| 57 |
display: flex;
|
| 58 |
flex-direction: column;
|
| 59 |
min-height: 100vh;
|
|
|
|
| 83 |
|
| 84 |
/* Typography */
|
| 85 |
header {
|
| 86 |
+
margin: 1.5rem 0;
|
| 87 |
text-align: left;
|
| 88 |
}
|
| 89 |
|
|
|
|
| 115 |
background: rgba(255, 255, 255, 0.03);
|
| 116 |
backdrop-filter: blur(15px);
|
| 117 |
border: 1px solid rgba(255, 255, 255, 0.05);
|
| 118 |
+
padding: clamp(1.5rem, 3vw, 2.5rem);
|
| 119 |
+
margin: 1rem 0;
|
| 120 |
width: 100%;
|
| 121 |
box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
|
| 122 |
+
border-radius: 8px;
|
| 123 |
}
|
| 124 |
|
| 125 |
.form-group {
|
| 126 |
+
margin-bottom: 1.5rem;
|
| 127 |
}
|
| 128 |
|
| 129 |
label {
|
|
|
|
| 277 |
.table-wrapper {
|
| 278 |
width: 100%;
|
| 279 |
overflow-x: auto;
|
| 280 |
+
overflow-y: auto;
|
| 281 |
+
max-height: 500px;
|
| 282 |
background: rgba(255, 255, 255, 0.03);
|
| 283 |
backdrop-filter: blur(10px);
|
| 284 |
border: 1px solid rgba(255, 255, 255, 0.08);
|
| 285 |
border-radius: 4px;
|
| 286 |
+
scrollbar-width: thin;
|
| 287 |
+
scrollbar-color: var(--secondary-color) transparent;
|
| 288 |
+
position: relative;
|
| 289 |
+
mask-image: linear-gradient(to bottom, black 90%, transparent 100%);
|
| 290 |
+
-webkit-mask-image: linear-gradient(to bottom, black 90%, transparent 100%);
|
| 291 |
+
}
|
| 292 |
+
|
| 293 |
+
/* Smart indicating effect: show more contrast on inner content */
|
| 294 |
+
.table-wrapper table {
|
| 295 |
+
position: relative;
|
| 296 |
+
z-index: 1;
|
| 297 |
+
}
|
| 298 |
+
|
| 299 |
+
.table-wrapper::-webkit-scrollbar {
|
| 300 |
+
width: 4px;
|
| 301 |
+
height: 4px;
|
| 302 |
+
}
|
| 303 |
+
|
| 304 |
+
.table-wrapper::-webkit-scrollbar-thumb {
|
| 305 |
+
background: var(--secondary-color);
|
| 306 |
+
border-radius: 10px;
|
| 307 |
+
box-shadow: 0 0 10px var(--secondary-color);
|
| 308 |
}
|
| 309 |
|
| 310 |
table {
|
|
|
|
| 597 |
}
|
| 598 |
}
|
| 599 |
|
| 600 |
+
/* Dashboard Layout */
|
| 601 |
+
.report-grid {
|
| 602 |
+
display: grid;
|
| 603 |
+
grid-template-columns: 1fr;
|
| 604 |
+
gap: 2rem;
|
| 605 |
+
}
|
| 606 |
+
|
| 607 |
+
@media (min-width: 1100px) {
|
| 608 |
+
.report-grid {
|
| 609 |
+
grid-template-columns: 1fr 400px;
|
| 610 |
+
}
|
| 611 |
+
|
| 612 |
+
.sticky-side {
|
| 613 |
+
position: sticky;
|
| 614 |
+
top: 2rem;
|
| 615 |
+
height: min-content;
|
| 616 |
+
}
|
| 617 |
+
}
|
| 618 |
+
|
| 619 |
+
.scroll-card {
|
| 620 |
+
height: 100%;
|
| 621 |
+
display: flex;
|
| 622 |
+
flex-direction: column;
|
| 623 |
+
}
|
| 624 |
+
|
| 625 |
.flush-section {
|
| 626 |
+
margin-top: 2rem;
|
| 627 |
+
padding-top: 1.5rem;
|
| 628 |
border-top: 1px solid rgba(255, 255, 255, 0.05);
|
| 629 |
}
|
| 630 |
|
templates/report.html
CHANGED
|
@@ -30,122 +30,103 @@
|
|
| 30 |
</header>
|
| 31 |
|
| 32 |
{% if metrics %}
|
| 33 |
-
<
|
| 34 |
-
<
|
| 35 |
-
|
| 36 |
-
|
| 37 |
-
<
|
| 38 |
-
|
| 39 |
-
|
| 40 |
-
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
|
| 44 |
-
|
| 45 |
-
|
| 46 |
-
|
| 47 |
-
|
| 48 |
-
|
| 49 |
-
|
| 50 |
-
|
| 51 |
-
|
| 52 |
-
|
| 53 |
-
<
|
| 54 |
-
<span class="metric-label">PRECISION</span>
|
| 55 |
-
<p class="metric-note">Ability of the classifier not to label a negative sample as positive.</p>
|
| 56 |
-
</div>
|
| 57 |
-
<div class="metric-item">
|
| 58 |
-
<span class="metric-value">{{ metrics.recall|round(4) }}</span>
|
| 59 |
-
<span class="metric-label">RECALL</span>
|
| 60 |
-
<p class="metric-note">Ability of the classifier to find all positive samples.</p>
|
| 61 |
-
</div>
|
| 62 |
-
</div>
|
| 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 |
-
</tr>
|
| 91 |
-
{% endfor %}
|
| 92 |
-
</tbody>
|
| 93 |
-
</table>
|
| 94 |
</div>
|
| 95 |
|
| 96 |
-
<div class="
|
| 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 |
-
<tbody>
|
| 136 |
-
{% for item in metrics.class_metrics %}
|
| 137 |
-
<tr>
|
| 138 |
-
<td style="font-weight: 700; color: var(--secondary-color);">{{ item.label }}</td>
|
| 139 |
-
<td>{{ item.precision }}</td>
|
| 140 |
-
<td>{{ item.recall }}</td>
|
| 141 |
-
<td>{{ item.f1 }}</td>
|
| 142 |
-
<td style="opacity: 0.5;">{{ item.support }}</td>
|
| 143 |
-
</tr>
|
| 144 |
-
{% endfor %}
|
| 145 |
-
</tbody>
|
| 146 |
-
</table>
|
| 147 |
</div>
|
| 148 |
-
</
|
| 149 |
{% endif %}
|
| 150 |
|
| 151 |
<section class="upload-card" style="margin-top: 4rem; padding: 2.5rem; border-radius: 8px;">
|
|
|
|
| 30 |
</header>
|
| 31 |
|
| 32 |
{% if metrics %}
|
| 33 |
+
<div class="report-grid">
|
| 34 |
+
<div class="scroll-card">
|
| 35 |
+
<section class="upload-card" style="margin: 0; padding: 2rem;">
|
| 36 |
+
<p class="label-mini">Performance Summary</p>
|
| 37 |
+
<div class="metrics-grid">
|
| 38 |
+
<div class="metric-item">
|
| 39 |
+
<span class="metric-value">{{ (metrics.accuracy * 100)|round(2) }}%</span>
|
| 40 |
+
<span class="metric-label">ACCURACY</span>
|
| 41 |
+
<p class="metric-note">Overall correctness.</p>
|
| 42 |
+
</div>
|
| 43 |
+
<div class="metric-item">
|
| 44 |
+
<span class="metric-value">{{ metrics.f1|round(4) }}</span>
|
| 45 |
+
<span class="metric-label">WEIGHTED F1</span>
|
| 46 |
+
<p class="metric-note">Balanced score (weighted).</p>
|
| 47 |
+
</div>
|
| 48 |
+
<div class="metric-item">
|
| 49 |
+
<span class="metric-value">{{ metrics.macro_f1|round(4) }}</span>
|
| 50 |
+
<span class="metric-label">MACRO F1</span>
|
| 51 |
+
<p class="metric-note">Unweighted average score.</p>
|
| 52 |
+
</div>
|
| 53 |
+
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 54 |
|
| 55 |
+
<p class="label-mini" style="margin-top: 2rem;">Class-Wise Decomposition</p>
|
| 56 |
+
<div class="table-wrapper" style="max-height: 400px;">
|
| 57 |
+
<table>
|
| 58 |
+
<thead>
|
| 59 |
+
<tr>
|
| 60 |
+
<th>Grade</th>
|
| 61 |
+
<th>Prec.</th>
|
| 62 |
+
<th>Recall</th>
|
| 63 |
+
<th>F1</th>
|
| 64 |
+
<th>Sup.</th>
|
| 65 |
+
</tr>
|
| 66 |
+
</thead>
|
| 67 |
+
<tbody>
|
| 68 |
+
{% for item in metrics.class_metrics %}
|
| 69 |
+
<tr>
|
| 70 |
+
<td style="font-weight: 700; color: var(--secondary-color);">{{ item.label }}</td>
|
| 71 |
+
<td>{{ item.precision }}</td>
|
| 72 |
+
<td>{{ item.recall }}</td>
|
| 73 |
+
<td>{{ item.f1 }}</td>
|
| 74 |
+
<td style="opacity: 0.5;">{{ item.support }}</td>
|
| 75 |
+
</tr>
|
| 76 |
+
{% endfor %}
|
| 77 |
+
</tbody>
|
| 78 |
+
</table>
|
| 79 |
+
</div>
|
| 80 |
+
</section>
|
|
|
|
|
|
|
|
|
|
|
|
|
| 81 |
</div>
|
| 82 |
|
| 83 |
+
<div class="sticky-side">
|
| 84 |
+
<section class="upload-card" style="margin: 0; padding: 2rem;">
|
| 85 |
+
<p class="label-mini">Confusion Matrix</p>
|
| 86 |
+
<div class="cm-container" style="margin-top: 1rem;">
|
| 87 |
+
<table class="cm-table" style="width: 100%;">
|
| 88 |
+
<thead>
|
| 89 |
+
<tr class="cm-label-row">
|
| 90 |
+
<th>A\P</th>
|
| 91 |
+
{% for label in metrics.confusion_matrix.labels %}
|
| 92 |
+
<th style="min-width: 30px; padding: 0.5rem;">{{ label }}</th>
|
| 93 |
+
{% endfor %}
|
| 94 |
+
</tr>
|
| 95 |
+
</thead>
|
| 96 |
+
<tbody>
|
| 97 |
+
{% for row_idx in range(metrics.confusion_matrix.matrix|length) %}
|
| 98 |
+
<tr>
|
| 99 |
+
<td
|
| 100 |
+
style="background: rgba(255,255,255,0.03); font-weight: 700; color: var(--secondary-color); padding: 0.5rem;">
|
| 101 |
+
{{ metrics.confusion_matrix.labels[row_idx] }}
|
| 102 |
+
</td>
|
| 103 |
+
{% for col_idx in range(metrics.confusion_matrix.matrix[row_idx]|length) %}
|
| 104 |
+
{% set val = metrics.confusion_matrix.matrix[row_idx][col_idx] %}
|
| 105 |
+
<td class="cm-value {% if row_idx == col_idx %}cm-match{% endif %} {% if val == 0 %}cm-dimmed{% endif %}"
|
| 106 |
+
style="padding: 0.5rem;">
|
| 107 |
+
{{ val }}
|
| 108 |
+
</td>
|
| 109 |
+
{% endfor %}
|
| 110 |
+
</tr>
|
| 111 |
+
{% endfor %}
|
| 112 |
+
</tbody>
|
| 113 |
+
</table>
|
| 114 |
+
</div>
|
| 115 |
|
| 116 |
+
<div class="summary-metrics"
|
| 117 |
+
style="margin-top: 2rem; display: grid; grid-template-columns: 1fr 1fr; gap: 1rem;">
|
| 118 |
+
<div class="summary-card" style="padding: 1rem;">
|
| 119 |
+
<span class="lbl">Macro F1</span>
|
| 120 |
+
<span class="val" style="font-size: 1.5rem;">{{ metrics.macro_f1|round(4) }}</span>
|
| 121 |
+
</div>
|
| 122 |
+
<div class="summary-card" style="padding: 1rem;">
|
| 123 |
+
<span class="lbl">Accuracy</span>
|
| 124 |
+
<span class="val" style="font-size: 1.5rem;">{{ (metrics.accuracy * 100)|round(0) }}%</span>
|
| 125 |
+
</div>
|
| 126 |
+
</div>
|
| 127 |
+
</section>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 128 |
</div>
|
| 129 |
+
</div>
|
| 130 |
{% endif %}
|
| 131 |
|
| 132 |
<section class="upload-card" style="margin-top: 4rem; padding: 2.5rem; border-radius: 8px;">
|