Update app.py
Browse files
app.py
CHANGED
|
@@ -285,16 +285,68 @@ def generate_pdf(*inputs):
|
|
| 285 |
# ===============================
|
| 286 |
# INTERFACE
|
| 287 |
# ===============================
|
| 288 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 289 |
|
| 290 |
-
|
| 291 |
-
|
| 292 |
-
|
| 293 |
-
|
| 294 |
-
|
| 295 |
-
|
| 296 |
-
|
| 297 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 298 |
</div>
|
| 299 |
""")
|
| 300 |
|
|
@@ -344,4 +396,12 @@ with gr.Blocks(theme=gr.themes.Soft()) as demo:
|
|
| 344 |
blood_bacteria,severity,medication],
|
| 345 |
outputs=gr.File())
|
| 346 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 347 |
demo.launch()
|
|
|
|
| 285 |
# ===============================
|
| 286 |
# INTERFACE
|
| 287 |
# ===============================
|
| 288 |
+
# ===============================
|
| 289 |
+
# PREMIUM MEDICAL INTERFACE
|
| 290 |
+
# ===============================
|
| 291 |
+
with gr.Blocks(
|
| 292 |
+
theme=gr.themes.Soft(),
|
| 293 |
+
css="""
|
| 294 |
+
body {
|
| 295 |
+
background: linear-gradient(135deg, #e3f2fd, #f4f9ff);
|
| 296 |
+
}
|
| 297 |
|
| 298 |
+
.gr-button {
|
| 299 |
+
border-radius: 10px !important;
|
| 300 |
+
font-weight: 600 !important;
|
| 301 |
+
padding: 10px 18px !important;
|
| 302 |
+
font-size: 15px !important;
|
| 303 |
+
}
|
| 304 |
+
|
| 305 |
+
button:contains("Basic Risk Assessment") {
|
| 306 |
+
background-color: #1565c0 !important;
|
| 307 |
+
color: white !important;
|
| 308 |
+
}
|
| 309 |
+
|
| 310 |
+
button:contains("Detailed Report & Recommendations") {
|
| 311 |
+
background-color: #00838f !important;
|
| 312 |
+
color: white !important;
|
| 313 |
+
}
|
| 314 |
+
|
| 315 |
+
button:contains("Generate PDF Report") {
|
| 316 |
+
background-color: #2e7d32 !important;
|
| 317 |
+
color: white !important;
|
| 318 |
+
}
|
| 319 |
+
|
| 320 |
+
.gr-textbox, .gr-number, .gr-dropdown {
|
| 321 |
+
border-radius: 8px !important;
|
| 322 |
+
}
|
| 323 |
+
|
| 324 |
+
.header-card {
|
| 325 |
+
background: white;
|
| 326 |
+
padding: 25px;
|
| 327 |
+
border-radius: 15px;
|
| 328 |
+
box-shadow: 0 4px 15px rgba(0,0,0,0.08);
|
| 329 |
+
text-align: center;
|
| 330 |
+
}
|
| 331 |
+
|
| 332 |
+
.footer-team {
|
| 333 |
+
background: #ffffff;
|
| 334 |
+
padding: 15px;
|
| 335 |
+
border-radius: 10px;
|
| 336 |
+
margin-top: 15px;
|
| 337 |
+
text-align: center;
|
| 338 |
+
font-size: 14px;
|
| 339 |
+
box-shadow: 0 2px 8px rgba(0,0,0,0.05);
|
| 340 |
+
}
|
| 341 |
+
"""
|
| 342 |
+
) as demo:
|
| 343 |
+
|
| 344 |
+
gr.Markdown(f"""
|
| 345 |
+
<div class="header-card">
|
| 346 |
+
<img src="{LOGO_PATH}" width="130"><br><br>
|
| 347 |
+
<h1 style="color:#0d47a1;">🏥 TyphoidGuard AI</h1>
|
| 348 |
+
<h4 style="color:#37474f;">HEC Generative AI Hackathon – Pakistan</h4>
|
| 349 |
+
<h4 style="color:#00695c;">Team Chinar AI (AJK)</h4>
|
| 350 |
</div>
|
| 351 |
""")
|
| 352 |
|
|
|
|
| 396 |
blood_bacteria,severity,medication],
|
| 397 |
outputs=gr.File())
|
| 398 |
|
| 399 |
+
gr.Markdown("""
|
| 400 |
+
<div class="footer-team">
|
| 401 |
+
<b>Team Chinar AI (AJK)</b><br>
|
| 402 |
+
Anees Qumar Abbasi (Team Lead) | Sharafat Hussain | Salma Asghar |
|
| 403 |
+
Kaleem Hussain | Munazza Zahra | Kokub Khurishid
|
| 404 |
+
</div>
|
| 405 |
+
""")
|
| 406 |
+
|
| 407 |
demo.launch()
|