Add 3 files
Browse files- README.md +7 -5
- index.html +527 -19
- prompts.txt +1 -0
README.md
CHANGED
|
@@ -1,10 +1,12 @@
|
|
| 1 |
---
|
| 2 |
-
title:
|
| 3 |
-
emoji:
|
| 4 |
-
colorFrom:
|
| 5 |
-
colorTo:
|
| 6 |
sdk: static
|
| 7 |
pinned: false
|
|
|
|
|
|
|
| 8 |
---
|
| 9 |
|
| 10 |
-
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
|
| 1 |
---
|
| 2 |
+
title: defapp
|
| 3 |
+
emoji: 🐳
|
| 4 |
+
colorFrom: blue
|
| 5 |
+
colorTo: gray
|
| 6 |
sdk: static
|
| 7 |
pinned: false
|
| 8 |
+
tags:
|
| 9 |
+
- deepsite
|
| 10 |
---
|
| 11 |
|
| 12 |
+
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
index.html
CHANGED
|
@@ -1,19 +1,527 @@
|
|
| 1 |
-
<!
|
| 2 |
-
<html>
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<!DOCTYPE html>
|
| 2 |
+
<html lang="en">
|
| 3 |
+
<head>
|
| 4 |
+
<meta charset="UTF-8">
|
| 5 |
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 6 |
+
<title>PurpleHoop - Basketball Training</title>
|
| 7 |
+
<script src="https://cdn.tailwindcss.com"></script>
|
| 8 |
+
<script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
|
| 9 |
+
<script src="https://cdn.jsdelivr.net/npm/hotkeys-js/dist/hotkeys.min.js"></script>
|
| 10 |
+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
|
| 11 |
+
<style>
|
| 12 |
+
.heatmap {
|
| 13 |
+
background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%"><rect width="100%" height="100%" fill="black"/></svg>');
|
| 14 |
+
position: relative;
|
| 15 |
+
}
|
| 16 |
+
|
| 17 |
+
.heat-point {
|
| 18 |
+
position: absolute;
|
| 19 |
+
border-radius: 50%;
|
| 20 |
+
transform: translate(-50%, -50%);
|
| 21 |
+
opacity: 0.7;
|
| 22 |
+
transition: all 0.3s ease;
|
| 23 |
+
}
|
| 24 |
+
|
| 25 |
+
.court {
|
| 26 |
+
background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="300" height="280" viewBox="0 0 300 280"><rect x="0" y="0" width="300" height="280" fill="none" stroke="%23a855f7" stroke-width="2"/><circle cx="150" cy="140" r="60" fill="none" stroke="%23a855f7" stroke-width="2"/><line x1="0" y1="140" x2="300" y2="140" stroke="%23a855f7" stroke-width="2"/><rect x="0" y="100" width="60" height="80" fill="none" stroke="%23a855f7" stroke-width="2"/><rect x="240" y="100" width="60" height="80" fill="none" stroke="%23a855f7" stroke-width="2"/></svg>');
|
| 27 |
+
background-repeat: no-repeat;
|
| 28 |
+
background-position: center;
|
| 29 |
+
background-size: contain;
|
| 30 |
+
}
|
| 31 |
+
|
| 32 |
+
.gradient-bg {
|
| 33 |
+
background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 100%);
|
| 34 |
+
}
|
| 35 |
+
|
| 36 |
+
.pulse-animation {
|
| 37 |
+
animation: pulse 2s infinite;
|
| 38 |
+
}
|
| 39 |
+
|
| 40 |
+
@keyframes pulse {
|
| 41 |
+
0% { box-shadow: 0 0 0 0 rgba(168, 85, 247, 0.7); }
|
| 42 |
+
70% { box-shadow: 0 0 0 10px rgba(168, 85, 247, 0); }
|
| 43 |
+
100% { box-shadow: 0 0 0 0 rgba(168, 85, 247, 0); }
|
| 44 |
+
}
|
| 45 |
+
|
| 46 |
+
.shot-trail {
|
| 47 |
+
position: absolute;
|
| 48 |
+
background: #a855f7;
|
| 49 |
+
height: 2px;
|
| 50 |
+
transform-origin: left center;
|
| 51 |
+
z-index: 10;
|
| 52 |
+
}
|
| 53 |
+
</style>
|
| 54 |
+
</head>
|
| 55 |
+
<body class="gradient-bg text-white min-h-screen">
|
| 56 |
+
<div class="container mx-auto px-4 py-8">
|
| 57 |
+
<!-- Header -->
|
| 58 |
+
<header class="flex justify-between items-center mb-8">
|
| 59 |
+
<div class="flex items-center">
|
| 60 |
+
<i class="fas fa-basketball-ball text-4xl text-purple-500 mr-3"></i>
|
| 61 |
+
<h1 class="text-3xl font-bold bg-clip-text text-transparent bg-gradient-to-r from-purple-400 to-purple-600">
|
| 62 |
+
PurpleHoop
|
| 63 |
+
</h1>
|
| 64 |
+
</div>
|
| 65 |
+
<div class="flex space-x-4">
|
| 66 |
+
<button class="bg-purple-600 hover:bg-purple-700 px-4 py-2 rounded-lg flex items-center">
|
| 67 |
+
<i class="fas fa-user mr-2"></i> Profile
|
| 68 |
+
</button>
|
| 69 |
+
<button class="bg-gray-800 hover:bg-gray-700 px-4 py-2 rounded-lg flex items-center">
|
| 70 |
+
<i class="fas fa-cog mr-2"></i> Settings
|
| 71 |
+
</button>
|
| 72 |
+
</div>
|
| 73 |
+
</header>
|
| 74 |
+
|
| 75 |
+
<!-- Main Content -->
|
| 76 |
+
<div class="grid grid-cols-1 lg:grid-cols-3 gap-8">
|
| 77 |
+
<!-- Camera Feed and Tracking -->
|
| 78 |
+
<div class="lg:col-span-2 space-y-6">
|
| 79 |
+
<div class="bg-black rounded-xl overflow-hidden shadow-2xl">
|
| 80 |
+
<div class="p-4 bg-gray-900 flex justify-between items-center">
|
| 81 |
+
<h2 class="text-xl font-semibold text-purple-400">
|
| 82 |
+
<i class="fas fa-video mr-2"></i> Shot Tracking
|
| 83 |
+
</h2>
|
| 84 |
+
<div class="flex space-x-2">
|
| 85 |
+
<button id="startTracking" class="bg-purple-600 hover:bg-purple-700 px-3 py-1 rounded-lg flex items-center pulse-animation">
|
| 86 |
+
<i class="fas fa-play mr-2"></i> Start Session
|
| 87 |
+
</button>
|
| 88 |
+
<button id="toggleCamera" class="bg-gray-700 hover:bg-gray-600 px-3 py-1 rounded-lg flex items-center">
|
| 89 |
+
<i class="fas fa-camera mr-2"></i> Switch Camera
|
| 90 |
+
</button>
|
| 91 |
+
</div>
|
| 92 |
+
</div>
|
| 93 |
+
|
| 94 |
+
<div class="relative" style="padding-bottom: 56.25%;">
|
| 95 |
+
<!-- Camera Feed Placeholder -->
|
| 96 |
+
<div id="cameraFeed" class="absolute inset-0 bg-gray-800 flex items-center justify-center">
|
| 97 |
+
<div class="text-center">
|
| 98 |
+
<i class="fas fa-basketball-ball text-6xl text-gray-600 mb-4"></i>
|
| 99 |
+
<p class="text-gray-400">Camera feed will appear here</p>
|
| 100 |
+
<button id="enableCamera" class="mt-4 bg-purple-600 hover:bg-purple-700 px-4 py-2 rounded-lg">
|
| 101 |
+
Enable Camera
|
| 102 |
+
</button>
|
| 103 |
+
</div>
|
| 104 |
+
</div>
|
| 105 |
+
|
| 106 |
+
<!-- Overlay for computer vision tracking -->
|
| 107 |
+
<canvas id="trackingOverlay" class="absolute inset-0 w-full h-full pointer-events-none" style="display: none;"></canvas>
|
| 108 |
+
|
| 109 |
+
<!-- Shot trails container -->
|
| 110 |
+
<div id="shotTrails" class="absolute inset-0 w-full h-full pointer-events-none"></div>
|
| 111 |
+
</div>
|
| 112 |
+
|
| 113 |
+
<div class="p-4 bg-gray-900 flex justify-between items-center">
|
| 114 |
+
<div class="text-sm text-gray-400">
|
| 115 |
+
<span id="shotCount">0</span> shots tracked
|
| 116 |
+
</div>
|
| 117 |
+
<div class="flex space-x-2">
|
| 118 |
+
<button id="showHeatmap" class="bg-gray-700 hover:bg-gray-600 px-3 py-1 rounded-lg flex items-center">
|
| 119 |
+
<i class="fas fa-fire mr-2"></i> Heatmap
|
| 120 |
+
</button>
|
| 121 |
+
<button id="showTrajectory" class="bg-gray-700 hover:bg-gray-600 px-3 py-1 rounded-lg flex items-center">
|
| 122 |
+
<i class="fas fa-project-diagram mr-2"></i> Trajectories
|
| 123 |
+
</button>
|
| 124 |
+
</div>
|
| 125 |
+
</div>
|
| 126 |
+
</div>
|
| 127 |
+
|
| 128 |
+
<!-- Session Stats -->
|
| 129 |
+
<div class="bg-gray-900 rounded-xl p-6 shadow-2xl">
|
| 130 |
+
<h2 class="text-xl font-semibold text-purple-400 mb-4">
|
| 131 |
+
<i class="fas fa-chart-line mr-2"></i> Session Statistics
|
| 132 |
+
</h2>
|
| 133 |
+
<div class="grid grid-cols-2 md:grid-cols-4 gap-4">
|
| 134 |
+
<div class="bg-gray-800 p-4 rounded-lg">
|
| 135 |
+
<div class="text-sm text-gray-400">Made Shots</div>
|
| 136 |
+
<div class="text-2xl font-bold text-purple-400">12</div>
|
| 137 |
+
<div class="text-xs text-gray-500">+2 from last</div>
|
| 138 |
+
</div>
|
| 139 |
+
<div class="bg-gray-800 p-4 rounded-lg">
|
| 140 |
+
<div class="text-sm text-gray-400">Shot %</div>
|
| 141 |
+
<div class="text-2xl font-bold text-purple-400">48%</div>
|
| 142 |
+
<div class="text-xs text-gray-500">3% improvement</div>
|
| 143 |
+
</div>
|
| 144 |
+
<div class="bg-gray-800 p-4 rounded-lg">
|
| 145 |
+
<div class="text-sm text-gray-400">Avg Arc</div>
|
| 146 |
+
<div class="text-2xl font-bold text-purple-400">47°</div>
|
| 147 |
+
<div class="text-xs text-gray-500">Ideal: 45-50°</div>
|
| 148 |
+
</div>
|
| 149 |
+
<div class="bg-gray-800 p-4 rounded-lg">
|
| 150 |
+
<div class="text-sm text-gray-400">Release Time</div>
|
| 151 |
+
<div class="text-2xl font-bold text-purple-400">0.8s</div>
|
| 152 |
+
<div class="text-xs text-gray-500">Consistent</div>
|
| 153 |
+
</div>
|
| 154 |
+
</div>
|
| 155 |
+
</div>
|
| 156 |
+
</div>
|
| 157 |
+
|
| 158 |
+
<!-- Sidebar with Heatmap and Analytics -->
|
| 159 |
+
<div class="space-y-6">
|
| 160 |
+
<!-- Heatmap Visualization -->
|
| 161 |
+
<div class="bg-gray-900 rounded-xl p-6 shadow-2xl">
|
| 162 |
+
<h2 class="text-xl font-semibold text-purple-400 mb-4">
|
| 163 |
+
<i class="fas fa-fire mr-2"></i> Shot Heatmap
|
| 164 |
+
</h2>
|
| 165 |
+
<div class="heatmap court relative" style="height: 280px; width: 100%;">
|
| 166 |
+
<!-- Heatmap points will be added here by JavaScript -->
|
| 167 |
+
</div>
|
| 168 |
+
<div class="mt-4 flex justify-between text-xs text-gray-400">
|
| 169 |
+
<span>Fewer shots</span>
|
| 170 |
+
<span>More shots</span>
|
| 171 |
+
</div>
|
| 172 |
+
<div class="h-2 mt-1 rounded-full bg-gradient-to-r from-gray-800 via-purple-600 to-purple-400"></div>
|
| 173 |
+
</div>
|
| 174 |
+
|
| 175 |
+
<!-- Shot Chart -->
|
| 176 |
+
<div class="bg-gray-900 rounded-xl p-6 shadow-2xl">
|
| 177 |
+
<h2 class="text-xl font-semibold text-purple-400 mb-4">
|
| 178 |
+
<i class="fas fa-bullseye mr-2"></i> Shot Accuracy
|
| 179 |
+
</h2>
|
| 180 |
+
<canvas id="shotChart" height="200"></canvas>
|
| 181 |
+
</div>
|
| 182 |
+
|
| 183 |
+
<!-- Shot Types -->
|
| 184 |
+
<div class="bg-gray-900 rounded-xl p-6 shadow-2xl">
|
| 185 |
+
<h2 class="text-xl font-semibold text-purple-400 mb-4">
|
| 186 |
+
<i class="fas fa-tags mr-2"></i> Shot Types
|
| 187 |
+
</h2>
|
| 188 |
+
<div class="space-y-3">
|
| 189 |
+
<div>
|
| 190 |
+
<div class="flex justify-between text-sm mb-1">
|
| 191 |
+
<span>3-Pointers</span>
|
| 192 |
+
<span>8/20 (40%)</span>
|
| 193 |
+
</div>
|
| 194 |
+
<div class="w-full bg-gray-800 rounded-full h-2">
|
| 195 |
+
<div class="bg-purple-500 h-2 rounded-full" style="width: 40%"></div>
|
| 196 |
+
</div>
|
| 197 |
+
</div>
|
| 198 |
+
<div>
|
| 199 |
+
<div class="flex justify-between text-sm mb-1">
|
| 200 |
+
<span>Mid-Range</span>
|
| 201 |
+
<span>12/15 (80%)</span>
|
| 202 |
+
</div>
|
| 203 |
+
<div class="w-full bg-gray-800 rounded-full h-2">
|
| 204 |
+
<div class="bg-purple-500 h-2 rounded-full" style="width: 80%"></div>
|
| 205 |
+
</div>
|
| 206 |
+
</div>
|
| 207 |
+
<div>
|
| 208 |
+
<div class="flex justify-between text-sm mb-1">
|
| 209 |
+
<span>Layups</span>
|
| 210 |
+
<span>10/12 (83%)</span>
|
| 211 |
+
</div>
|
| 212 |
+
<div class="w-full bg-gray-800 rounded-full h-2">
|
| 213 |
+
<div class="bg-purple-500 h-2 rounded-full" style="width: 83%"></div>
|
| 214 |
+
</div>
|
| 215 |
+
</div>
|
| 216 |
+
</div>
|
| 217 |
+
</div>
|
| 218 |
+
</div>
|
| 219 |
+
</div>
|
| 220 |
+
|
| 221 |
+
<!-- Session History -->
|
| 222 |
+
<div class="mt-12 bg-gray-900 rounded-xl p-6 shadow-2xl">
|
| 223 |
+
<h2 class="text-xl font-semibold text-purple-400 mb-4">
|
| 224 |
+
<i class="fas fa-history mr-2"></i> Recent Sessions
|
| 225 |
+
</h2>
|
| 226 |
+
<div class="overflow-x-auto">
|
| 227 |
+
<table class="min-w-full divide-y divide-gray-800">
|
| 228 |
+
<thead>
|
| 229 |
+
<tr>
|
| 230 |
+
<th class="px-4 py-3 text-left text-xs font-medium text-gray-400 uppercase tracking-wider">Date</th>
|
| 231 |
+
<th class="px-4 py-3 text-left text-xs font-medium text-gray-400 uppercase tracking-wider">Duration</th>
|
| 232 |
+
<th class="px-4 py-3 text-left text-xs font-medium text-gray-400 uppercase tracking-wider">Shots</th>
|
| 233 |
+
<th class="px-4 py-3 text-left text-xs font-medium text-gray-400 uppercase tracking-wider">Accuracy</th>
|
| 234 |
+
<th class="px-4 py-3 text-left text-xs font-medium text-gray-400 uppercase tracking-wider">Trend</th>
|
| 235 |
+
</tr>
|
| 236 |
+
</thead>
|
| 237 |
+
<tbody class="divide-y divide-gray-800">
|
| 238 |
+
<tr>
|
| 239 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm">Today</td>
|
| 240 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm">45 min</td>
|
| 241 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm">120</td>
|
| 242 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm">68%</td>
|
| 243 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm text-green-400"><i class="fas fa-arrow-up mr-1"></i> 5%</td>
|
| 244 |
+
</tr>
|
| 245 |
+
<tr>
|
| 246 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm">Yesterday</td>
|
| 247 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm">30 min</td>
|
| 248 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm">85</td>
|
| 249 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm">63%</td>
|
| 250 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm text-red-400"><i class="fas fa-arrow-down mr-1"></i> 2%</td>
|
| 251 |
+
</tr>
|
| 252 |
+
<tr>
|
| 253 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm">May 15</td>
|
| 254 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm">60 min</td>
|
| 255 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm">150</td>
|
| 256 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm">65%</td>
|
| 257 |
+
<td class="px-4 py-3 whitespace-nowrap text-sm text-green-400"><i class="fas fa-arrow-up mr-1"></i> 8%</td>
|
| 258 |
+
</tr>
|
| 259 |
+
</tbody>
|
| 260 |
+
</table>
|
| 261 |
+
</div>
|
| 262 |
+
</div>
|
| 263 |
+
</div>
|
| 264 |
+
|
| 265 |
+
<script>
|
| 266 |
+
// Simulate computer vision tracking
|
| 267 |
+
document.addEventListener('DOMContentLoaded', function() {
|
| 268 |
+
// Initialize shot chart
|
| 269 |
+
const shotCtx = document.getElementById('shotChart').getContext('2d');
|
| 270 |
+
const shotChart = new Chart(shotCtx, {
|
| 271 |
+
type: 'line',
|
| 272 |
+
data: {
|
| 273 |
+
labels: ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10'],
|
| 274 |
+
datasets: [
|
| 275 |
+
{
|
| 276 |
+
label: 'Made',
|
| 277 |
+
data: [3, 5, 7, 8, 10, 12, 14, 15, 17, 20],
|
| 278 |
+
borderColor: '#a855f7',
|
| 279 |
+
backgroundColor: 'rgba(168, 85, 247, 0.1)',
|
| 280 |
+
tension: 0.3,
|
| 281 |
+
fill: true
|
| 282 |
+
},
|
| 283 |
+
{
|
| 284 |
+
label: 'Missed',
|
| 285 |
+
data: [2, 3, 3, 4, 5, 5, 6, 6, 7, 8],
|
| 286 |
+
borderColor: '#6b7280',
|
| 287 |
+
backgroundColor: 'rgba(107, 114, 128, 0.1)',
|
| 288 |
+
tension: 0.3,
|
| 289 |
+
fill: true
|
| 290 |
+
}
|
| 291 |
+
]
|
| 292 |
+
},
|
| 293 |
+
options: {
|
| 294 |
+
responsive: true,
|
| 295 |
+
plugins: {
|
| 296 |
+
legend: {
|
| 297 |
+
position: 'top',
|
| 298 |
+
labels: {
|
| 299 |
+
color: '#e5e7eb'
|
| 300 |
+
}
|
| 301 |
+
}
|
| 302 |
+
},
|
| 303 |
+
scales: {
|
| 304 |
+
y: {
|
| 305 |
+
beginAtZero: true,
|
| 306 |
+
grid: {
|
| 307 |
+
color: 'rgba(255, 255, 255, 0.1)'
|
| 308 |
+
},
|
| 309 |
+
ticks: {
|
| 310 |
+
color: '#9ca3af'
|
| 311 |
+
}
|
| 312 |
+
},
|
| 313 |
+
x: {
|
| 314 |
+
grid: {
|
| 315 |
+
color: 'rgba(255, 255, 255, 0.1)'
|
| 316 |
+
},
|
| 317 |
+
ticks: {
|
| 318 |
+
color: '#9ca3af'
|
| 319 |
+
}
|
| 320 |
+
}
|
| 321 |
+
}
|
| 322 |
+
}
|
| 323 |
+
});
|
| 324 |
+
|
| 325 |
+
// Generate heatmap points
|
| 326 |
+
const heatmap = document.querySelector('.heatmap');
|
| 327 |
+
const heatmapWidth = heatmap.offsetWidth;
|
| 328 |
+
const heatmapHeight = heatmap.offsetHeight;
|
| 329 |
+
|
| 330 |
+
// Common shooting spots with different intensities
|
| 331 |
+
const shootingSpots = [
|
| 332 |
+
{ x: 0.2, y: 0.7, intensity: 8 }, // Left corner
|
| 333 |
+
{ x: 0.8, y: 0.7, intensity: 7 }, // Right corner
|
| 334 |
+
{ x: 0.5, y: 0.6, intensity: 15 }, // Top of the key
|
| 335 |
+
{ x: 0.3, y: 0.5, intensity: 5 }, // Left wing
|
| 336 |
+
{ x: 0.7, y: 0.5, intensity: 6 }, // Right wing
|
| 337 |
+
{ x: 0.5, y: 0.8, intensity: 10 }, // Free throw
|
| 338 |
+
{ x: 0.15, y: 0.9, intensity: 3 }, // Left baseline
|
| 339 |
+
{ x: 0.85, y: 0.9, intensity: 4 } // Right baseline
|
| 340 |
+
];
|
| 341 |
+
|
| 342 |
+
shootingSpots.forEach(spot => {
|
| 343 |
+
for (let i = 0; i < spot.intensity; i++) {
|
| 344 |
+
// Add some randomness to the position
|
| 345 |
+
const xVar = (Math.random() * 0.1) - 0.05;
|
| 346 |
+
const yVar = (Math.random() * 0.1) - 0.05;
|
| 347 |
+
|
| 348 |
+
const point = document.createElement('div');
|
| 349 |
+
point.className = 'heat-point';
|
| 350 |
+
|
| 351 |
+
// Position the point
|
| 352 |
+
const xPos = (spot.x + xVar) * 100;
|
| 353 |
+
const yPos = (spot.y + yVar) * 100;
|
| 354 |
+
|
| 355 |
+
point.style.left = `${xPos}%`;
|
| 356 |
+
point.style.top = `${yPos}%`;
|
| 357 |
+
|
| 358 |
+
// Size and color based on intensity
|
| 359 |
+
const size = 10 + (Math.random() * 10);
|
| 360 |
+
const opacity = 0.3 + (Math.random() * 0.5);
|
| 361 |
+
const hue = 270 + (Math.random() * 20 - 10); // Purple variations
|
| 362 |
+
|
| 363 |
+
point.style.width = `${size}px`;
|
| 364 |
+
point.style.height = `${size}px`;
|
| 365 |
+
point.style.backgroundColor = `hsla(${hue}, 80%, 60%, ${opacity})`;
|
| 366 |
+
|
| 367 |
+
heatmap.appendChild(point);
|
| 368 |
+
}
|
| 369 |
+
});
|
| 370 |
+
|
| 371 |
+
// Simulate camera feed and tracking
|
| 372 |
+
const enableCameraBtn = document.getElementById('enableCamera');
|
| 373 |
+
const startTrackingBtn = document.getElementById('startTracking');
|
| 374 |
+
const cameraFeed = document.getElementById('cameraFeed');
|
| 375 |
+
const trackingOverlay = document.getElementById('trackingOverlay');
|
| 376 |
+
const shotTrails = document.getElementById('shotTrails');
|
| 377 |
+
const shotCount = document.getElementById('shotCount');
|
| 378 |
+
|
| 379 |
+
let shotCounter = 0;
|
| 380 |
+
let trackingInterval;
|
| 381 |
+
|
| 382 |
+
enableCameraBtn.addEventListener('click', function() {
|
| 383 |
+
// Simulate camera activation
|
| 384 |
+
cameraFeed.innerHTML = `
|
| 385 |
+
<div class="absolute inset-0 bg-gray-900 flex items-center justify-center">
|
| 386 |
+
<div class="text-center">
|
| 387 |
+
<div class="court w-full h-full"></div>
|
| 388 |
+
</div>
|
| 389 |
+
</div>
|
| 390 |
+
`;
|
| 391 |
+
trackingOverlay.style.display = 'block';
|
| 392 |
+
enableCameraBtn.style.display = 'none';
|
| 393 |
+
startTrackingBtn.disabled = false;
|
| 394 |
+
|
| 395 |
+
// Initialize tracking overlay
|
| 396 |
+
trackingOverlay.width = trackingOverlay.offsetWidth;
|
| 397 |
+
trackingOverlay.height = trackingOverlay.offsetHeight;
|
| 398 |
+
const ctx = trackingOverlay.getContext('2d');
|
| 399 |
+
|
| 400 |
+
// Draw some initial tracking markers
|
| 401 |
+
ctx.strokeStyle = '#a855f7';
|
| 402 |
+
ctx.lineWidth = 2;
|
| 403 |
+
|
| 404 |
+
// Court lines
|
| 405 |
+
ctx.beginPath();
|
| 406 |
+
ctx.arc(trackingOverlay.width/2, trackingOverlay.height/2, trackingOverlay.width/5, 0, Math.PI * 2);
|
| 407 |
+
ctx.stroke();
|
| 408 |
+
|
| 409 |
+
ctx.beginPath();
|
| 410 |
+
ctx.moveTo(0, trackingOverlay.height/2);
|
| 411 |
+
ctx.lineTo(trackingOverlay.width, trackingOverlay.height/2);
|
| 412 |
+
ctx.stroke();
|
| 413 |
+
});
|
| 414 |
+
|
| 415 |
+
startTrackingBtn.addEventListener('click', function() {
|
| 416 |
+
if (startTrackingBtn.textContent.includes('Start')) {
|
| 417 |
+
startTrackingBtn.innerHTML = '<i class="fas fa-stop mr-2"></i> Stop Session';
|
| 418 |
+
startTrackingBtn.classList.remove('bg-purple-600');
|
| 419 |
+
startTrackingBtn.classList.add('bg-red-600');
|
| 420 |
+
startTrackingBtn.classList.remove('pulse-animation');
|
| 421 |
+
|
| 422 |
+
// Start simulated tracking
|
| 423 |
+
trackingInterval = setInterval(simulateShotTracking, 3000);
|
| 424 |
+
} else {
|
| 425 |
+
startTrackingBtn.innerHTML = '<i class="fas fa-play mr-2"></i> Start Session';
|
| 426 |
+
startTrackingBtn.classList.add('bg-purple-600');
|
| 427 |
+
startTrackingBtn.classList.remove('bg-red-600');
|
| 428 |
+
clearInterval(trackingInterval);
|
| 429 |
+
}
|
| 430 |
+
});
|
| 431 |
+
|
| 432 |
+
function simulateShotTracking() {
|
| 433 |
+
shotCounter++;
|
| 434 |
+
shotCount.textContent = shotCounter;
|
| 435 |
+
|
| 436 |
+
// Random shot result (60% make rate)
|
| 437 |
+
const madeShot = Math.random() < 0.6;
|
| 438 |
+
|
| 439 |
+
// Random shot position
|
| 440 |
+
const startX = 50 + (Math.random() * 40 - 20);
|
| 441 |
+
const startY = 80 + (Math.random() * 10);
|
| 442 |
+
const endX = 45 + (Math.random() * 10);
|
| 443 |
+
const endY = 40 + (Math.random() * 10);
|
| 444 |
+
|
| 445 |
+
// Create shot trail
|
| 446 |
+
const trail = document.createElement('div');
|
| 447 |
+
trail.className = 'shot-trail';
|
| 448 |
+
|
| 449 |
+
// Position the trail
|
| 450 |
+
const startPosX = (startX / 100) * trackingOverlay.offsetWidth;
|
| 451 |
+
const startPosY = (startY / 100) * trackingOverlay.offsetHeight;
|
| 452 |
+
const endPosX = (endX / 100) * trackingOverlay.offsetWidth;
|
| 453 |
+
const endPosY = (endY / 100) * trackingOverlay.offsetHeight;
|
| 454 |
+
|
| 455 |
+
trail.style.left = `${startPosX}px`;
|
| 456 |
+
trail.style.top = `${startPosY}px`;
|
| 457 |
+
|
| 458 |
+
// Calculate length and angle
|
| 459 |
+
const dx = endPosX - startPosX;
|
| 460 |
+
const dy = endPosY - startPosY;
|
| 461 |
+
const length = Math.sqrt(dx * dx + dy * dy);
|
| 462 |
+
const angle = Math.atan2(dy, dx) * 180 / Math.PI;
|
| 463 |
+
|
| 464 |
+
trail.style.width = `${length}px`;
|
| 465 |
+
trail.style.transform = `rotate(${angle}deg)`;
|
| 466 |
+
|
| 467 |
+
// Add to DOM
|
| 468 |
+
shotTrails.appendChild(trail);
|
| 469 |
+
|
| 470 |
+
// Animate the shot
|
| 471 |
+
setTimeout(() => {
|
| 472 |
+
trail.style.width = '0';
|
| 473 |
+
trail.style.opacity = '0';
|
| 474 |
+
trail.style.transition = 'width 0.5s ease-out, opacity 0.5s ease-out';
|
| 475 |
+
|
| 476 |
+
// Add shot marker
|
| 477 |
+
setTimeout(() => {
|
| 478 |
+
const marker = document.createElement('div');
|
| 479 |
+
marker.className = 'absolute w-4 h-4 rounded-full';
|
| 480 |
+
marker.style.left = `${endPosX}px`;
|
| 481 |
+
marker.style.top = `${endPosY}px`;
|
| 482 |
+
marker.style.backgroundColor = madeShot ? '#a855f7' : '#6b7280';
|
| 483 |
+
marker.style.transform = 'translate(-50%, -50%)';
|
| 484 |
+
marker.style.boxShadow = '0 0 10px ' + (madeShot ? '#a855f7' : '#6b7280');
|
| 485 |
+
|
| 486 |
+
shotTrails.appendChild(marker);
|
| 487 |
+
|
| 488 |
+
// Remove elements after animation
|
| 489 |
+
setTimeout(() => {
|
| 490 |
+
trail.remove();
|
| 491 |
+
marker.remove();
|
| 492 |
+
}, 3000);
|
| 493 |
+
}, 500);
|
| 494 |
+
}, 100);
|
| 495 |
+
|
| 496 |
+
// Update chart data periodically
|
| 497 |
+
if (shotCounter % 5 === 0) {
|
| 498 |
+
const madeData = shotChart.data.datasets[0].data;
|
| 499 |
+
const missedData = shotChart.data.datasets[1].data;
|
| 500 |
+
|
| 501 |
+
madeData.push(madeData[madeData.length-1] + (madeShot ? 1 : 0));
|
| 502 |
+
missedData.push(missedData[missedData.length-1] + (madeShot ? 0 : 1));
|
| 503 |
+
|
| 504 |
+
if (madeData.length > 10) {
|
| 505 |
+
madeData.shift();
|
| 506 |
+
missedData.shift();
|
| 507 |
+
}
|
| 508 |
+
|
| 509 |
+
shotChart.update();
|
| 510 |
+
}
|
| 511 |
+
}
|
| 512 |
+
|
| 513 |
+
// Toggle heatmap visibility
|
| 514 |
+
const showHeatmapBtn = document.getElementById('showHeatmap');
|
| 515 |
+
const showTrajectoryBtn = document.getElementById('showTrajectory');
|
| 516 |
+
|
| 517 |
+
showHeatmapBtn.addEventListener('click', function() {
|
| 518 |
+
heatmap.style.display = heatmap.style.display === 'none' ? 'block' : 'none';
|
| 519 |
+
});
|
| 520 |
+
|
| 521 |
+
showTrajectoryBtn.addEventListener('click', function() {
|
| 522 |
+
shotTrails.style.display = shotTrails.style.display === 'none' ? 'block' : 'none';
|
| 523 |
+
});
|
| 524 |
+
});
|
| 525 |
+
</script>
|
| 526 |
+
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=Deflook/defapp" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
|
| 527 |
+
</html>
|
prompts.txt
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
Faça um app de treino de basquete com visão computacional usando a câmera pra mapear os arremessos tipo o app homecort , faça toda a interface faça mapa de calor de pontos tudo com paleta de cores preto e roxo
|