# abhijitjadhav1998/deepfake_detection_using_deep_learning architecture

> Architecture diagram of the GitHub repository abhijitjadhav1998/deepfake_detection_using_deep_learning, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-01-24). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/abhijitjadhav1998/deepfake_detection_using_deep_learning
- Repository: https://github.com/abhijitjadhav1998/deepfake_detection_using_deep_learning

## Overview

##### Main Components

a) Frontend Layer:
- Django Templates (HTML/CSS/JS)
- Face-API.js components
- Static assets (including ML model weights)

b) Backend Layer:
- Django Application Server
- ML Processing Pipeline
- File Storage System

c) Model Components:
- ResNext CNN
- LSTM Network
- Model Weights

**[Client Layer] -> [Application Layer] -> [Model Layer]**

##### Client Layer
- Web Interface
- Face Detection Components
- Static Assets

##### Application Layer
- Nginx Reverse Proxy
- Django Application Server
- File Upload Handler
- Request Router

##### Model Layer
- ResNext Feature Extractor
- LSTM Sequence Processor
- Model Weights Storage
- Prediction Pipeline

##### Flow Representation

- Video upload flow
- Frame extraction process
- Model prediction pipeline
- Result return path

##### Additional Elements

Specific technical details in annotations:
- Frame processing capacity (10-100 frames)
- Model accuracy metrics (84-93%)
- Supported file formats
- Processing constraints

Create clear separations between:
- User Interface Layer
- Application Processing Layer
- ML Model Layer
- Storage Layer

##### The scalability aspects through Docker containerization

This system design should reflect both the technical sophistication of the ML pipeline and the practical deployment considerations of the web application.

## Diagram (Mermaid)

```mermaid
graph TB
    subgraph Client
        UI["Web Interface"]:::frontend
        FD["Face Detection"]:::frontend
        SA["Static Assets"]:::frontend
    end

    subgraph Application
        NG["Nginx Reverse Proxy"]:::server
        DJ["Django Server"]:::server
        UH["Upload Handler"]:::server
        RR["Request Router"]:::server
        FS["File Storage"]:::storage
    end

    subgraph ML_Pipeline
        FE["Frame Extractor"]:::ml
        RN["ResNext CNN"]:::ml
        LS["LSTM Network"]:::ml
        PP["Prediction Pipeline"]:::ml
        MW["Model Weights"]:::storage
    end

    %% Connections
    UI --> FD
    UI --> NG
    FD --> NG
    NG --> DJ
    DJ --> UH
    DJ --> RR
    UH --> FS
    RR --> FE
    FE --> RN
    RN --> LS
    LS --> PP
    MW --> RN
    MW --> LS
    PP --> DJ
    DJ --> UI

    %% Click Events
    click DJ "https://github.com/abhijitjadhav1998/Deepfake_detection_using_deep_learning/tree/master/Django Application/project_settings/"
    click UH "https://github.com/abhijitjadhav1998/Deepfake_detection_using_deep_learning/tree/master/Django Application/ml_app/"
    click UI "https://github.com/abhijitjadhav1998/Deepfake_detection_using_deep_learning/tree/master/Django Application/ml_app/templates/"
    click FD "https://github.com/abhijitjadhav1998/Deepfake_detection_using_deep_learning/blob/master/Django Application/static/js/face-api.js"
    click SA "https://github.com/abhijitjadhav1998/Deepfake_detection_using_deep_learning/tree/master/Django Application/static/"
    click FS "https://github.com/abhijitjadhav1998/Deepfake_detection_using_deep_learning/tree/master/Django Application/uploaded_videos/"
    click NG "https://github.com/abhijitjadhav1998/Deepfake_detection_using_deep_learning/tree/master/Django Application/nginx/"
    click MW "https://github.com/abhijitjadhav1998/Deepfake_detection_using_deep_learning/tree/master/Django Application/static/json/"
    click RR "https://github.com/abhijitjadhav1998/Deepfake_detection_using_deep_learning/blob/master/Django Application/ml_app/urls.py"

    %% Styling
    classDef frontend fill:#3498db,stroke:#2980b9,color:white
    classDef server fill:#2ecc71,stroke:#27ae60,color:white
    classDef ml fill:#e74c3c,stroke:#c0392b,color:white
    classDef storage fill:#f1c40f,stroke:#f39c12,color:white

    %% Legend
    subgraph Legend
        L1["Frontend Components"]:::frontend
        L2["Server Components"]:::server
        L3["ML Components"]:::ml
        L4["Storage Components"]:::storage
    end
```
