How krisshvamsi/skin-disease-identification-using-image-analysis works
Project type and purpose
• This is a full-stack web application for automatic skin-disease identification.
• It uses a deep-learning model (CNN built with Keras/TensorFlow) to analyze uploaded images and predict skin conditions.
• The Flask framework serves the web interface and handles API requests; static assets and HTML templates provide the frontend.
File structure
• Root files:
– app.py: main Flask application (controllers/routes, model loading, inference logic).
– README.md, project_documentation.docx: documentation of purpose and design.
• Model code directory: contains Jupyter notebooks (model training, prototyping) but no production code.
• templates/: HTML files (views) for rendering pages (base.html, upload form, results view).
• static/: frontend assets (main.js, main.css) (client-side scripts for image upload, UI interactions).
README for architectural insights
• CNN model trained in notebooks, exported and loaded in Flask.
• Flask interacts with Firebase for data storage or user authentication (external service).
• Workflow: user uploads image → Flask preprocesses → CNN inference → result returned → optionally saved to Firebase.
Main components and their responsibilities
A. Web Client (Browser)
– Renders HTML/CSS/UI (static assets + templates)
– Handles user interactions (image upload, displaying results) via JavaScript
B. Flask Web Server
– Routes/Controllers in app.py
– Request validation, image preprocessing
– Invokes CNN model for inference
– Sends JSON or HTML response back to client
C. Deep-Learning Model
– Keras/TensorFlow model loaded on startup
– Performs forward pass on input image, returns prediction
D. Data Storage / External Services
– Firebase: stores user submissions, logs, or model metadata
E. Model Training Environment (offline)
– Jupyter notebooks in Model code/ for model development and retraining
Relationships & Data Flows
• Client → Flask: HTTP POST with image file
• Flask → Model: in-process function call for inference
• Model → Flask: prediction result
• Flask → Client: JSON or rendered HTML with prediction and confidence
• Flask → Firebase: write user submission & result (optional)
• Model code notebooks operate offline and feed new model artifacts into production (e.g., .h5 file)
Architectural Patterns & Design Principles
• MVC pattern:
– Model: CNN artifact loaded by Flask
– View: templates + static assets
– Controller: routes in app.py
• Monolithic deployment: one Flask service bundles web server and model in one process
• Separation of concerns: frontend resources in static/templates, backend logic in app.py, model training separate
Details
• Technologies next to components (e.g., Flask, Keras, HTML5).
• Performance considerations (e.g., GPU/CPU inference).
Summary
• Layers (presentation, application, model, data).
• Separation of concerns and external dependencies.
• Keep it as detailed as necessary for understanding, without overcrowding—use grouping and layering.
• This will give stakeholders and new engineers a clear view of how the skin-disease identification system is constructed and operates end to end.