Skip to content

Enhances underwater images / videos using Deep Image Processing (DIP) techniques like Dark Channel Prior and guided filtering, improving visibility and color accuracy.

License

Notifications You must be signed in to change notification settings

RyanSilva2004/UnderWater_Media_Enhancer

Repository files navigation

🌊 Open Source - Underwater Media Enhancer

Welcome to the Underwater Media Enhancement repository! This project provides a robust solution for enhancing underwater images and videos using a range of Digital Image Processing (DIP) techniques. Our mission is to improve the visibility and quality of underwater imagery by tackling common issues like haze, poor contrast, and color distortion.

Take a look at this side-by-side comparison of an original underwater image and its enhanced version using our techniques:



📸 Python Application UI

Here’s a screenshot of the Underwater Media Enhancer application in action:



🖥️ Running the Python Application

You can use the Python applications UWME_UI.py and UWME.py or the executable Underwater Media Enhancer v0.1.exe to enhance both images and videos. These tools provide a comprehensive solution for underwater media enhancement.


✨ Features

  • Dehazing: Implemented using the Dark Channel Prior (DCP) technique, this feature effectively reduces haze, significantly improving image clarity.
  • Color Correction: Balances colors to counter the blue/green tint typical of underwater photos, restoring natural hues.
  • Contrast Enhancement: Boosts contrast to bring out details and enrich overall image quality.
  • Edge Preservation: Maintains sharpness and fine details during the enhancement process using advanced filters.

🔍 Techniques and Concepts

1. Dark Channel Prior (DCP)

The DCP technique is essential for dehazing underwater images. This method leverages the observation that in most non-hazy outdoor images, at least one color channel has some pixels with very low intensities in any local region. In underwater images, DCP helps estimate haze thickness and remove it effectively.


2. Color Balance Adjustment

Due to light absorption and scattering in water, underwater images often have a blue/green cast. Our color balance adjustment technique corrects this by equalizing the histograms of the red, green, and blue channels, restoring the natural colors.


3. Contrast Limited Adaptive Histogram Equalization (CLAHE)

CLAHE enhances image contrast by working on small regions called tiles. This ensures that the histogram of each tile matches a desired distribution, avoiding over-amplification of noise while improving image detail.


4. Edge Preservation Smoothing

We use edge-preserving smoothing filters like the Bilateral Filter to smooth images without blurring edges, which is crucial for maintaining the fine details in underwater images.


🔧 Implemented Digital Image Processing Techniques

Here's a snapshot of the Digital Image Processing techniques employed in this project:

  • Image Enhancement: Core techniques to improve the visual quality of underwater images and videos.
  • Histogram Analysis: Tools for understanding and manipulating the intensity distribution of images.
  • Point Processing Techniques:
    • Histogram Equalization: Enhances contrast by redistributing intensity values.
  • Spatial Domain Enhancement: Direct manipulation of pixel values to improve image quality.
  • Filtering:
    • Non-Linear Domain Filtering: Reduces noise while preserving edges.
  • Color Image Processing: Adjusts color balance and corrects color casts.
  • Dark Channel Prior (DCP) Approach: Dehazes underwater images to improve clarity.

🚀 Getting Started

  1. Clone the repository:

git clone https://github.com/RyanSilva2004/UnderWater_Media_Enhancer.git
cd UnderWater_Media_Enhancer
  1. Install the required dependencies:

pip install -r requirements.txt
  1. Run the Jupyter Notebook:

Open the Jupyter Notebook Under_Water_Image_Enhancement.ipynb and follow the step-by-step instructions to enhance your underwater images.

  1. Run the Python Applications:

For interactive usage for images & videos , you can run the Python applications:


python UWME_UI.py
  1. Use the Executable File:

If you prefer a quick access option, run the executable Underwater Media Enhancer v0.1.exe. This will provide a user-friendly interface for both image and video enhancement.


🖥️ Running the Python Application

You can also run the Python applications UWME_UI.py or UWME.py for interactive usage, or use the executable Underwater Media Enhancer v0.1.exe for quick access. These tools support both image and video enhancement.


🤝 Contributing

We welcome all contributions to make this project even better! Whether it's adding new features, improving existing algorithms, or optimizing the code, your input is highly valued. To contribute, fork the repository, create a feature branch, and submit a Pull Request. Let's collaborate to push the boundaries of what's possible in underwater image and video enhancement!


📜 License

This project is licensed under the MIT License - see the LICENSE file for details.


🙏 Acknowledgements

  • The Dark Channel Prior technique is based on the paper by Kaiming He, Jian Sun, and Xiaoou Tang.
  • The CLAHE method is inspired by Karel Zuiderveld's work on Adaptive Histogram Equalization.
  • Edge-preserving smoothing techniques are derived from the Bilateral Filter by Carlo Tomasi and Roberto Manduchi.

About

Enhances underwater images / videos using Deep Image Processing (DIP) techniques like Dark Channel Prior and guided filtering, improving visibility and color accuracy.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published