File size: 20,918 Bytes
6cbed0b
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>DeepSeek ECG Analysis System</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
    <style>
        @keyframes pulse {
            0%, 100% { opacity: 1; }
            50% { opacity: 0.5; }
        }
        .animate-pulse {
            animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
        }
        .ecg-line {
            position: relative;
            height: 200px;
            background-color: #f3f4f6;
            overflow: hidden;
        }
        .ecg-line::before {
            content: "";
            position: absolute;
            top: 50%;
            left: 0;
            right: 0;
            height: 1px;
            background-color: #e5e7eb;
            transform: translateY(-50%);
        }
        .ecg-wave {
            position: absolute;
            top: 50%;
            left: 0;
            width: 100%;
            height: 2px;
            background-color: #3b82f6;
            transform: translateY(-50%);
        }
        .ecg-wave::after {
            content: "";
            position: absolute;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, rgba(59, 130, 246, 1) 0%, rgba(59, 130, 246, 0) 100%);
            animation: ecgMove 8s linear infinite;
        }
        @keyframes ecgMove {
            0% { transform: translateX(-100%); }
            100% { transform: translateX(100%); }
        }
        .risk-low { background-color: #10b981; }
        .risk-medium { background-color: #f59e0b; }
        .risk-high { background-color: #ef4444; }
    </style>
</head>
<body class="bg-gray-50 font-sans">
    <div class="min-h-screen flex flex-col">
        <!-- Header -->
        <header class="bg-white shadow-sm">
            <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-4 flex items-center justify-between">
                <div class="flex items-center space-x-3">
                    <div class="w-10 h-10 rounded-full bg-blue-600 flex items-center justify-center">
                        <i class="fas fa-heartbeat text-white text-xl"></i>
                    </div>
                    <h1 class="text-xl font-bold text-gray-800">DeepSeek ECG Analysis</h1>
                </div>
                <nav class="hidden md:flex space-x-8">
                    <a href="#" class="text-blue-600 font-medium">Dashboard</a>
                    <a href="#" class="text-gray-600 hover:text-blue-600">Patients</a>
                    <a href="#" class="text-gray-600 hover:text-blue-600">History</a>
                    <a href="#" class="text-gray-600 hover:text-blue-600">Settings</a>
                </nav>
                <div class="flex items-center space-x-4">
                    <button class="p-2 rounded-full hover:bg-gray-100">
                        <i class="fas fa-bell text-gray-600"></i>
                    </button>
                    <div class="w-8 h-8 rounded-full bg-gray-300"></div>
                </div>
            </div>
        </header>

        <!-- Main Content -->
        <main class="flex-grow">
            <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-8">
                <div class="grid grid-cols-1 lg:grid-cols-3 gap-8">
                    <!-- Left Column -->
                    <div class="lg:col-span-2 space-y-6">
                        <!-- Patient Info -->
                        <div class="bg-white rounded-xl shadow-sm p-6">
                            <div class="flex items-center justify-between mb-4">
                                <h2 class="text-lg font-semibold text-gray-800">Patient Information</h2>
                                <span class="px-3 py-1 rounded-full text-xs font-medium bg-green-100 text-green-800">Active</span>
                            </div>
                            <div class="grid grid-cols-2 md:grid-cols-4 gap-4">
                                <div>
                                    <p class="text-sm text-gray-500">Name</p>
                                    <p class="font-medium">John Doe</p>
                                </div>
                                <div>
                                    <p class="text-sm text-gray-500">Age</p>
                                    <p class="font-medium">45 years</p>
                                </div>
                                <div>
                                    <p class="text-sm text-gray-500">Gender</p>
                                    <p class="font-medium">Male</p>
                                </div>
                                <div>
                                    <p class="text-sm text-gray-500">ID</p>
                                    <p class="font-medium">#ECG-2023-0042</p>
                                </div>
                            </div>
                        </div>

                        <!-- ECG Graph -->
                        <div class="bg-white rounded-xl shadow-sm p-6">
                            <div class="flex items-center justify-between mb-4">
                                <h2 class="text-lg font-semibold text-gray-800">ECG Waveform Analysis</h2>
                                <div class="flex space-x-2">
                                    <button class="px-3 py-1 text-sm bg-blue-50 text-blue-600 rounded-md">Lead II</button>
                                    <button class="px-3 py-1 text-sm bg-gray-50 text-gray-600 rounded-md">Lead V1</button>
                                    <button class="px-3 py-1 text-sm bg-gray-50 text-gray-600 rounded-md">Lead V5</button>
                                </div>
                            </div>
                            <div class="ecg-line rounded-lg overflow-hidden mb-4">
                                <div class="ecg-wave"></div>
                            </div>
                            <div class="flex justify-between text-xs text-gray-500">
                                <span>0 sec</span>
                                <span>2.5 sec</span>
                                <span>5 sec</span>
                                <span>7.5 sec</span>
                                <span>10 sec</span>
                            </div>
                        </div>

                        <!-- Analysis Controls -->
                        <div class="bg-white rounded-xl shadow-sm p-6">
                            <div class="flex flex-col md:flex-row md:items-center md:justify-between space-y-4 md:space-y-0">
                                <div>
                                    <h3 class="font-medium text-gray-800">ECG Analysis Controls</h3>
                                    <p class="text-sm text-gray-500">Upload or capture new ECG data</p>
                                </div>
                                <div class="flex space-x-3">
                                    <button class="px-4 py-2 bg-blue-600 text-white rounded-md flex items-center space-x-2 hover:bg-blue-700 transition">
                                        <i class="fas fa-upload"></i>
                                        <span>Upload ECG</span>
                                    </button>
                                    <button class="px-4 py-2 border border-gray-300 rounded-md flex items-center space-x-2 hover:bg-gray-50 transition">
                                        <i class="fas fa-camera"></i>
                                        <span>Capture Live</span>
                                    </button>
                                </div>
                            </div>
                        </div>
                    </div>

                    <!-- Right Column -->
                    <div class="space-y-6">
                        <!-- Quick Analysis -->
                        <div class="bg-white rounded-xl shadow-sm p-6">
                            <h2 class="text-lg font-semibold text-gray-800 mb-4">Quick Analysis</h2>
                            <div class="space-y-4">
                                <div class="flex items-center justify-between">
                                    <div class="flex items-center space-x-3">
                                        <div class="w-10 h-10 rounded-full bg-blue-100 flex items-center justify-center">
                                            <i class="fas fa-heart text-blue-600"></i>
                                        </div>
                                        <div>
                                            <p class="font-medium">Heart Rate</p>
                                            <p class="text-sm text-gray-500">Beats per minute</p>
                                        </div>
                                    </div>
                                    <span class="text-xl font-bold">72 <span class="text-sm font-normal text-gray-500">bpm</span></span>
                                </div>
                                <div class="flex items-center justify-between">
                                    <div class="flex items-center space-x-3">
                                        <div class="w-10 h-10 rounded-full bg-green-100 flex items-center justify-center">
                                            <i class="fas fa-wave-square text-green-600"></i>
                                        </div>
                                        <div>
                                            <p class="font-medium">PR Interval</p>
                                            <p class="text-sm text-gray-500">Atrial depolarization</p>
                                        </div>
                                    </div>
                                    <span class="text-xl font-bold">160 <span class="text-sm font-normal text-gray-500">ms</span></span>
                                </div>
                                <div class="flex items-center justify-between">
                                    <div class="flex items-center space-x-3">
                                        <div class="w-10 h-10 rounded-full bg-purple-100 flex items-center justify-center">
                                            <i class="fas fa-project-diagram text-purple-600"></i>
                                        </div>
                                        <div>
                                            <p class="font-medium">QRS Duration</p>
                                            <p class="text-sm text-gray-500">Ventricular depolarization</p>
                                        </div>
                                    </div>
                                    <span class="text-xl font-bold">88 <span class="text-sm font-normal text-gray-500">ms</span></span>
                                </div>
                            </div>
                        </div>

                        <!-- Risk Assessment -->
                        <div class="bg-white rounded-xl shadow-sm p-6">
                            <h2 class="text-lg font-semibold text-gray-800 mb-4">Risk Assessment</h2>
                            <div class="space-y-3">
                                <div>
                                    <div class="flex justify-between mb-1">
                                        <span class="font-medium">Arrhythmia</span>
                                        <span class="text-sm font-medium text-yellow-600">Medium Risk</span>
                                    </div>
                                    <div class="w-full bg-gray-200 rounded-full h-2">
                                        <div class="bg-yellow-500 h-2 rounded-full" style="width: 60%"></div>
                                    </div>
                                </div>
                                <div>
                                    <div class="flex justify-between mb-1">
                                        <span class="font-medium">Ischemia</span>
                                        <span class="text-sm font-medium text-green-600">Low Risk</span>
                                    </div>
                                    <div class="w-full bg-gray-200 rounded-full h-2">
                                        <div class="bg-green-500 h-2 rounded-full" style="width: 20%"></div>
                                    </div>
                                </div>
                                <div>
                                    <div class="flex justify-between mb-1">
                                        <span class="font-medium">Hypertrophy</span>
                                        <span class="text-sm font-medium text-red-600">High Risk</span>
                                    </div>
                                    <div class="w-full bg-gray-200 rounded-full h-2">
                                        <div class="bg-red-500 h-2 rounded-full" style="width: 85%"></div>
                                    </div>
                                </div>
                            </div>
                        </div>

                        <!-- Alerts -->
                        <div class="bg-white rounded-xl shadow-sm p-6">
                            <div class="flex items-center justify-between mb-4">
                                <h2 class="text-lg font-semibold text-gray-800">Critical Alerts</h2>
                                <span class="px-2 py-1 rounded-full text-xs font-medium bg-red-100 text-red-800">2 New</span>
                            </div>
                            <div class="space-y-4">
                                <div class="flex items-start space-x-3 p-3 rounded-lg bg-red-50 border border-red-100">
                                    <div class="mt-1">
                                        <i class="fas fa-exclamation-triangle text-red-500"></i>
                                    </div>
                                    <div>
                                        <p class="font-medium text-red-800">Possible Left Ventricular Hypertrophy</p>
                                        <p class="text-sm text-red-600">Sokolow-Lyon criteria positive (SV1 + RV5 > 3.5mV)</p>
                                    </div>
                                </div>
                                <div class="flex items-start space-x-3 p-3 rounded-lg bg-yellow-50 border border-yellow-100">
                                    <div class="mt-1">
                                        <i class="fas fa-exclamation-circle text-yellow-500"></i>
                                    </div>
                                    <div>
                                        <p class="font-medium text-yellow-800">Mild ST Depression</p>
                                        <p class="text-sm text-yellow-600">0.5mm depression in leads II, III, aVF</p>
                                    </div>
                                </div>
                            </div>
                        </div>

                        <!-- Actions -->
                        <div class="bg-white rounded-xl shadow-sm p-6">
                            <h2 class="text-lg font-semibold text-gray-800 mb-4">Recommended Actions</h2>
                            <div class="space-y-3">
                                <button class="w-full px-4 py-3 bg-blue-600 text-white rounded-md flex items-center justify-between hover:bg-blue-700 transition">
                                    <span>Generate Full Report</span>
                                    <i class="fas fa-chevron-right"></i>
                                </button>
                                <button class="w-full px-4 py-3 bg-white border border-gray-300 rounded-md flex items-center justify-between hover:bg-gray-50 transition">
                                    <span>Consult Cardiologist</span>
                                    <i class="fas fa-chevron-right"></i>
                                </button>
                                <button class="w-full px-4 py-3 bg-white border border-gray-300 rounded-md flex items-center justify-between hover:bg-gray-50 transition">
                                    <span>Schedule Follow-up</span>
                                    <i class="fas fa-chevron-right"></i>
                                </button>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </main>

        <!-- Footer -->
        <footer class="bg-white border-t border-gray-200">
            <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-6">
                <div class="md:flex md:items-center md:justify-between">
                    <div class="flex justify-center md:justify-start space-x-6">
                        <a href="#" class="text-gray-400 hover:text-gray-500">
                            <i class="fab fa-facebook-f"></i>
                        </a>
                        <a href="#" class="text-gray-400 hover:text-gray-500">
                            <i class="fab fa-twitter"></i>
                        </a>
                        <a href="#" class="text-gray-400 hover:text-gray-500">
                            <i class="fab fa-linkedin-in"></i>
                        </a>
                    </div>
                    <div class="mt-8 md:mt-0 text-center md:text-right">
                        <p class="text-sm text-gray-500">&copy; 2023 DeepSeek ECG Analysis System. All rights reserved.</p>
                    </div>
                </div>
            </div>
        </footer>
    </div>

    <script>
        // Simulate ECG analysis
        document.addEventListener('DOMContentLoaded', function() {
            // Simulate analysis progress
            const simulateAnalysis = () => {
                const analysisItems = document.querySelectorAll('.ecg-wave, .risk-low, .risk-medium, .risk-high');
                analysisItems.forEach(item => {
                    item.classList.add('animate-pulse');
                });
                
                setTimeout(() => {
                    analysisItems.forEach(item => {
                        item.classList.remove('animate-pulse');
                    });
                    
                    // Show completion message
                    const alertDiv = document.createElement('div');
                    alertDiv.className = 'fixed bottom-4 right-4 px-6 py-3 bg-green-100 border border-green-200 text-green-800 rounded-lg shadow-lg flex items-center space-x-2';
                    alertDiv.innerHTML = `
                        <i class="fas fa-check-circle text-green-600"></i>
                        <span>ECG analysis completed successfully!</span>
                    `;
                    document.body.appendChild(alertDiv);
                    
                    setTimeout(() => {
                        alertDiv.remove();
                    }, 5000);
                }, 3000);
            };
            
            // Trigger analysis when upload or capture buttons are clicked
            const analysisButtons = document.querySelectorAll('button');
            analysisButtons.forEach(button => {
                button.addEventListener('click', simulateAnalysis);
            });
            
            // ECG wave animation
            const ecgWave = document.querySelector('.ecg-wave');
            if (ecgWave) {
                setInterval(() => {
                    // Randomly add abnormalities to the ECG wave
                    if (Math.random() > 0.7) {
                        ecgWave.style.height = '4px';
                        ecgWave.style.backgroundColor = '#ef4444';
                        setTimeout(() => {
                            ecgWave.style.height = '2px';
                            ecgWave.style.backgroundColor = '#3b82f6';
                        }, 300);
                    }
                }, 2000);
            }
        });
    </script>
<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=echo3700/deepseek-ecg-analysis" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
</html>