Skip to content

AfiaaAziz/SpectraVault-AI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

SpectraVault AI: Advanced Hybrid Medical Data Embedding

Overview

SpectraVault AI is a high-security Digital Image Processing (DIP) project designed to protect sensitive patient information within medical imaging. The system integrates Deep Learning for automated disease metadata extraction and employs a multi-layered cryptographic and steganographic approach to hide this data within X-ray images.

By utilizing both spatial and frequency domain techniques, the system ensures data remains imperceptible to the human eye while maintaining high robustness against common image processing attacks.

Core Features

  • AI-Driven Metadata Extraction: Uses a pretrained DenseNet-121 model (on NIH ChestX-ray14) to automatically generate diagnostic labels from ChestMNIST X-rays.
  • Cryptographic Layer: Implements AES-256-GCM encryption with PBKDF2 key derivation for secure data handling.
  • Hybrid Steganography:
    • LSB (Least Significant Bit): Spatial domain embedding for high capacity.
    • DCT (Discrete Cosine Transform): Blind frequency domain embedding for improved invisibility.
    • FFT (Fast Fourier Transform): Robust frequency domain embedding for resilience against geometric distortions.
  • Robustness Testing: Evaluation against Gaussian noise, Salt & Pepper noise, JPEG compression, and resizing.
  • Quality Assessment: Quantitative analysis using PSNR (Peak Signal-to-Noise Ratio), MSE (Mean Squared Error), and SSIM (Structural Similarity Index).

Technical Implementation

1. Data Acquisition and AI Analysis

The system loads real medical X-ray data from the MedMNIST collection. Each image is processed through an AI pipeline where the DenseNet-121 model predicts potential pathologies. This automated diagnosis, along with simulated patient demographics, forms the payload for embedding.

2. Encryption Pipeline

Before embedding, the extracted string is encrypted using AES-256 in Galois/Counter Mode (GCM). A 16-byte random salt and nonce are used to ensure that even identical patient data results in unique ciphertexts.

3. Steganographic Embedding

  • Spatial Domain: Data is hidden in the least significant bits of the pixel intensity values.
  • Frequency Domain (DCT/FFT): The image is transformed into its frequency components. Parity-based quantization is applied to mid-frequency coefficients to hide data without affecting the diagnostic quality of the image.

4. Recovery and Validation

The extraction process is "blind," meaning the original cover image is not required to retrieve the hidden metadata. Once extracted, the ciphertext is decrypted, and the integrity of the data is verified.

Performance Metrics

The system is evaluated based on the transparency of the hidden data:

  • PSNR: > 50 dB (indicates excellent image quality).
  • SSIM: > 0.99 (indicates the stego-image is structurally identical to the original).

Setup and Installation

Prerequisites

  • Python 3.8+
  • PyTorch
  • OpenCV
  • MedMNIST
  • PyCryptodome
  • Scikit-Image

Installation

  1. Clone the repository: git clone https://github.com/AfiaaAziz/SpectraVault-AI.git

  2. Install dependencies: pip install medmnist torch torchvision opencv-python matplotlib numpy pandas scipy pycryptodome scikit-image torchxrayvision

  3. Run the notebook: Open model.ipynb in Jupyter or Google Colab and execute the cells sequentially.

Future Scope

  • Integration of GANs (Generative Adversarial Networks) for more secure cover image generation.
  • Support for 3D medical data like MRI and CT scans.
  • Blockchain-based verification for audit logs.

About

A high-security medical image processing system that uses AI (DenseNet-121) for disease metadata extraction and embeds encrypted patient data into X-rays using Hybrid Steganography (LSB, DCT, and FFT).

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors