Spaces:
Running
Running
imporvements..
Browse files- frontend/initial.html +38 -29
- frontend/js/initial.js +6 -2
- frontend/js/vehicles.js +12 -6
- frontend/vehicles.html +54 -67
frontend/initial.html
CHANGED
|
@@ -48,16 +48,25 @@
|
|
| 48 |
<span class="block sm:inline">Intelligence</span>
|
| 49 |
</h1>
|
| 50 |
<p class="font-bold mb-8 text-sm uppercase tracking-[0.2em] flex items-center justify-center sm:justify-start" style="color:#a89f97">
|
| 51 |
-
<span class="core-badge px-3 py-1 rounded-full text-[10px] mr-3">
|
| 52 |
-
|
| 53 |
</p>
|
| 54 |
<ul class="space-y-4 xl:space-y-5 text-base xl:text-lg font-medium" style="color:#a89f97">
|
| 55 |
-
<li class="flex items-center"><i class="fa-solid fa-check mr-3 md:mr-5 text-xl" style="color:#c89a6c"></i>
|
| 56 |
-
<li class="flex items-center"><i class="fa-solid fa-check mr-3 md:mr-5 text-xl" style="color:#c89a6c"></i>
|
| 57 |
-
<li class="flex items-center"><i class="fa-solid fa-check mr-3 md:mr-5 text-xl" style="color:#c89a6c"></i>
|
| 58 |
-
<li class="flex items-center"><i class="fa-solid fa-check mr-3 md:mr-5 text-xl" style="color:#c89a6c"></i>
|
| 59 |
-
<li class="flex items-center"><i class="fa-solid fa-check mr-3 md:mr-5 text-xl" style="color:#c89a6c"></i>
|
| 60 |
</ul>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 61 |
</div>
|
| 62 |
|
| 63 |
<div class="step-card-section lg:col-span-5 flex flex-col justify-center w-full max-w-[32rem] mx-auto h-auto md:h-[480px] lg:h-[520px] mb-12 lg:mb-0">
|
|
@@ -65,15 +74,15 @@
|
|
| 65 |
<!-- STEP: Modules -->
|
| 66 |
<div id="step-modules" class="w-full flex flex-col fade-in overflow-y-auto">
|
| 67 |
<h2 class="text-3xl font-bold mb-2 text-center" style="color:#f0ece6">UrbanFlow</h2>
|
| 68 |
-
<p class="text-[13px] font-medium mb-8 text-center" style="color:#a89f97">
|
| 69 |
<div class="flex justify-center w-full">
|
| 70 |
<div onclick="showStep('upload')"
|
| 71 |
class="group relative border-2 rounded-[2rem] p-8 cursor-pointer hover:-translate-y-1 transition-all duration-300 text-center max-w-sm w-full traffic-dynamics-card">
|
| 72 |
<div class="absolute top-4 right-6 text-[9px] font-bold px-2.5 py-1 rounded-full uppercase tracking-wider"
|
| 73 |
-
style="background:#c89a6c;color:#000">
|
| 74 |
<i class="fa-solid fa-car-side text-4xl mb-4 block mx-auto" style="color:#c89a6c"></i>
|
| 75 |
<h3 class="font-bold text-lg mb-2 leading-tight" style="color:#f0ece6">Traffic <br>Dynamics</h3>
|
| 76 |
-
<p class="text-[10px] font-medium leading-relaxed" style="color:#a89f97">Vehicle counting, classification, and flow analysis
|
| 77 |
</div>
|
| 78 |
</div>
|
| 79 |
</div>
|
|
@@ -84,13 +93,13 @@
|
|
| 84 |
class="text-[#a89f97] hover:text-white hover:underline transition flex items-center text-xs font-bold uppercase tracking-widest mb-6 w-fit">
|
| 85 |
<i class="fa-solid fa-arrow-left mr-2"></i> Back
|
| 86 |
</button>
|
| 87 |
-
<h2 class="text-3xl font-bold mb-2 text-center" style="color:#f0ece6">
|
| 88 |
-
<p class="text-[13px] font-medium mb-8 text-center" style="color:#a89f97">Submit
|
| 89 |
<input id="file-input" type="file" accept="video/*" class="hidden">
|
| 90 |
<div id="dropzone" onclick="document.getElementById('file-input').click()"
|
| 91 |
class="border border-dashed border-neutral-700 rounded-[2rem] p-8 md:p-12 flex flex-col items-center justify-center cursor-pointer transition-all duration-300 group">
|
| 92 |
<i class="fa-solid fa-arrow-up-from-bracket text-4xl mb-5 block mx-auto transition" style="color:#a89f97"></i>
|
| 93 |
-
<span class="font-semibold text-lg mb-2 text-center block" style="color:#f0ece6">Drop or select a video
|
| 94 |
<span class="text-[10px] font-bold uppercase tracking-widest text-center block" style="color:#a89f97">Any standard video format accepted</span>
|
| 95 |
</div>
|
| 96 |
<div id="upload-progress-container" class="hidden mt-10 w-full">
|
|
@@ -125,7 +134,7 @@
|
|
| 125 |
</button>
|
| 126 |
<button onclick="resetCanvas()"
|
| 127 |
class="text-[10px] font-bold uppercase tracking-widest text-slate-500 hover:text-white transition px-4 py-2 mt-2"
|
| 128 |
-
style="background:none;border:none;">Reset
|
| 129 |
</div>
|
| 130 |
</div>
|
| 131 |
|
|
@@ -185,9 +194,9 @@
|
|
| 185 |
<h2 style="color:#f0ece6;font-size:1.1rem;font-weight:700;margin-bottom:8px">Privacy Policy</h2>
|
| 186 |
<p style="color:#a89f97;font-size:11px;margin-bottom:20px">We keep this simple and honest.</p>
|
| 187 |
<ul style="color:#a89f97;font-size:11px;line-height:1.9;padding-left:16px;list-style:disc;text-align:left">
|
| 188 |
-
<li>This is a <strong style="color:#f0ece6">public demo</strong> hosted on Hugging Face Spaces. It is not a production service.</li>
|
| 189 |
-
<li>UrbanFlow provides an estimated accuracy of ±5–8% on dense mixed-traffic footage. Results may vary
|
| 190 |
-
<li>Footage you submit is processed
|
| 191 |
<li>We do not use your footage to train models, sell it, or share it with any third party.</li>
|
| 192 |
<li>Reports and annotated videos are generated temporarily and delivered to your device. We do not retain copies.</li>
|
| 193 |
<li>We do not use advertising cookies, behavioral tracking, or analytics scripts on this platform.</li>
|
|
@@ -206,28 +215,28 @@
|
|
| 206 |
<button onclick="closeAppModal('termsModal')"
|
| 207 |
style="position:absolute;top:16px;right:18px;background:none;border:none;color:#a89f97;font-size:18px;cursor:pointer">×</button>
|
| 208 |
<h2 style="color:#f0ece6;font-size:1.1rem;font-weight:700;margin-bottom:8px">Terms & Conditions</h2>
|
| 209 |
-
<p style="color:#a89f97;font-size:11px;margin-bottom:20px">By using this
|
| 210 |
following terms.</p>
|
| 211 |
<p style="color:#c89a6c;font-size:11px;font-weight:700;margin-bottom:6px;text-align:left">You can:</p>
|
| 212 |
<ul
|
| 213 |
style="color:#a89f97;font-size:11px;line-height:1.9;padding-left:16px;list-style:disc;margin-bottom:16px;text-align:left">
|
| 214 |
-
<li>Use this
|
| 215 |
<li>Export reports, annotated video outputs, and data artifacts to your own device.</li>
|
| 216 |
<li>Share feedback, feature requests, or questions with us at <strong style="color:#c89a6c">support.urbanflow365@gmail.com</strong>.</li>
|
| 217 |
-
<li>Reference this
|
| 218 |
</ul>
|
| 219 |
<p style="color:#c89a6c;font-size:11px;font-weight:700;margin-bottom:6px;text-align:left">You cannot:</p>
|
| 220 |
<ul
|
| 221 |
style="color:#a89f97;font-size:11px;line-height:1.9;padding-left:16px;list-style:disc;margin-bottom:16px;text-align:left">
|
| 222 |
<li>Commercially redistribute outputs or present them as your own product’s capability.</li>
|
| 223 |
<li>Reverse-engineer, extract, or attempt to replicate the underlying model or processing pipeline.</li>
|
| 224 |
-
<li>Use the
|
| 225 |
-
<li>Misrepresent
|
| 226 |
</ul>
|
| 227 |
-
<p style="color:#a89f97;font-size:11px;text-align:left">This
|
| 228 |
-
UrbanFlow provides an estimated accuracy of ±5–8% on dense mixed-traffic footage. For research
|
| 229 |
<p style="color:#a89f97;font-size:11px;text-align:left">Outputs are not intended for operational, regulatory, or safety-critical use. This is an early-stage research project, not a commercial product.</p>
|
| 230 |
-
<p style="color:#555;font-size:10px;margin-top:16px;text-align:left">
|
| 231 |
style="color:#c89a6c">support.urbanflow365@gmail.com</strong></p>
|
| 232 |
</div>
|
| 233 |
</div>
|
|
@@ -238,17 +247,17 @@
|
|
| 238 |
<div class="onboard-step active" data-step="0">
|
| 239 |
<i class="fa-solid fa-cloud-arrow-up text-4xl mb-4" style="color:var(--cocoa-l)"></i>
|
| 240 |
<h3 class="text-lg font-bold mb-2" style="color:#f0ece6">Upload a Video</h3>
|
| 241 |
-
<p class="text-xs" style="color:#777;line-height:1.7">
|
| 242 |
</div>
|
| 243 |
<div class="onboard-step" data-step="1">
|
| 244 |
<i class="fa-solid fa-draw-polygon text-4xl mb-4" style="color:var(--cocoa-l)"></i>
|
| 245 |
-
<h3 class="text-lg font-bold mb-2" style="color:#f0ece6">
|
| 246 |
-
<p class="text-xs" style="color:#777;line-height:1.7">
|
| 247 |
</div>
|
| 248 |
<div class="onboard-step" data-step="2">
|
| 249 |
<i class="fa-solid fa-chart-line text-4xl mb-4" style="color:var(--cocoa-l)"></i>
|
| 250 |
<h3 class="text-lg font-bold mb-2" style="color:#f0ece6">Review Analytics & Export</h3>
|
| 251 |
-
<p class="text-xs" style="color:#777;line-height:1.7">
|
| 252 |
</div>
|
| 253 |
<div class="onboard-dots">
|
| 254 |
<span class="onboard-dot active"></span>
|
|
|
|
| 48 |
<span class="block sm:inline">Intelligence</span>
|
| 49 |
</h1>
|
| 50 |
<p class="font-bold mb-8 text-sm uppercase tracking-[0.2em] flex items-center justify-center sm:justify-start" style="color:#a89f97">
|
| 51 |
+
<span class="core-badge px-3 py-1 rounded-full text-[10px] mr-3">Beta</span>
|
| 52 |
+
MVP for traffic intelligence
|
| 53 |
</p>
|
| 54 |
<ul class="space-y-4 xl:space-y-5 text-base xl:text-lg font-medium" style="color:#a89f97">
|
| 55 |
+
<li class="flex items-center"><i class="fa-solid fa-check mr-3 md:mr-5 text-xl" style="color:#c89a6c"></i> Works with CCTV, webcam or mobile recorded clips</li>
|
| 56 |
+
<li class="flex items-center"><i class="fa-solid fa-check mr-3 md:mr-5 text-xl" style="color:#c89a6c"></i> Your Data is secure & private</li>
|
| 57 |
+
<li class="flex items-center"><i class="fa-solid fa-check mr-3 md:mr-5 text-xl" style="color:#c89a6c"></i> Built for Indian Roads, conditions & traffic patterns</li>
|
| 58 |
+
<li class="flex items-center"><i class="fa-solid fa-check mr-3 md:mr-5 text-xl" style="color:#c89a6c"></i> No Hardware Installation; rapid & scalable analysis.</li>
|
| 59 |
+
<li class="flex items-center"><i class="fa-solid fa-check mr-3 md:mr-5 text-xl" style="color:#c89a6c"></i> Tested on real field conditions</li>
|
| 60 |
</ul>
|
| 61 |
+
|
| 62 |
+
<div class="mt-10 flex justify-center sm:justify-start">
|
| 63 |
+
<button onclick="openOnboarding()" class="pr-6 pl-2 py-2 rounded-full transition-all active:scale-95 flex items-center gap-4 hover:border-[#c89a6c] shadow-lg group cursor-pointer" style="background:#050505; border: 1px solid #1a1a1a">
|
| 64 |
+
<div class="w-8 h-8 rounded-full flex items-center justify-center transition-transform group-hover:scale-110" style="background:#c89a6c; color:#000">
|
| 65 |
+
<i class="fa-solid fa-play text-[10px] ml-0.5"></i>
|
| 66 |
+
</div>
|
| 67 |
+
<span class="uppercase tracking-widest text-[11px] font-bold" style="color:#c89a6c">Experience Guided Tour</span>
|
| 68 |
+
</button>
|
| 69 |
+
</div>
|
| 70 |
</div>
|
| 71 |
|
| 72 |
<div class="step-card-section lg:col-span-5 flex flex-col justify-center w-full max-w-[32rem] mx-auto h-auto md:h-[480px] lg:h-[520px] mb-12 lg:mb-0">
|
|
|
|
| 74 |
<!-- STEP: Modules -->
|
| 75 |
<div id="step-modules" class="w-full flex flex-col fade-in overflow-y-auto">
|
| 76 |
<h2 class="text-3xl font-bold mb-2 text-center" style="color:#f0ece6">UrbanFlow</h2>
|
| 77 |
+
<p class="text-[13px] font-medium mb-8 text-center" style="color:#a89f97">Proceed to analysis</p>
|
| 78 |
<div class="flex justify-center w-full">
|
| 79 |
<div onclick="showStep('upload')"
|
| 80 |
class="group relative border-2 rounded-[2rem] p-8 cursor-pointer hover:-translate-y-1 transition-all duration-300 text-center max-w-sm w-full traffic-dynamics-card">
|
| 81 |
<div class="absolute top-4 right-6 text-[9px] font-bold px-2.5 py-1 rounded-full uppercase tracking-wider"
|
| 82 |
+
style="background:#c89a6c;color:#000">BETA</div>
|
| 83 |
<i class="fa-solid fa-car-side text-4xl mb-4 block mx-auto" style="color:#c89a6c"></i>
|
| 84 |
<h3 class="font-bold text-lg mb-2 leading-tight" style="color:#f0ece6">Traffic <br>Dynamics</h3>
|
| 85 |
+
<p class="text-[10px] font-medium leading-relaxed" style="color:#a89f97">Vehicle counting, classification, and flow analysis</p>
|
| 86 |
</div>
|
| 87 |
</div>
|
| 88 |
</div>
|
|
|
|
| 93 |
class="text-[#a89f97] hover:text-white hover:underline transition flex items-center text-xs font-bold uppercase tracking-widest mb-6 w-fit">
|
| 94 |
<i class="fa-solid fa-arrow-left mr-2"></i> Back
|
| 95 |
</button>
|
| 96 |
+
<h2 class="text-3xl font-bold mb-2 text-center" style="color:#f0ece6">Media</h2>
|
| 97 |
+
<p class="text-[13px] font-medium mb-8 text-center" style="color:#a89f97">Submit an appropriate video footage</p>
|
| 98 |
<input id="file-input" type="file" accept="video/*" class="hidden">
|
| 99 |
<div id="dropzone" onclick="document.getElementById('file-input').click()"
|
| 100 |
class="border border-dashed border-neutral-700 rounded-[2rem] p-8 md:p-12 flex flex-col items-center justify-center cursor-pointer transition-all duration-300 group">
|
| 101 |
<i class="fa-solid fa-arrow-up-from-bracket text-4xl mb-5 block mx-auto transition" style="color:#a89f97"></i>
|
| 102 |
+
<span class="font-semibold text-lg mb-2 text-center block" style="color:#f0ece6">Drop or select a video</span>
|
| 103 |
<span class="text-[10px] font-bold uppercase tracking-widest text-center block" style="color:#a89f97">Any standard video format accepted</span>
|
| 104 |
</div>
|
| 105 |
<div id="upload-progress-container" class="hidden mt-10 w-full">
|
|
|
|
| 134 |
</button>
|
| 135 |
<button onclick="resetCanvas()"
|
| 136 |
class="text-[10px] font-bold uppercase tracking-widest text-slate-500 hover:text-white transition px-4 py-2 mt-2"
|
| 137 |
+
style="background:none;border:none;">Reset </button>
|
| 138 |
</div>
|
| 139 |
</div>
|
| 140 |
|
|
|
|
| 194 |
<h2 style="color:#f0ece6;font-size:1.1rem;font-weight:700;margin-bottom:8px">Privacy Policy</h2>
|
| 195 |
<p style="color:#a89f97;font-size:11px;margin-bottom:20px">We keep this simple and honest.</p>
|
| 196 |
<ul style="color:#a89f97;font-size:11px;line-height:1.9;padding-left:16px;list-style:disc;text-align:left">
|
| 197 |
+
<li>This is a <strong style="color:#f0ece6">public demo</strong> hosted on Hugging Face Spaces. It is not yet a complete production service.</li>
|
| 198 |
+
<li>UrbanFlow provides an estimated accuracy of ±5–8% on dense mixed-traffic footage. Results may vary across runs due to the nature of real-time frame-by-frame inference.</li>
|
| 199 |
+
<li>Footage you submit is processed with minimal delay and <strong style="color:#f0ece6">discarded immediately</strong> after the session ends. Nothing is stored on our servers.</li>
|
| 200 |
<li>We do not use your footage to train models, sell it, or share it with any third party.</li>
|
| 201 |
<li>Reports and annotated videos are generated temporarily and delivered to your device. We do not retain copies.</li>
|
| 202 |
<li>We do not use advertising cookies, behavioral tracking, or analytics scripts on this platform.</li>
|
|
|
|
| 215 |
<button onclick="closeAppModal('termsModal')"
|
| 216 |
style="position:absolute;top:16px;right:18px;background:none;border:none;color:#a89f97;font-size:18px;cursor:pointer">×</button>
|
| 217 |
<h2 style="color:#f0ece6;font-size:1.1rem;font-weight:700;margin-bottom:8px">Terms & Conditions</h2>
|
| 218 |
+
<p style="color:#a89f97;font-size:11px;margin-bottom:20px">By using this application, you agree to the
|
| 219 |
following terms.</p>
|
| 220 |
<p style="color:#c89a6c;font-size:11px;font-weight:700;margin-bottom:6px;text-align:left">You can:</p>
|
| 221 |
<ul
|
| 222 |
style="color:#a89f97;font-size:11px;line-height:1.9;padding-left:16px;list-style:disc;margin-bottom:16px;text-align:left">
|
| 223 |
+
<li>Use this application to evaluate UrbanFlow’s traffic detection and analytics capabilities.</li>
|
| 224 |
<li>Export reports, annotated video outputs, and data artifacts to your own device.</li>
|
| 225 |
<li>Share feedback, feature requests, or questions with us at <strong style="color:#c89a6c">support.urbanflow365@gmail.com</strong>.</li>
|
| 226 |
+
<li>Reference this application in research or internal evaluation, with proper attribution.</li>
|
| 227 |
</ul>
|
| 228 |
<p style="color:#c89a6c;font-size:11px;font-weight:700;margin-bottom:6px;text-align:left">You cannot:</p>
|
| 229 |
<ul
|
| 230 |
style="color:#a89f97;font-size:11px;line-height:1.9;padding-left:16px;list-style:disc;margin-bottom:16px;text-align:left">
|
| 231 |
<li>Commercially redistribute outputs or present them as your own product’s capability.</li>
|
| 232 |
<li>Reverse-engineer, extract, or attempt to replicate the underlying model or processing pipeline.</li>
|
| 233 |
+
<li>Use the application for unlawful, harmful, or safety-critical operational purposes.</li>
|
| 234 |
+
<li>Misrepresent outputs as certified or regulatory-grade traffic data.</li>
|
| 235 |
</ul>
|
| 236 |
+
<p style="color:#a89f97;font-size:11px;text-align:left">This application is provided as-is for <strong style="color:#f0ece6">demonstration and evaluation purposes only</strong>.
|
| 237 |
+
UrbanFlow provides an estimated accuracy of ±5–8% on dense mixed-traffic footage. For research use, we recommend processing the same video 2–3 times and taking the average count.</p>
|
| 238 |
<p style="color:#a89f97;font-size:11px;text-align:left">Outputs are not intended for operational, regulatory, or safety-critical use. This is an early-stage research project, not a commercial product.</p>
|
| 239 |
+
<p style="color:#555;font-size:10px;margin-top:16px;text-align:left">For any queries: <strong
|
| 240 |
style="color:#c89a6c">support.urbanflow365@gmail.com</strong></p>
|
| 241 |
</div>
|
| 242 |
</div>
|
|
|
|
| 247 |
<div class="onboard-step active" data-step="0">
|
| 248 |
<i class="fa-solid fa-cloud-arrow-up text-4xl mb-4" style="color:var(--cocoa-l)"></i>
|
| 249 |
<h3 class="text-lg font-bold mb-2" style="color:#f0ece6">Upload a Video</h3>
|
| 250 |
+
<p class="text-xs" style="color:#777;line-height:1.7">Upload a suitable video clip from a traffic camera.</p>
|
| 251 |
</div>
|
| 252 |
<div class="onboard-step" data-step="1">
|
| 253 |
<i class="fa-solid fa-draw-polygon text-4xl mb-4" style="color:var(--cocoa-l)"></i>
|
| 254 |
+
<h3 class="text-lg font-bold mb-2" style="color:#f0ece6">Draw a Counting Line</h3>
|
| 255 |
+
<p class="text-xs" style="color:#777;line-height:1.7">Draw two points to define a counting line. Vehicles crossing this line will be counted & classified.</p>
|
| 256 |
</div>
|
| 257 |
<div class="onboard-step" data-step="2">
|
| 258 |
<i class="fa-solid fa-chart-line text-4xl mb-4" style="color:var(--cocoa-l)"></i>
|
| 259 |
<h3 class="text-lg font-bold mb-2" style="color:#f0ece6">Review Analytics & Export</h3>
|
| 260 |
+
<p class="text-xs" style="color:#777;line-height:1.7">Track insights as they update during processing. Download reports when ready.</p>
|
| 261 |
</div>
|
| 262 |
<div class="onboard-dots">
|
| 263 |
<span class="onboard-dot active"></span>
|
frontend/js/initial.js
CHANGED
|
@@ -308,10 +308,14 @@ function closeOnboarding() {
|
|
| 308 |
if (overlay) overlay.style.display = 'none';
|
| 309 |
}
|
| 310 |
|
| 311 |
-
|
| 312 |
const onboard = document.getElementById('onboard-overlay');
|
| 313 |
if (onboard) {
|
|
|
|
|
|
|
|
|
|
|
|
|
| 314 |
onboard.style.display = 'flex';
|
| 315 |
triggerIconPulse();
|
| 316 |
}
|
| 317 |
-
}
|
|
|
|
| 308 |
if (overlay) overlay.style.display = 'none';
|
| 309 |
}
|
| 310 |
|
| 311 |
+
function openOnboarding() {
|
| 312 |
const onboard = document.getElementById('onboard-overlay');
|
| 313 |
if (onboard) {
|
| 314 |
+
_obStep = 0;
|
| 315 |
+
document.querySelectorAll('.onboard-step').forEach((s, i) => s.classList.toggle('active', i === _obStep));
|
| 316 |
+
document.querySelectorAll('.onboard-dot').forEach((d, i) => d.classList.toggle('active', i === _obStep));
|
| 317 |
+
document.getElementById('onboard-next').innerText = 'Next';
|
| 318 |
onboard.style.display = 'flex';
|
| 319 |
triggerIconPulse();
|
| 320 |
}
|
| 321 |
+
}
|
frontend/js/vehicles.js
CHANGED
|
@@ -197,15 +197,19 @@ function switchTab(tab) {
|
|
| 197 |
|
| 198 |
// =========== Keyboard Shortcuts ===========
|
| 199 |
const TAB_KEYS = { '1': 'about', '2': 'overview', '3': 'run-details', '4': 'reports', '5': 'settings', '6': 'help', '7': 'feedback' };
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 200 |
document.addEventListener('keydown', function(e) {
|
| 201 |
if (e.target.tagName === 'INPUT' || e.target.tagName === 'TEXTAREA' || e.target.tagName === 'SELECT') return;
|
| 202 |
if (TAB_KEYS[e.key]) { switchTab(TAB_KEYS[e.key]); return; }
|
| 203 |
if (e.key === 'd' || e.key === 'D') {
|
| 204 |
-
|
| 205 |
-
if (vid) {
|
| 206 |
-
window.open(`bundle/${vid}`, '_blank');
|
| 207 |
-
showToast('Download started', 'success');
|
| 208 |
-
}
|
| 209 |
}
|
| 210 |
});
|
| 211 |
|
|
@@ -1113,6 +1117,8 @@ function switchTab(tab) {
|
|
| 1113 |
document.getElementById('post-process-cards').classList.remove('hidden');
|
| 1114 |
const grid = document.getElementById('reports-grid');
|
| 1115 |
grid.classList.remove('hidden');
|
|
|
|
|
|
|
| 1116 |
grid.innerHTML = '';
|
| 1117 |
|
| 1118 |
data.files.forEach(name => {
|
|
@@ -1241,7 +1247,7 @@ function switchTab(tab) {
|
|
| 1241 |
Want to try another video?
|
| 1242 |
</p>
|
| 1243 |
<p style="color:#a89f97;font-size:11px;margin:0">
|
| 1244 |
-
|
| 1245 |
</p>
|
| 1246 |
<div id="retry-bubble-arrow"></div>
|
| 1247 |
`;
|
|
|
|
| 197 |
|
| 198 |
// =========== Keyboard Shortcuts ===========
|
| 199 |
const TAB_KEYS = { '1': 'about', '2': 'overview', '3': 'run-details', '4': 'reports', '5': 'settings', '6': 'help', '7': 'feedback' };
|
| 200 |
+
function downloadArtifacts() {
|
| 201 |
+
const vid = document.body.dataset.lastVideoId;
|
| 202 |
+
if (vid) {
|
| 203 |
+
window.open(`bundle/${vid}`, '_blank');
|
| 204 |
+
showToast('Download started', 'success');
|
| 205 |
+
}
|
| 206 |
+
}
|
| 207 |
+
|
| 208 |
document.addEventListener('keydown', function(e) {
|
| 209 |
if (e.target.tagName === 'INPUT' || e.target.tagName === 'TEXTAREA' || e.target.tagName === 'SELECT') return;
|
| 210 |
if (TAB_KEYS[e.key]) { switchTab(TAB_KEYS[e.key]); return; }
|
| 211 |
if (e.key === 'd' || e.key === 'D') {
|
| 212 |
+
downloadArtifacts();
|
|
|
|
|
|
|
|
|
|
|
|
|
| 213 |
}
|
| 214 |
});
|
| 215 |
|
|
|
|
| 1117 |
document.getElementById('post-process-cards').classList.remove('hidden');
|
| 1118 |
const grid = document.getElementById('reports-grid');
|
| 1119 |
grid.classList.remove('hidden');
|
| 1120 |
+
const mobileBtn = document.getElementById('mobile-download-wrap');
|
| 1121 |
+
if (mobileBtn) mobileBtn.classList.remove('hidden');
|
| 1122 |
grid.innerHTML = '';
|
| 1123 |
|
| 1124 |
data.files.forEach(name => {
|
|
|
|
| 1247 |
Want to try another video?
|
| 1248 |
</p>
|
| 1249 |
<p style="color:#a89f97;font-size:11px;margin:0">
|
| 1250 |
+
Go to <b style="color:#f0ece6">⚙ Settings</b> & click 'Analyze again'
|
| 1251 |
</p>
|
| 1252 |
<div id="retry-bubble-arrow"></div>
|
| 1253 |
`;
|
frontend/vehicles.html
CHANGED
|
@@ -152,47 +152,45 @@
|
|
| 152 |
what gets built for production.
|
| 153 |
</p>
|
| 154 |
<p style="font-size:13px;color:#777">
|
| 155 |
-
The production system will support
|
| 156 |
-
|
| 157 |
-
This demo accepts video upload only.
|
| 158 |
</p>
|
| 159 |
</div>
|
| 160 |
|
| 161 |
<div class="grid grid-cols-2 gap-12 pt-8 text-left border-t max-w-5xl mx-auto"
|
| 162 |
style="border-color:#1a1a1a">
|
| 163 |
<div class="space-y-4">
|
| 164 |
-
<h4 class="font-bold text-[13px] uppercase tracking-wider" style="color:#f0ece6">What You Get
|
| 165 |
-
</h4>
|
| 166 |
<ul class="text-xs space-y-3 pl-1">
|
| 167 |
<li class="flex items-start gap-3"><i class="fa-solid fa-circle text-[5px] mt-1.5"
|
| 168 |
style="color:#c89a6c"></i>
|
| 169 |
-
<span>Class-wise vehicle counts
|
| 170 |
</li>
|
| 171 |
<li class="flex items-start gap-3"><i class="fa-solid fa-circle text-[5px] mt-1.5"
|
| 172 |
style="color:#c89a6c"></i>
|
| 173 |
-
<span>Directional
|
| 174 |
</li>
|
| 175 |
<li class="flex items-start gap-3"><i class="fa-solid fa-circle text-[5px] mt-1.5"
|
| 176 |
style="color:#c89a6c"></i>
|
| 177 |
-
<span>Congestion
|
| 178 |
</li>
|
| 179 |
<li class="flex items-start gap-3"><i class="fa-solid fa-circle text-[5px] mt-1.5"
|
| 180 |
style="color:#c89a6c"></i>
|
| 181 |
-
<span>
|
| 182 |
</li>
|
| 183 |
</ul>
|
| 184 |
</div>
|
| 185 |
<div class="space-y-4">
|
| 186 |
-
<h4 class="font-bold text-[13px] uppercase tracking-wider" style="color:#f0ece6">
|
| 187 |
Accuracy
|
| 188 |
</h4>
|
| 189 |
<p class="text-xs leading-relaxed" style="color:#a89f97">
|
| 190 |
-
UrbanFlow
|
| 191 |
-
may vary slightly across runs due to
|
| 192 |
</p>
|
| 193 |
<p class="text-xs leading-relaxed" style="color:#a89f97">
|
| 194 |
-
For research or planning use,
|
| 195 |
-
|
| 196 |
</p>
|
| 197 |
</div>
|
| 198 |
</div>
|
|
@@ -225,8 +223,8 @@
|
|
| 225 |
</div>
|
| 226 |
</div>
|
| 227 |
<div class="flex items-center space-x-6 text-xs font-bold text-white whitespace-nowrap">
|
| 228 |
-
<span id="proc-frames">
|
| 229 |
-
<span id="proc-pct">
|
| 230 |
<div class="uf-select-wrap" id="live-palette-wrap">
|
| 231 |
<div class="uf-select-trigger" id="live-palette-trigger" onclick="ufSelectToggle('live-palette')">
|
| 232 |
<span class="uf-select-label" id="live-palette-label">Default</span>
|
|
@@ -255,16 +253,16 @@
|
|
| 255 |
<!-- Empty State Overlay -->
|
| 256 |
<div id="stats-empty-state" class="stats-empty-overlay">
|
| 257 |
<i class="fa-solid fa-chart-column text-4xl mb-4" style="color:#333"></i>
|
| 258 |
-
<span class="text-sm font-bold" style="color:#555">
|
| 259 |
-
<span class="text-[11px] mt-1" style="color:#444">Charts will
|
| 260 |
-
|
| 261 |
</div>
|
| 262 |
|
| 263 |
<!-- Congestion Index -->
|
| 264 |
<div
|
| 265 |
class="col-span-12 xl:col-span-6 bg-white rounded-xl p-5 border border-slate-200 shadow-sm flex flex-col min-h-0">
|
| 266 |
<div class="flex justify-between items-center mb-2 relative">
|
| 267 |
-
<h3 class="font-bold text-slate-900 text-sm flex items-center">
|
| 268 |
<span class="info-wrap"><span class="info-btn"><i class="fa-solid fa-info"></i></span>
|
| 269 |
<span class="info-tip">Count of active tracked vehicles visible in each processed
|
| 270 |
frame.</span></span>
|
|
@@ -280,14 +278,13 @@
|
|
| 280 |
class="col-span-6 xl:col-span-3 bg-white rounded-xl p-5 border border-slate-200 shadow-sm flex flex-col items-center justify-center min-h-0">
|
| 281 |
<h3 class="font-bold text-slate-900 text-sm mb-2 self-start flex items-center">Directional Distribution
|
| 282 |
<span class="info-wrap"><span class="info-btn"><i class="fa-solid fa-info"></i></span>
|
| 283 |
-
<span class="info-tip">Incoming vs outgoing vehicles
|
| 284 |
-
boundary.</span></span>
|
| 285 |
</h3>
|
| 286 |
<div class="relative w-full flex-1 min-h-[180px] flex items-center justify-center">
|
| 287 |
<canvas id="doughnutChart"></canvas>
|
| 288 |
<div class="absolute inset-0 flex flex-col items-center justify-center pointer-events-none">
|
| 289 |
<span class="text-3xl font-black text-slate-900" id="cnt-total">0</span>
|
| 290 |
-
<span class="text-[10px] font-bold text-slate-400 uppercase tracking-wider">Total
|
| 291 |
<span class="text-[9px] font-bold mt-1 uppercase tracking-wider" style="color:#8b5e3c"
|
| 292 |
id="cnt-pcu-wrap"
|
| 293 |
title="Passenger Car Units (IRC:106-1990) — normalizes mixed traffic for capacity analysis">
|
|
@@ -307,7 +304,7 @@
|
|
| 307 |
spatial boundary.</span></span>
|
| 308 |
</h3>
|
| 309 |
</div>
|
| 310 |
-
<div class="text-[10px] text-slate-400 mb-3 uppercase tracking-widest">
|
| 311 |
<div class="flex-1 overflow-y-auto pr-2 space-y-2" id="class-breakdown"></div>
|
| 312 |
</div>
|
| 313 |
|
|
@@ -315,13 +312,12 @@
|
|
| 315 |
<div
|
| 316 |
class="col-span-12 xl:col-span-6 bg-white rounded-xl p-5 border border-slate-200 shadow-sm flex flex-col min-h-0">
|
| 317 |
<div class="flex justify-between items-center mb-2 relative">
|
| 318 |
-
<h3 class="font-bold text-slate-900 text-sm flex items-center">
|
| 319 |
<span class="info-wrap"><span class="info-btn"><i class="fa-solid fa-info"></i></span>
|
| 320 |
<span class="info-tip">Aggregated vehicle count grouped by dominant category.</span></span>
|
| 321 |
</h3>
|
| 322 |
<span
|
| 323 |
-
class="text-[10px] text-slate-500 font-bold uppercase tracking-wider whitespace-nowrap">
|
| 324 |
-
Intelligence</span>
|
| 325 |
</div>
|
| 326 |
<div class="flex-1 w-full relative min-h-[220px]">
|
| 327 |
<canvas id="dominanceChart"></canvas>
|
|
@@ -435,11 +431,10 @@
|
|
| 435 |
<!-- TAB: Reports -->
|
| 436 |
<div id="tab-reports" class="hidden flex-1 min-h-0 overflow-y-auto">
|
| 437 |
<div id="reports-pending-message"
|
| 438 |
-
class="mb-4 text-center p-8
|
| 439 |
-
<i id="reports-pending-icon" class="fa-solid fa-layer-group text-3xl text-[#c89a6c] opacity-50"></i>
|
| 440 |
<span id="reports-pending-text"
|
| 441 |
class="text-xs text-[#a89f97] font-medium tracking-wide uppercase leading-relaxed max-w-[240px]">
|
| 442 |
-
|
| 443 |
</span>
|
| 444 |
</div>
|
| 445 |
|
|
@@ -456,13 +451,19 @@
|
|
| 456 |
</h3>
|
| 457 |
</div>
|
| 458 |
<div class="flex-1 flex items-center justify-center" id="pcu-stats-card">
|
| 459 |
-
<div class="text-center text-slate-600 text-xs"><i
|
| 460 |
-
class="fa-solid fa-car text-2xl mb-2"></i><br>Available after processing</div>
|
| 461 |
</div>
|
| 462 |
</div>
|
| 463 |
</div>
|
| 464 |
|
| 465 |
<div id="reports-grid" class="hidden grid grid-cols-2 xl:grid-cols-3 gap-4"></div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 466 |
</div>
|
| 467 |
|
| 468 |
<!-- TAB: Settings -->
|
|
@@ -582,16 +583,16 @@
|
|
| 582 |
<div class="s-row" data-param="report">
|
| 583 |
<div>
|
| 584 |
<div class="text-xs font-semibold text-slate-300">Chart Format</div>
|
| 585 |
-
<div class="text-[10px] text-slate-500">Format for
|
| 586 |
</div>
|
| 587 |
<div class="uf-select-wrap" id="sv-report-wrap">
|
| 588 |
<div class="uf-select-trigger" id="sv-report-trigger" onclick="ufSelectToggle('sv-report')">
|
| 589 |
-
<span class="uf-select-label" id="sv-report-label">PNG
|
| 590 |
<i class="fa-solid fa-chevron-down uf-select-arrow" id="sv-report-arrow"></i>
|
| 591 |
</div>
|
| 592 |
<div class="uf-select-dropdown hidden" id="sv-report-dropdown">
|
| 593 |
-
<div class="uf-select-option uf-select-option-active" data-value="png" onclick="ufSelectPick('sv-report','png','PNG Image')">PNG
|
| 594 |
-
<div class="uf-select-option" data-value="pdf" onclick="ufSelectPick('sv-report','pdf','PDF Document')">PDF
|
| 595 |
</div>
|
| 596 |
<input type="hidden" id="sv-report" value="png">
|
| 597 |
</div>
|
|
@@ -662,9 +663,8 @@
|
|
| 662 |
<span class="info-wrap ml-1">
|
| 663 |
<span class="info-btn" style="background:#1a1a1a;color:#888"><i
|
| 664 |
class="fa-solid fa-info"></i></span>
|
| 665 |
-
<span class="info-tip">Enable before processing
|
| 666 |
-
|
| 667 |
-
after processing finishes.</span>
|
| 668 |
</span>
|
| 669 |
</div>
|
| 670 |
<div class="text-[10px] text-slate-500">Save reports automatically</div>
|
|
@@ -673,11 +673,11 @@
|
|
| 673 |
<div class="toggle-thumb"></div>
|
| 674 |
</div>
|
| 675 |
</div>
|
| 676 |
-
<div class="s-row hidden">
|
| 677 |
<div>
|
| 678 |
<div class="text-xs font-semibold text-slate-300">Interface Mode</div>
|
| 679 |
<div class="text-[10px] text-slate-500">Locked to Professional Dark</div>
|
| 680 |
-
</div>
|
| 681 |
<div class="text-xs font-bold text-white px-3 py-1 bg-slate-800 rounded-full">Dark Mode Only
|
| 682 |
</div>
|
| 683 |
</div>
|
|
@@ -714,7 +714,7 @@
|
|
| 714 |
<h3 class="font-bold text-white text-sm flex items-center">Navigator</h3>
|
| 715 |
<p class="text-[10px] mt-0.1 uppercase tracking-widest font-medium" style="color:#a89f97">
|
| 716 |
Quick
|
| 717 |
-
assistance
|
| 718 |
</div>
|
| 719 |
</div>
|
| 720 |
|
|
@@ -754,8 +754,7 @@
|
|
| 754 |
style="color:#777">
|
| 755 |
Auto-download failures are typically caused by browser popup blockers. Please
|
| 756 |
ensure you have allowed popups for this site in your browser settings.
|
| 757 |
-
Alternatively, you can
|
| 758 |
-
report download once processing reaches 100%.
|
| 759 |
</div>
|
| 760 |
</div>
|
| 761 |
<div
|
|
@@ -768,9 +767,9 @@
|
|
| 768 |
</button>
|
| 769 |
<div id="h3-ans" class="hidden px-6 pb-6 text-xs leading-relaxed"
|
| 770 |
style="color:#777">
|
| 771 |
-
To analyze a new video,
|
| 772 |
-
|
| 773 |
-
to the
|
| 774 |
</div>
|
| 775 |
</div>
|
| 776 |
<div
|
|
@@ -784,29 +783,21 @@
|
|
| 784 |
</button>
|
| 785 |
<div id="h4-ans" class="hidden px-6 pb-6 text-xs leading-relaxed"
|
| 786 |
style="color:#777">
|
| 787 |
-
|
| 788 |
-
conditions. UrbanFlow provides highly reliable analytical overviews, but
|
| 789 |
-
variables such as severe occlusion, extreme lighting, or complex
|
| 790 |
-
mis-classifications can occur. Our development goal is constant iteration toward
|
| 791 |
-
human-level perception.
|
| 792 |
</div>
|
| 793 |
</div>
|
| 794 |
<div
|
| 795 |
class="bg-[#050505] border border-slate-900 rounded-lg overflow-hidden transition hover:border-[#1a1a1a]">
|
| 796 |
<button onclick="toggleHelp('h5')"
|
| 797 |
class="w-full px-6 py-5 text-left flex items-center justify-between hover:bg-[#080808] transition">
|
| 798 |
-
<span class="text-sm font-semibold" style="color:#a89f97">What is PCU analysis
|
| 799 |
-
and
|
| 800 |
-
which speed metrics are calculated?</span>
|
| 801 |
<i id="h5-icon" class="fa-solid fa-plus text-xs" style="color:#555"></i>
|
| 802 |
</button>
|
| 803 |
<div id="h5-ans" class="hidden px-6 pb-6 text-xs leading-relaxed"
|
| 804 |
style="color:#777">
|
| 805 |
Passenger Car Unit (PCU) is a standard metric used in transportation engineering
|
| 806 |
to convert heterogeneous traffic (bikes, trucks, cars) into a common denominator
|
| 807 |
-
for capacity analysis.
|
| 808 |
-
distribution, helping identify congestion bottlenecks and overall throughput
|
| 809 |
-
efficiency.
|
| 810 |
</div>
|
| 811 |
</div>
|
| 812 |
</div>
|
|
@@ -838,16 +829,12 @@
|
|
| 838 |
class="bg-[#050505] border border-slate-900 rounded-lg overflow-hidden transition hover:border-[#1a1a1a]">
|
| 839 |
<button onclick="toggleHelp('h7')"
|
| 840 |
class="w-full px-6 py-5 text-left flex items-center justify-between hover:bg-[#080808] transition">
|
| 841 |
-
<span class="text-sm font-semibold" style="color:#a89f97">Why is this
|
| 842 |
-
focused on a single model?</span>
|
| 843 |
<i id="h7-icon" class="fa-solid fa-plus text-xs" style="color:#555"></i>
|
| 844 |
</button>
|
| 845 |
<div id="h7-ans" class="hidden px-6 pb-6 text-xs leading-relaxed"
|
| 846 |
style="color:#777">
|
| 847 |
-
This platform
|
| 848 |
-
model for requirements gathering. The full production suite integrates multiple
|
| 849 |
-
specialized models, real-time edge processing, and advanced telemetry designed
|
| 850 |
-
for complex enterprise-grade deployments.
|
| 851 |
</div>
|
| 852 |
</div>
|
| 853 |
<div
|
|
@@ -906,7 +893,7 @@
|
|
| 906 |
</button>
|
| 907 |
<div id="h11-ans" class="hidden px-6 pb-6 text-xs leading-relaxed"
|
| 908 |
style="color:#777">
|
| 909 |
-
Our roadmap includes multi-model fusion, real-time
|
| 910 |
ANPR integration, and deeper predictive analytics to support smarter city
|
| 911 |
infrastructure.
|
| 912 |
</div>
|
|
@@ -1169,7 +1156,7 @@
|
|
| 1169 |
<p style="color:#a89f97;font-size:11px;margin-bottom:20px">We keep this simple and honest.</p>
|
| 1170 |
<ul style="color:#a89f97;font-size:11px;line-height:1.9;padding-left:16px;list-style:disc">
|
| 1171 |
<li>This is a <strong style="color:#f0ece6">public demo</strong> hosted on Hugging Face Spaces. It is
|
| 1172 |
-
not a production service.</li>
|
| 1173 |
<li>Footage you submit is processed in real time and <strong style="color:#f0ece6">discarded
|
| 1174 |
immediately</strong> after the session ends. Nothing is stored on our servers.</li>
|
| 1175 |
<li>We do not use your footage to train models, sell it, or share it with any third party.</li>
|
|
@@ -1192,7 +1179,7 @@
|
|
| 1192 |
<button onclick="closeAppModal('termsModal')"
|
| 1193 |
style="position:absolute;top:16px;right:18px;background:none;border:none;color:#a89f97;font-size:18px;cursor:pointer">×</button>
|
| 1194 |
<h2 style="color:#f0ece6;font-size:1.1rem;font-weight:700;margin-bottom:8px">Terms & Conditions</h2>
|
| 1195 |
-
<p style="color:#a89f97;font-size:11px;margin-bottom:20px">By using this
|
| 1196 |
following terms.</p>
|
| 1197 |
<p style="color:#c89a6c;font-size:11px;font-weight:700;margin-bottom:6px">You can:</p>
|
| 1198 |
<ul
|
|
|
|
| 152 |
what gets built for production.
|
| 153 |
</p>
|
| 154 |
<p style="font-size:13px;color:#777">
|
| 155 |
+
The production system will support live-streaming and more advanced analytics.
|
| 156 |
+
This application only accepts video clips.
|
|
|
|
| 157 |
</p>
|
| 158 |
</div>
|
| 159 |
|
| 160 |
<div class="grid grid-cols-2 gap-12 pt-8 text-left border-t max-w-5xl mx-auto"
|
| 161 |
style="border-color:#1a1a1a">
|
| 162 |
<div class="space-y-4">
|
| 163 |
+
<h4 class="font-bold text-[13px] uppercase tracking-wider" style="color:#f0ece6">What You Will Get Here</h4>
|
|
|
|
| 164 |
<ul class="text-xs space-y-3 pl-1">
|
| 165 |
<li class="flex items-start gap-3"><i class="fa-solid fa-circle text-[5px] mt-1.5"
|
| 166 |
style="color:#c89a6c"></i>
|
| 167 |
+
<span>Class-wise vehicle counts</span>
|
| 168 |
</li>
|
| 169 |
<li class="flex items-start gap-3"><i class="fa-solid fa-circle text-[5px] mt-1.5"
|
| 170 |
style="color:#c89a6c"></i>
|
| 171 |
+
<span>Directional Flow Analysis — incoming vs outgoing</span>
|
| 172 |
</li>
|
| 173 |
<li class="flex items-start gap-3"><i class="fa-solid fa-circle text-[5px] mt-1.5"
|
| 174 |
style="color:#c89a6c"></i>
|
| 175 |
+
<span>Congestion Analytics,Peak Detection, and temporal Trends</span>
|
| 176 |
</li>
|
| 177 |
<li class="flex items-start gap-3"><i class="fa-solid fa-circle text-[5px] mt-1.5"
|
| 178 |
style="color:#c89a6c"></i>
|
| 179 |
+
<span>Exportable Reports</span>
|
| 180 |
</li>
|
| 181 |
</ul>
|
| 182 |
</div>
|
| 183 |
<div class="space-y-4">
|
| 184 |
+
<h4 class="font-bold text-[13px] uppercase tracking-wider" style="color:#f0ece6">Inference
|
| 185 |
Accuracy
|
| 186 |
</h4>
|
| 187 |
<p class="text-xs leading-relaxed" style="color:#a89f97">
|
| 188 |
+
UrbanFlow delivers an estimated accuracy of ±5–8% on dense mixed-traffic footage. Results
|
| 189 |
+
may vary slightly across runs due to frame-by-frame inference variability
|
| 190 |
</p>
|
| 191 |
<p class="text-xs leading-relaxed" style="color:#a89f97">
|
| 192 |
+
For research or planning use, process the same footage 2–3 times
|
| 193 |
+
and average the results for improved reliability.
|
| 194 |
</p>
|
| 195 |
</div>
|
| 196 |
</div>
|
|
|
|
| 223 |
</div>
|
| 224 |
</div>
|
| 225 |
<div class="flex items-center space-x-6 text-xs font-bold text-white whitespace-nowrap">
|
| 226 |
+
<span id="proc-frames">Awaiting Input</span>
|
| 227 |
+
<span id="proc-pct">Idle</span>
|
| 228 |
<div class="uf-select-wrap" id="live-palette-wrap">
|
| 229 |
<div class="uf-select-trigger" id="live-palette-trigger" onclick="ufSelectToggle('live-palette')">
|
| 230 |
<span class="uf-select-label" id="live-palette-label">Default</span>
|
|
|
|
| 253 |
<!-- Empty State Overlay -->
|
| 254 |
<div id="stats-empty-state" class="stats-empty-overlay">
|
| 255 |
<i class="fa-solid fa-chart-column text-4xl mb-4" style="color:#333"></i>
|
| 256 |
+
<span class="text-sm font-bold" style="color:#555">Awaiting Processing</span>
|
| 257 |
+
<span class="text-[11px] mt-1" style="color:#444">Charts will update dynamically as analysis
|
| 258 |
+
progresses.</span>
|
| 259 |
</div>
|
| 260 |
|
| 261 |
<!-- Congestion Index -->
|
| 262 |
<div
|
| 263 |
class="col-span-12 xl:col-span-6 bg-white rounded-xl p-5 border border-slate-200 shadow-sm flex flex-col min-h-0">
|
| 264 |
<div class="flex justify-between items-center mb-2 relative">
|
| 265 |
+
<h3 class="font-bold text-slate-900 text-sm flex items-center">Congestion Index
|
| 266 |
<span class="info-wrap"><span class="info-btn"><i class="fa-solid fa-info"></i></span>
|
| 267 |
<span class="info-tip">Count of active tracked vehicles visible in each processed
|
| 268 |
frame.</span></span>
|
|
|
|
| 278 |
class="col-span-6 xl:col-span-3 bg-white rounded-xl p-5 border border-slate-200 shadow-sm flex flex-col items-center justify-center min-h-0">
|
| 279 |
<h3 class="font-bold text-slate-900 text-sm mb-2 self-start flex items-center">Directional Distribution
|
| 280 |
<span class="info-wrap"><span class="info-btn"><i class="fa-solid fa-info"></i></span>
|
| 281 |
+
<span class="info-tip">Incoming vs outgoing vehicles detected along the defined path</span></span>
|
|
|
|
| 282 |
</h3>
|
| 283 |
<div class="relative w-full flex-1 min-h-[180px] flex items-center justify-center">
|
| 284 |
<canvas id="doughnutChart"></canvas>
|
| 285 |
<div class="absolute inset-0 flex flex-col items-center justify-center pointer-events-none">
|
| 286 |
<span class="text-3xl font-black text-slate-900" id="cnt-total">0</span>
|
| 287 |
+
<span class="text-[10px] font-bold text-slate-400 uppercase tracking-wider">Total Count</span>
|
| 288 |
<span class="text-[9px] font-bold mt-1 uppercase tracking-wider" style="color:#8b5e3c"
|
| 289 |
id="cnt-pcu-wrap"
|
| 290 |
title="Passenger Car Units (IRC:106-1990) — normalizes mixed traffic for capacity analysis">
|
|
|
|
| 304 |
spatial boundary.</span></span>
|
| 305 |
</h3>
|
| 306 |
</div>
|
| 307 |
+
<div class="text-[10px] text-slate-400 mb-3 uppercase tracking-widest">Class Breakdown</div>
|
| 308 |
<div class="flex-1 overflow-y-auto pr-2 space-y-2" id="class-breakdown"></div>
|
| 309 |
</div>
|
| 310 |
|
|
|
|
| 312 |
<div
|
| 313 |
class="col-span-12 xl:col-span-6 bg-white rounded-xl p-5 border border-slate-200 shadow-sm flex flex-col min-h-0">
|
| 314 |
<div class="flex justify-between items-center mb-2 relative">
|
| 315 |
+
<h3 class="font-bold text-slate-900 text-sm flex items-center">Big Picture
|
| 316 |
<span class="info-wrap"><span class="info-btn"><i class="fa-solid fa-info"></i></span>
|
| 317 |
<span class="info-tip">Aggregated vehicle count grouped by dominant category.</span></span>
|
| 318 |
</h3>
|
| 319 |
<span
|
| 320 |
+
class="text-[10px] text-slate-500 font-bold uppercase tracking-wider whitespace-nowrap">Category Dominance</span>
|
|
|
|
| 321 |
</div>
|
| 322 |
<div class="flex-1 w-full relative min-h-[220px]">
|
| 323 |
<canvas id="dominanceChart"></canvas>
|
|
|
|
| 431 |
<!-- TAB: Reports -->
|
| 432 |
<div id="tab-reports" class="hidden flex-1 min-h-0 overflow-y-auto">
|
| 433 |
<div id="reports-pending-message"
|
| 434 |
+
class="mb-4 text-center p-8 flex flex-col items-center justify-center gap-4 min-h-[200px]">
|
|
|
|
| 435 |
<span id="reports-pending-text"
|
| 436 |
class="text-xs text-[#a89f97] font-medium tracking-wide uppercase leading-relaxed max-w-[240px]">
|
| 437 |
+
Return once processing is complete to access results.
|
| 438 |
</span>
|
| 439 |
</div>
|
| 440 |
|
|
|
|
| 451 |
</h3>
|
| 452 |
</div>
|
| 453 |
<div class="flex-1 flex items-center justify-center" id="pcu-stats-card">
|
| 454 |
+
<div class="text-center text-slate-600 text-xs"><i></i><br>Available after processing</div>
|
|
|
|
| 455 |
</div>
|
| 456 |
</div>
|
| 457 |
</div>
|
| 458 |
|
| 459 |
<div id="reports-grid" class="hidden grid grid-cols-2 xl:grid-cols-3 gap-4"></div>
|
| 460 |
+
|
| 461 |
+
<!-- Mobile Download Button (visible at the very bottom of Artifacts tab after processing) -->
|
| 462 |
+
<div id="mobile-download-wrap" class="hidden lg:hidden flex justify-center mt-6 mb-4">
|
| 463 |
+
<button onclick="downloadArtifacts()" class="w-fit px-16 py-4 font-bold text-sm rounded-full transition flex items-center justify-center gap-2 shadow-lg active:scale-95" style="background:var(--cocoa-l);color:#000">
|
| 464 |
+
<i class="fa-solid fa-download"></i> Download All
|
| 465 |
+
</button>
|
| 466 |
+
</div>
|
| 467 |
</div>
|
| 468 |
|
| 469 |
<!-- TAB: Settings -->
|
|
|
|
| 583 |
<div class="s-row" data-param="report">
|
| 584 |
<div>
|
| 585 |
<div class="text-xs font-semibold text-slate-300">Chart Format</div>
|
| 586 |
+
<div class="text-[10px] text-slate-500">Format for each KPI chart</div>
|
| 587 |
</div>
|
| 588 |
<div class="uf-select-wrap" id="sv-report-wrap">
|
| 589 |
<div class="uf-select-trigger" id="sv-report-trigger" onclick="ufSelectToggle('sv-report')">
|
| 590 |
+
<span class="uf-select-label" id="sv-report-label">PNG</span>
|
| 591 |
<i class="fa-solid fa-chevron-down uf-select-arrow" id="sv-report-arrow"></i>
|
| 592 |
</div>
|
| 593 |
<div class="uf-select-dropdown hidden" id="sv-report-dropdown">
|
| 594 |
+
<div class="uf-select-option uf-select-option-active" data-value="png" onclick="ufSelectPick('sv-report','png','PNG Image')">PNG</div>
|
| 595 |
+
<div class="uf-select-option" data-value="pdf" onclick="ufSelectPick('sv-report','pdf','PDF Document')">PDF</div>
|
| 596 |
</div>
|
| 597 |
<input type="hidden" id="sv-report" value="png">
|
| 598 |
</div>
|
|
|
|
| 663 |
<span class="info-wrap ml-1">
|
| 664 |
<span class="info-btn" style="background:#1a1a1a;color:#888"><i
|
| 665 |
class="fa-solid fa-info"></i></span>
|
| 666 |
+
<span class="info-tip">Enable before processing completes
|
| 667 |
+
to automatically download the report.</span>
|
|
|
|
| 668 |
</span>
|
| 669 |
</div>
|
| 670 |
<div class="text-[10px] text-slate-500">Save reports automatically</div>
|
|
|
|
| 673 |
<div class="toggle-thumb"></div>
|
| 674 |
</div>
|
| 675 |
</div>
|
| 676 |
+
<div class="s-row hidden">
|
| 677 |
<div>
|
| 678 |
<div class="text-xs font-semibold text-slate-300">Interface Mode</div>
|
| 679 |
<div class="text-[10px] text-slate-500">Locked to Professional Dark</div>
|
| 680 |
+
</div>
|
| 681 |
<div class="text-xs font-bold text-white px-3 py-1 bg-slate-800 rounded-full">Dark Mode Only
|
| 682 |
</div>
|
| 683 |
</div>
|
|
|
|
| 714 |
<h3 class="font-bold text-white text-sm flex items-center">Navigator</h3>
|
| 715 |
<p class="text-[10px] mt-0.1 uppercase tracking-widest font-medium" style="color:#a89f97">
|
| 716 |
Quick
|
| 717 |
+
assistance & Documentation</p>
|
| 718 |
</div>
|
| 719 |
</div>
|
| 720 |
|
|
|
|
| 754 |
style="color:#777">
|
| 755 |
Auto-download failures are typically caused by browser popup blockers. Please
|
| 756 |
ensure you have allowed popups for this site in your browser settings.
|
| 757 |
+
Alternatively, you can manually trigger the bundled ZIP download once processing reaches 100% by using the 'D' keyboard shortcut on Desktop, or tapping the 'Download All' button on Mobile.
|
|
|
|
| 758 |
</div>
|
| 759 |
</div>
|
| 760 |
<div
|
|
|
|
| 767 |
</button>
|
| 768 |
<div id="h3-ans" class="hidden px-6 pb-6 text-xs leading-relaxed"
|
| 769 |
style="color:#777">
|
| 770 |
+
To analyze a new video, go to 'Settings' and click 'Analyze again'
|
| 771 |
+
This resets current session state and return you
|
| 772 |
+
to the Home screen.
|
| 773 |
</div>
|
| 774 |
</div>
|
| 775 |
<div
|
|
|
|
| 783 |
</button>
|
| 784 |
<div id="h4-ans" class="hidden px-6 pb-6 text-xs leading-relaxed"
|
| 785 |
style="color:#777">
|
| 786 |
+
UrbanFlow delivers an estimated accuracy of ±5–8% on dense mixed-traffic footage. While highly reliable, no computer vision model achieves 100% accuracy under all conditions. Results may vary slightly across runs due to frame-by-frame inference variability, severe occlusion, or extreme lighting. Our goal is constant iteration toward human-level perception.
|
|
|
|
|
|
|
|
|
|
|
|
|
| 787 |
</div>
|
| 788 |
</div>
|
| 789 |
<div
|
| 790 |
class="bg-[#050505] border border-slate-900 rounded-lg overflow-hidden transition hover:border-[#1a1a1a]">
|
| 791 |
<button onclick="toggleHelp('h5')"
|
| 792 |
class="w-full px-6 py-5 text-left flex items-center justify-between hover:bg-[#080808] transition">
|
| 793 |
+
<span class="text-sm font-semibold" style="color:#a89f97">What is PCU analysis?</span>
|
|
|
|
|
|
|
| 794 |
<i id="h5-icon" class="fa-solid fa-plus text-xs" style="color:#555"></i>
|
| 795 |
</button>
|
| 796 |
<div id="h5-ans" class="hidden px-6 pb-6 text-xs leading-relaxed"
|
| 797 |
style="color:#777">
|
| 798 |
Passenger Car Unit (PCU) is a standard metric used in transportation engineering
|
| 799 |
to convert heterogeneous traffic (bikes, trucks, cars) into a common denominator
|
| 800 |
+
for capacity analysis. This allows UrbanFlow to accurately calculate standardized traffic loads and identify congestion bottlenecks regardless of vehicle composition.
|
|
|
|
|
|
|
| 801 |
</div>
|
| 802 |
</div>
|
| 803 |
</div>
|
|
|
|
| 829 |
class="bg-[#050505] border border-slate-900 rounded-lg overflow-hidden transition hover:border-[#1a1a1a]">
|
| 830 |
<button onclick="toggleHelp('h7')"
|
| 831 |
class="w-full px-6 py-5 text-left flex items-center justify-between hover:bg-[#080808] transition">
|
| 832 |
+
<span class="text-sm font-semibold" style="color:#a89f97">Why is this application designed to be simple and focused?</span>
|
|
|
|
| 833 |
<i id="h7-icon" class="fa-solid fa-plus text-xs" style="color:#555"></i>
|
| 834 |
</button>
|
| 835 |
<div id="h7-ans" class="hidden px-6 pb-6 text-xs leading-relaxed"
|
| 836 |
style="color:#777">
|
| 837 |
+
This platform is intentionally built as a streamlined demo. We created it to allow users to explore and provide us with valuable feedback. This user feedback directly helps us continuously improve our models and guides the development of our full, enterprise-grade production suite.
|
|
|
|
|
|
|
|
|
|
| 838 |
</div>
|
| 839 |
</div>
|
| 840 |
<div
|
|
|
|
| 893 |
</button>
|
| 894 |
<div id="h11-ans" class="hidden px-6 pb-6 text-xs leading-relaxed"
|
| 895 |
style="color:#777">
|
| 896 |
+
Our roadmap includes multi-model fusion, real-time processing, advanced
|
| 897 |
ANPR integration, and deeper predictive analytics to support smarter city
|
| 898 |
infrastructure.
|
| 899 |
</div>
|
|
|
|
| 1156 |
<p style="color:#a89f97;font-size:11px;margin-bottom:20px">We keep this simple and honest.</p>
|
| 1157 |
<ul style="color:#a89f97;font-size:11px;line-height:1.9;padding-left:16px;list-style:disc">
|
| 1158 |
<li>This is a <strong style="color:#f0ece6">public demo</strong> hosted on Hugging Face Spaces. It is
|
| 1159 |
+
not yet a complete production service.</li>
|
| 1160 |
<li>Footage you submit is processed in real time and <strong style="color:#f0ece6">discarded
|
| 1161 |
immediately</strong> after the session ends. Nothing is stored on our servers.</li>
|
| 1162 |
<li>We do not use your footage to train models, sell it, or share it with any third party.</li>
|
|
|
|
| 1179 |
<button onclick="closeAppModal('termsModal')"
|
| 1180 |
style="position:absolute;top:16px;right:18px;background:none;border:none;color:#a89f97;font-size:18px;cursor:pointer">×</button>
|
| 1181 |
<h2 style="color:#f0ece6;font-size:1.1rem;font-weight:700;margin-bottom:8px">Terms & Conditions</h2>
|
| 1182 |
+
<p style="color:#a89f97;font-size:11px;margin-bottom:20px">By using this application, you agree to the
|
| 1183 |
following terms.</p>
|
| 1184 |
<p style="color:#c89a6c;font-size:11px;font-weight:700;margin-bottom:6px">You can:</p>
|
| 1185 |
<ul
|