简体   繁体   中英

Localized Adaptive Contrast enhancement on opencv and python

I am trying to do image enhancement on different types of images. I have tried a lot of different methods but usually, it works only on one image but fails on a different image. I am new to Image Processing so it difficult for me to understand How it needs to be done. I am posting the input images and desired output.

Input 1:

输入1

output 1:

输出1

Input 2:

输入2

output 2:

输出2

Input 3:

输入3

output 3:

输出3

Input 4:

Input4

Output 4:

输出4

I have tried CLAHE , Adaptive Thresholding , Histogram Equilization , Auto Brightness and Contrast adjustment , Adaptive Integral Enhancement , and many more things. Nothing is working on all the images. My assumption is I need to implement some kind of Local Adaptive Contrast Enhancement, But then again I may be wrong. It would be of a great help if anyone could help me out with this problem.

As fmw42 said, you potentially need to work on gray level images. So the suggestion was to convert to grayscale and invert as needed. I can suggest that you convert to Y Cb Br and apply on Y, and keep Cb Cr as is and see whether this works. This is the method I would use, say, to apply histogram equalization to a color image. CLAHE should do the trick for the gray level work.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM