Code Monkey home page Code Monkey logo

histogramequalization16bit's Introduction

HistogramEqualization16Bit

Histogram equalization on 16 bit images. (As of 9th February 2019) While OpenCV can perform histogram equalization, it only works on 8 bit images.

This project shows how to perform histogram equalization directly on 16 bit images (without downsampling to 8 bit).

Description

This project will read 16 bit grayscale image(HistogramEqualization\Image\16bit_grayscale.TIF), perform histogram equalization and save the output in "HistogramEqualization\Output\16bit_grayscale.TIF".

Please find the histogram equalization method in Histogram\Histogram.cpp. It is based on similar OpenCV method equalizeHist().

Prerequisites

This project uses CMAKE. This project requires you to have precompiled OpenCV library.

Installing

  1. Clone this project

  2. Edit CMakeLists.txt at the root folder of this project to set the correct OpenCV path.

    # Make sure to configure this block
    ###############################################################################
    set(OpenCV_DIR "D:/Project/DurrNDT/opencv")
    # we want to copy OpenCV bin files to build dir
    set(OpenCV_BIN_DIR "D:/Project/DurrNDT/opencv/x64/vc15/bin") 
    ###############################################################################
    
  3. If you are not using OpenCV 4.0.1, make appropriate changes in the same CMakeLists.txt

    find_package(OpenCV 4.0.1 REQUIRED)
    
  4. Configure and generate using cmake/cmake-gui

    CMAKE-GUI

  5. Find generated .sln and compile with Visual Studio.

  6. Execute HistogramEqualization.exe and check the output image in "Output\16bit_grayscale.TIF"

Running the tests

Histogram-Test is the testing project. It uses googletest framework.

Potential improvement

Speed of the method can be improve (potentially) by

  • parallel processing
  • uses OpenCL
  • uses OpenVX

I uses platform specific function in the main function. This can be improved by using C++17(among others).

Histogram equalization method depends on OpenCV.

Built With

Authors

Acknowledgments

  • Nick D'Ademo

histogramequalization16bit's People

Contributors

syaifulnizamyahya avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.