Spaces:
Sleeping
Sleeping
dcavadia commited on
Commit Β·
3428599
1
Parent(s): cb9512d
update gradio version
Browse files- app.py +63 -85
- requirements.txt +1 -1
app.py
CHANGED
|
@@ -4,100 +4,78 @@ def create_demo():
|
|
| 4 |
title = "π¬ EndoSight AI - Development Preview"
|
| 5 |
|
| 6 |
description = """
|
| 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 |
footer = """
|
| 35 |
-
|
| 36 |
-
|
| 37 |
-
## π Development Status & Impact
|
| 38 |
-
|
| 39 |
-
β
**Model Training**: Complete with validation metrics achieved
|
| 40 |
-
π **Clinical Integration**: Active collaboration with gastroenterology clinic
|
| 41 |
-
π **Performance**: Production-ready accuracy and speed benchmarks
|
| 42 |
-
π― **Target**: Q1 2026 clinical deployment
|
| 43 |
-
|
| 44 |
-
### π€ Research Collaboration
|
| 45 |
-
|
| 46 |
-
**Academic Partner**: Universidad Central de Venezuela
|
| 47 |
-
**Research Focus**: AI-Assisted Endoscopy & Computer-Aided Diagnosis
|
| 48 |
-
|
| 49 |
-
### π Professional Contact
|
| 50 |
-
|
| 51 |
-
**Technical Lead**: Daniel Cavadia
|
| 52 |
-
**Email**: dan.cavadia@gmail.com
|
| 53 |
-
|
| 54 |
-
---
|
| 55 |
-
|
| 56 |
-
### π₯ Clinical Impact Potential
|
| 57 |
-
|
| 58 |
-
EndoSight AI aims to:
|
| 59 |
-
- **Improve detection rates** of early-stage polyps
|
| 60 |
-
- **Reduce procedure time** through automated analysis
|
| 61 |
-
- **Enhance diagnostic consistency** across practitioners
|
| 62 |
-
- **Support clinical decision-making** with quantitative measurements
|
| 63 |
-
|
| 64 |
-
---
|
| 65 |
-
|
| 66 |
-
βοΈ **Medical Disclaimer**: *Research prototype under clinical validation - not intended for diagnostic use. Always consult qualified medical professionals for medical decisions.*
|
| 67 |
-
"""
|
| 68 |
|
| 69 |
-
|
| 70 |
-
|
| 71 |
-
|
| 72 |
-
|
| 73 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 74 |
gr.Markdown(f"# {title}")
|
| 75 |
gr.Markdown(description)
|
| 76 |
|
| 77 |
-
# Video
|
| 78 |
with gr.Row():
|
| 79 |
-
|
| 80 |
-
|
| 81 |
-
|
| 82 |
-
|
| 83 |
-
height=500,
|
| 84 |
-
width=700,
|
| 85 |
-
autoplay=True, # Starts automatically
|
| 86 |
-
loop=True, # Loops like a GIF
|
| 87 |
-
show_label=True,
|
| 88 |
-
interactive=False # Users can't control playback
|
| 89 |
-
)
|
| 90 |
|
| 91 |
with gr.Row():
|
| 92 |
-
|
| 93 |
-
|
| 94 |
-
|
| 95 |
-
|
| 96 |
-
|
| 97 |
-
|
| 98 |
-
|
| 99 |
-
|
| 100 |
-
""")
|
| 101 |
|
| 102 |
gr.Markdown(footer)
|
| 103 |
|
|
|
|
| 4 |
title = "π¬ EndoSight AI - Development Preview"
|
| 5 |
|
| 6 |
description = """
|
| 7 |
+
## Advanced Gastrointestinal Polyp Detection & Analysis System
|
| 8 |
+
|
| 9 |
+
**Performance Metrics:**
|
| 10 |
+
- **88% mAP@0.5** detection accuracy
|
| 11 |
+
- **92% pixel-level** segmentation accuracy
|
| 12 |
+
- **35+ FPS** real-time processing
|
| 13 |
+
- **YOLOv8 + U-Net** dual architecture
|
| 14 |
+
|
| 15 |
+
### π₯ Clinical Capabilities
|
| 16 |
+
- Real-time polyp detection and localization
|
| 17 |
+
- Precise boundary segmentation with pixel-level accuracy
|
| 18 |
+
- Quantitative size measurement for clinical decision support
|
| 19 |
+
- Optimized for endoscopy workflow integration
|
| 20 |
+
|
| 21 |
+
### π― Technical Highlights
|
| 22 |
+
- **Multi-modal AI**: Combined object detection and segmentation
|
| 23 |
+
- **Clinical-grade performance**: Sub-second processing times
|
| 24 |
+
- **Automated measurement**: Size, area, and morphometric analysis
|
| 25 |
+
- **Real-time inference**: GPU-accelerated deployment ready
|
| 26 |
+
|
| 27 |
+
---
|
| 28 |
+
|
| 29 |
+
## π₯ Live System Demonstration
|
| 30 |
+
|
| 31 |
+
**Real-time EndoSight AI in action** - showcasing automated polyp detection, segmentation, and measurement analysis on endoscopy footage.
|
| 32 |
+
"""
|
| 33 |
|
| 34 |
footer = """
|
| 35 |
+
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 36 |
|
| 37 |
+
## π Development Status & Impact
|
| 38 |
+
|
| 39 |
+
β
**Model Training**: Complete with validation metrics achieved
|
| 40 |
+
π **Clinical Integration**: Active collaboration with gastroenterology clinic
|
| 41 |
+
π **Performance**: Production-ready accuracy and speed benchmarks
|
| 42 |
+
π― **Target**: Q1 2026 clinical deployment
|
| 43 |
+
|
| 44 |
+
### π€ Research Collaboration
|
| 45 |
+
|
| 46 |
+
**Academic Partner**: Universidad Central de Venezuela
|
| 47 |
+
**Research Focus**: AI-Assisted Endoscopy & Computer-Aided Diagnosis
|
| 48 |
+
|
| 49 |
+
### π Professional Contact
|
| 50 |
+
|
| 51 |
+
**Technical Lead**: Daniel Cavadia
|
| 52 |
+
|
| 53 |
+
---
|
| 54 |
+
|
| 55 |
+
βοΈ **Medical Disclaimer**: *Research prototype under clinical validation - not intended for diagnostic use.*
|
| 56 |
+
"""
|
| 57 |
+
|
| 58 |
+
# Create interface using Gradio 3.x syntax
|
| 59 |
+
with gr.Blocks(title="EndoSight AI") as demo:
|
| 60 |
gr.Markdown(f"# {title}")
|
| 61 |
gr.Markdown(description)
|
| 62 |
|
| 63 |
+
# Video component (simpler syntax for v3.x)
|
| 64 |
with gr.Row():
|
| 65 |
+
video = gr.Video(
|
| 66 |
+
value="demo_video.mp4",
|
| 67 |
+
label="EndoSight AI Real-time Detection & Segmentation"
|
| 68 |
+
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 69 |
|
| 70 |
with gr.Row():
|
| 71 |
+
gr.Markdown("""
|
| 72 |
+
### π What You're Seeing:
|
| 73 |
+
- **Blue bounding boxes**: Real-time polyp detection
|
| 74 |
+
- **Colored masks**: Precise segmentation boundaries
|
| 75 |
+
- **Measurement overlays**: Automated size calculations
|
| 76 |
+
- **Processing metrics**: FPS and accuracy indicators
|
| 77 |
+
- **Multi-polyp detection**: Simultaneous analysis capability
|
| 78 |
+
""")
|
|
|
|
| 79 |
|
| 80 |
gr.Markdown(footer)
|
| 81 |
|
requirements.txt
CHANGED
|
@@ -1 +1 @@
|
|
| 1 |
-
gradio==
|
|
|
|
| 1 |
+
gradio==3.50.2
|