DeepPulse is an advanced educational and research platform for visualizing and analyzing physiological signals. Combining medical-grade signal processing with AI-powered interpretation using Google Gemini, DeepPulse provides interactive learning and analysis tools for medical students, researchers, and healthcare professionals.
DeepPulse provides professional-grade visualization and AI-assisted analysis of physiological signals including:
- Cardiac signals: ECG (electrocardiogram), heart rate variability
- Respiratory signals: Respiration waveforms, breathing patterns
- Neural signals: EEG (electroencephalogram) and other biosignals
- Other physiological data: Blood pressure, pulse oximetry, and more
- Medical-grade visualization with TRUE calibration (25mm/s, 10mm/mV for ECG)
- AI-driven analysis powered by Google Gemini 3.0 Flash
- Interactive learning modes including hints and diagnostic quizzes
- Multi-signal support for comprehensive physiological analysis
DeepPulse integrates with PhysioNet, the world's largest repository of open-source physiological data.
Supported Databases:
- PTB Diagnostic ECG Database (
ptbdb): 12-lead ECG recordings with clinical diagnoses - MIT-BIH Arrhythmia Database (
mitdb): Benchmark arrhythmia database - European ST-T Database (
edb): ST and T-wave changes - MIMIC-III Waveform Database: ICU patient monitoring data
- And many more via PhysioNet search
Data Access:
- Uses
wfdb(Waveform Database) Python library - Local caching for fast repeated access
- Automatic signal categorization and metadata extraction
Modern web application built with:
- React 19 with Vite for fast development
- SVG-based rendering for medical-grade signal visualization
- Medical calibration standards: Pixel-perfect 1mm/5mm grids
- Responsive design with horizontal scrolling for long recordings
- Real-time updates and interactive controls
- FastAPI: Modern Python web framework
- RESTful API: Clean separation of concerns
- Google Gemini 3.0 Flash: Multimodal AI for signal interpretation
- wfdb Integration: Direct PhysioNet database access
- Smart caching: Persistent local storage
backend/app/main.py: FastAPI application and API endpointsbackend/app/services/ai_service.py: Gemini AI integration and prompt engineeringbackend/app/services/data_service.py: PhysioNet data loading and managementfrontend/src/components/SignalViewer.jsx: Medical-grade SVG signal rendererfrontend/src/components/Dashboard.jsx: Main application interface
- Python 3.10+
- Node.js 18+ and npm
- Google Gemini API Key (get from Google AI Studio)
-
Clone the repository:
git clone https://github.com/Graceliying82/DeepPulse.git cd DeepPulse -
Backend Setup:
cd backend pip install -r requirements.txt -
Configure API Key: Create
backend/.envfile:GOOGLE_API_KEY=your_gemini_api_key_here
-
Frontend Setup:
cd frontend npm install
Start Backend (Terminal 1):
cd backend
uvicorn app.main:app --reload --port 8000Start Frontend (Terminal 2):
cd frontend
npm run devAccess the application:
- Frontend: http://localhost:5173
- Backend API: http://localhost:8000
- API Documentation: http://localhost:8000/docs
- TRUE calibration: 25mm/s time scale, 10mm/mV amplitude (ECG standard)
- Professional grid: 1mm minor lines, 5mm major lines matching medical paper
- DPI-normalized: Accurate pixel-to-millimeter conversion (96 DPI standard)
- Calibration pulse: Standard 1mV reference marker
- Multi-lead display: Synchronized scrolling across all channels
- Print-ready: SVG vector format for documentation
- Full Analysis Mode: Comprehensive clinical interpretation
- Hints Mode: Educational guidance using Socratic method
- Quiz Mode: Interactive diagnostic challenges with explanations
- Multi-signal support: Cardiac, respiratory, neural, and other physiological signals
- Context-aware: Considers patient metadata and signal characteristics
- Database discovery: AI-powered PhysioNet database recommendations
- Smart downloads: Automatic categorization and validation
- Local storage: Persistent caching with
data/directory - Record browser: Easy navigation through downloaded signals
- Batch processing: Download multiple records efficiently
- Switch analysis modes on the fly (Full/Hints/Quiz)
- Progressive hints that don't reveal the diagnosis
- Multiple-choice quizzes with detailed explanations
- Real patient data for authentic learning experiences
- Instant feedback from AI tutor
- SVG patterns for consistent 1mm/5mm medical grid
- Independent minor/major grid layers for precise styling
- Automatic baseline centering and amplitude scaling
- Downsampling for performance (500 points/second target)
- Horizontal scrolling for recordings of any length
- Time markers every 1 second with clear labels
- Time axis: 25 mm/s (1 small square = 0.04s = 40ms)
- Amplitude axis: 10 mm/mV (1 small square = 0.1 mV)
- Grid: Major lines every 5mm (bold), minor lines every 1mm (thin)
- Calibration: 1mV pulse, 0.2s duration (standard reference)
- Client-side SVG rendering (no server round-trips)
- Efficient downsampling prevents DOM bloat
- React memos and optimized re-renders
- Smart caching reduces repeated downloads
- Lazy loading for large datasets
DeepPulse/
βββ backend/ # FastAPI backend
β βββ app/
β β βββ main.py # API endpoints
β β βββ services/ # Business logic
β β βββ ai_service.py # Gemini AI integration
β β βββ data_service.py # PhysioNet data access
β βββ tests/ # Backend tests
β βββ requirements.txt # Python dependencies
β
βββ frontend/ # React frontend
β βββ src/
β β βββ components/ # React components
β β β βββ Dashboard.jsx # Main UI
β β β βββ SignalViewer.jsx # Medical signal renderer
β β βββ App.jsx # Root component
β β βββ main.jsx # Entry point
β βββ package.json # Node dependencies
β
βββ data/ # Local signal storage
β βββ cardiac/ # ECG and heart data
β βββ respiratory/ # Breathing signals
β βββ neural/ # EEG and brain data
β
βββ README.md # This file
Backend:
cd backend
pytestFrontend:
cd frontend
npm run lintFastAPI provides automatic interactive API docs at:
- Swagger UI: http://localhost:8000/docs
- ReDoc: http://localhost:8000/redoc
Contributions welcome! Areas of interest:
- Additional signal types and visualizations
- Enhanced AI analysis prompts
- Interactive measurement tools
- Export formats (PDF, DICOM, etc.)
- Real-time monitoring capabilities
This project is licensed under the MIT License - see the LICENSE file for details.
DeepPulse is an educational and research tool. AI-generated analyses are based on anonymized PhysioNet data and should be independently verified before any clinical application.
- PhysioNet for providing open-access physiological data
- Google Gemini for multimodal AI capabilities
- wfdb library maintainers for PhysioNet integration
- Medical signal processing community for standards and best practices
Built with β€οΈ for medical education and research