Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix picture path for mp11 #11

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions src/wb/mp/11/description.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -35,39 +35,39 @@ For images that represent the full color space, we expect an image's histogram t
This means that we expect the bin values in the histogram to be `256/pixel_count`.
This algorithm adjust an image's histogram so that all bins have equal probability.

![image](/mp/11/imgs/image.png "thumbnail")
![image](./imgs/image.png "thumbnail")

We first need to convert the image to gray scale by computing it's luminosity values.
These represent the brightness of the image and would allow us to simplify the histogram computation.

![Gray](/mp/11/imgs/gray.png "thumbnail")
![Gray](./imgs/gray.png "thumbnail")

The histogram computes the number of pixels having a specific brightness value.
Dividing by the number of pixels (width * height) gives us the probability of a luminosity value to occur in an image.

![OrigProb](/mp/11/imgs/orig_prob.png "thumbnail")
![OrigProb](./imgs/orig_prob.png "thumbnail")


A color balanced image is expected to have a uniform distribution of the luminosity values.

This means that if we compute the Cumulative Distribution Function (CDF) we expect a linear curve for a color equalized image.
For images that are not color equalized, we expect the curve to be non-linear.

![origcdf](/mp/11/imgs/orig_cdf.png "thumbnail")
![origcdf](./imgs/orig_cdf.png "thumbnail")

The algorithm equalizes the curve by computing a transformation function to map the original CDF to the desired CDF (the desired CDF being an almost linear function).

![newcdf](/mp/11/imgs/new_cdf.png "thumbnail")
![newcdf](./imgs/new_cdf.png "thumbnail")

The computed transformation is applied to the original image to produce the equalized image.

![newimg](/mp/11/imgs/new_img.png "thumbnail")
![newimg](./imgs/new_img.png "thumbnail")


Note that the CDF of the histogram of the new image has been transformed into an almost
linear curve.

![compare](/mp/11/imgs/compare.png "thumbnail")
![compare](./imgs/compare.png "thumbnail")

## Implementation Steps

Expand Down