Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
otb
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Sébastien Peillet
otb
Commits
f791da1b
Commit
f791da1b
authored
7 years ago
by
Antoine Regimbeau
Browse files
Options
Downloads
Patches
Plain Diff
DOC: cookbook recipe improvement
parent
beba601e
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Documentation/Cookbook/rst/recipes/contrast_enhancement.rst
+13
-10
13 additions, 10 deletions
Documentation/Cookbook/rst/recipes/contrast_enhancement.rst
with
13 additions
and
10 deletions
Documentation/Cookbook/rst/recipes/contrast_enhancement.rst
+
13
−
10
View file @
f791da1b
...
@@ -2,17 +2,17 @@ Visual product and contrast enhancement
...
@@ -2,17 +2,17 @@ Visual product and contrast enhancement
========================================================
========================================================
Sensor images have often a wide dynamic range. Whereas it is very helpful
Sensor images have often a wide dynamic range. Whereas it is very helpful
to have high precision to do complex processing, it is pretty hard to display
to have high precision to do complex processing, it is pretty hard to display
wide range of
dynamic, even on modern screen. The dynamic range for basic
high
dynamic
images
, even on modern screen. The dynamic range for basic
screen is of 8 bits.
Data
can contain 12 or 16 bits (or even more!).
screen is of 8 bits.
Images
can contain 12 or 16 bits (or even more!)
of data
.
The contrast enhancement application is aiming at reducing this dynamic
The contrast enhancement application is aiming at reducing this dynamic
by
compress
ing it in a smarter way than just linear compression.
by
reorganiz
ing it in a smarter way than just linear compression.
In a linear compression, compression changes the dynamic range (for instance
In a linear compression, compression changes the dynamic range (for instance
from 12 to 8 bits) but does not change the repartition of the pixel.
from 12 to 8 bits) but does not change the repartition of the pixel.
|image1| |image2|
|image1| |image2|
Here the equalization of histogram is creating a look up table in order to
Here the equalization of histogram is creating a look up table in order to
maximize the use of dynamic
s
. The target histogram is perfectly flat one.
maximize the use of dynamic. The target histogram is
a
perfectly flat one.
The gain applied on each pixel comes from the computation of the transfer
The gain applied on each pixel comes from the computation of the transfer
function :math:`T` such that :
function :math:`T` such that :
...
@@ -34,11 +34,14 @@ following use :
...
@@ -34,11 +34,14 @@ following use :
-out output_image.tif
-out output_image.tif
-spatial global
-spatial global
You can then compress your dynamic without loosing too much detail and
contrast.
Advanced parameters
Advanced parameters
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
You can see that more parameter are available in the application. Let us see
You can see that more parameter
s
are available in the application. Let us see
what there are for.
what there are for.
First what you want to equalize. There
is
two modes :
First what you want to equalize. There
are
two modes :
* luminance : you provide the application with a 3 bands image and the
* luminance : you provide the application with a 3 bands image and the
equalization will be done on a single band which will be a composition of
equalization will be done on a single band which will be a composition of
the original bands. The computed gain will then be applied on the different
the original bands. The computed gain will then be applied on the different
...
@@ -47,8 +50,8 @@ different color, conserve the hue.
...
@@ -47,8 +50,8 @@ different color, conserve the hue.
* channel : you provide the application with a n bands image and each of
* channel : you provide the application with a n bands image and each of
them are equalized independently.
them are equalized independently.
The other
main mode
is the local equalization. You can choose a window
The other
option
is the local equalization. You can choose a window
size
size
that will be use to split the image in tiles and histograms will be
that will be use to split the image in tiles and histograms will be
computed over those tiles. Gain will be interpolated between the adjacent
computed over those tiles. Gain will be interpolated between the adjacent
tiles in order to give a smooth result.
tiles in order to give a smooth result.
...
@@ -69,8 +72,8 @@ height".
...
@@ -69,8 +72,8 @@ height".
|image4|
|image4|
Finally you have the choice to ignore a particular value with the "nodata"
Finally you have the choice to ignore a particular value with the "nodata"
parameter, and also the choice to put manually your minimum and maximum value
.
parameter, and also the choice to put manually your minimum and maximum value
,
Any value out of bound will be ignored.
which can be a gain of time.
Any value out of bound will be ignored.
.. |image1| image:: ../Art/contrast1.png
.. |image1| image:: ../Art/contrast1.png
:scale: 30%
:scale: 30%
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment