Introductie Beeldanalyse8 2013 [Compatibility Mode]
-
Upload
karunnooney3073 -
Category
Documents
-
view
215 -
download
0
Transcript of Introductie Beeldanalyse8 2013 [Compatibility Mode]
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
1/61
Introduction to QuantitativeImage Analysis
Karl-Heinz Wolf, Joost van Meel
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
2/61
A course for MSc-students Geoscience & Engineering
Learn how to recognize and measure rock textures and
specific texture features.
Learn how to deal with pitfalls in image manipulation.
Basics for 2D 3D, i.e. slices to CT-scan volumes.
WHY?
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
3/61
Content Day 1 Sources of images
Digitizing images Analysis of an image
Binary image
Processing of images
*Point Processing
*NeighborhoodProcessing
More terminology
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
4/61
Content Day 2 Special Operations
*Logical Operators*Skeleton
*Pruning*Skiz
Content day 3: Excercises
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
5/61
Sources of Images Image of a photocamera / a (digital) videocamera Microscopy Images (camera on microscope)
Electron Microscopy Images, CT-scans
Images (frames) from a video movie
Electronic information from sensors, arranged in a
2D matrix. These sensors may record electronic ormagnetic signals
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
6/61
Sources & Example of SEM
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
7/61
Core sample
Microphoto
Thin section
2-D //-nicols
Thin section2-D X-nicols
Sources & Example of Thin Sections
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
8/61
Sources & Example of CT images of pores
& grains Bentheim sst core
X-Y CT scan and
X-Z reconstruction
x
y
z
CT-scan reconstruction of grains
Pore body reconstruction
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
9/61
Sources & Example of CT images of Fracs
Orientation
Open fractures
Cemented
fractures
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
10/61
Repeating Image Pattern
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
11/61
Feret :
(breadth,
length)Roundnes,
aspect ratiodirection of an
object
This course is about obtaining quantitative data
from digitized images
1 2 3Counting Objects
Intergrowths
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
12/61
Digitizing an Image-1 If an image is digitized, it becomes subdivided Picture
Elements (pixels)
Each pixel is valued in ones and zeros
The brightness of a pixel is subdivided in 8 ones and zeros;8 bits = 1 byte
This results in 256 grey values, varying from
00000000 (black) = 0 to 11111111 (white) = 255
With a green, blue and red component, represented by three256 grey values, the colour spectrum is represented with2563 = 18609625 colours.
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
13/61
Digitizing an Image -2 A digitized image is a 2D matrix of pixels. In this matrix,
for every pixel a code is present which indicates the
greyvalue of the pixel
Image with 2 magnifications. In thelast one, one may see the pixels.
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
14/61
Analysis of an ImageThe properties of an image may be recorded on two levels :
Grey / Colour Level
Measurements are conducted directly on the image, forinstance to determine the brightness distribution in an
image
Binary Level
Here a process is used that is termed detection, or
thresholding. Pixels matching a certain criterium arerecorded in a specific part of the memory of the computer :a binary image
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
15/61
Binary image -1 Usingdetection, orthresholding it is investigated if a pixel
does or does not match a certain criterion (for instance a
specific grey value). Does the pixel match the criterion, then
the pixel is set on (1). If not, the pixel is not set (0).
The result is calledbinary, because the pixels in the resulting
image (present in another binary image) are either on (value
1) or off (value 0).
Therefore a binary image has NO grey levels !
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
16/61
Binary image -2Detection
(criterion)
:
white
Binary Image
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
17/61
Processing of Images -1For the processing of images there are generally
two different ways :
Point processing
Neighbourhood Processing
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
18/61
Processing of Images -2Point Processing
In this type of processing, the value of a pixel is
changed without taking into account the value of
neighboring pixels.
Examples of this are:
- operations wherebrightness orcontrast are
changed, or,
- an operation calleddetection (thresholding).
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
19/61
Point Processing-1+10
+10
Brightness
Brightness
0
0
255
0
10
255
10
10
255
10
20
255
Note: 00000000 (black) = 0 to 11111111 (white) = 255
Grey Image Grey Image
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
20/61
Point Processing-2x10
x10
0
0
255
0
0
255
0
10
255
0
100
255
Contrast
Contrast
Grey Image Grey Image
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
21/61
Point Processing-3Threshold
> 250
50255 Detection or
Thresholding
0
1
Grey Image Binary Image
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
22/61
Neighbourhood Processing-1This can be subdivided into :
Mathematical Morphology
Examples : Erosion, Dilation, Sharpen, Smoothing,
Edge Detection
Convolution
Examples : Gauss Filters, Sobel Filters
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
23/61
Neighbourhood Processing-2Structuring Element :
also called the operator. It is a square matrix of pixels
moving over the object.
The Structuring Element defines the behaviour of erosion
and dilation
To erode an object, every pixel must be compared with its
neighbours.
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
24/61
Neighborhood Processing-3
In abinary image every pixel can be turnedon (1) oroff
(0). The structuring element moves over the object. Thevalue of the central pixelp becomes dependent on theneighboring pixels
If a pixel in abinary image coincides with the boundary ofthe object,at least one of the neighboring pixels will have thevalue zero (0). In the erosion process,the central pixel is set tozero (0) too.
p
Structuring element
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
25/61
Neighbourhood Processing - 4 Erosion :
this proces erodes a layer of pixels around an object. Only
those pixels are removed, which have a boundary with thebackground.
It leads to a different result if one takes into account onlythe sides of the pixels (4-connected erosion) orsides andcorners (8-connected erosion).
After erosion of a pixel, theoriginal image is taken as sourcefor the next erosion step (non- iterative process).
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
26/61
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
27/61
Neighbourhood Processing-Erosion
Red = unset, Green = set
Note: The pixel matching thecentral
pixel will be marked, and later be unset
Erosion : If at least one pixel in thestructuring elementcoincides with a
pixel which is unset, the pixel matching
the central one will be unset too. If the
central pixel doesnot coincide with apixel of the object,nothing happens
P
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
28/61
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
29/61
Neighbourhood Processing-ErosionPixels marked will be unset,when all pixels of object
have been investigated
P
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
30/61
Neighbourhood Processing-ErosionP
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
31/61
Neighbourhood Processing-ErosionP
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
32/61
Neighbourhood Processing-ErosionP
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
33/61
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
34/61
Neighbourhood Processing-ErosionP
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
35/61
Neighbourhood Processing-ErosionP
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
36/61
Neighbourhood Processing-ErosionP
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
37/61
And so on......
Neighbourhood Processing-Erosion
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
38/61
Neighborhood Processing-ErosionAfter a while .....
P
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
39/61
Neighbourhood Processing-ErosionAfter another while .....
Orange pixels will be eroded in
8-connection erosion, butnot in
4-connection erosion
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
40/61
Neighbourhood Processing-ErosionFinal state of
4-connected erosion
Marked pixels will be deleted
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
41/61
Neighbourhood Processing-ErosionFinal state of8-connected erosion
Marked pixels will be deleted
This final state is also used in
Edge Detection (contouring)
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
42/61
Neighbourhood Processing - 5 Dilation : this is exactly the opposite of erosion:a layer of
pixels is added to the object.
N.B. : In general dilation after erosion will ONLY
give the original object when it is a circle!!
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
43/61
Neighbourhood Processing - 6 Open:an erosion followed by a dilation
Close:a dilation followed by a erosion
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
44/61
Neighbourhood Processing - 7 In agrey level image the central pixelp will be set to the
minimum value of the neighbouring pixels.
Edge detection in binary image : if one of the neighbouring
pixels has the value zero, the central pixel coincides with apixel on the boundary of the object. If the central pixels
matching this criterion are recorded, this results in another
binary image containing only the edge (contour) of theobject.
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
45/61
Erosion DilationExercise8-connected processes1. Erosion of the objects2. Dilation of the remainingshapes
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
46/61
More Terminology
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
47/61
More Terminology-1 Feature Count Point (FCP): the coordinates of aspecific pixel, recorded by the program as being
the location of the object. In the software used inthe course this is the lowest rightmost pixel of theobject. Other software packages may use anotherpixel for this .
Image Frame: the frame indicating which part ofthe image should be processed (red frame)
Measure Frame: the frame indicating which part of
the image should be measured (blue frame).
N. B. : Objects with their FCP outside the measure
frame are ignored in measurement !!!!
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
48/61
More Terminology-2Feret : measure of length in a certain direction
the length of the object is the longest feret,
de breadth theshortest feretFeret : think of Calliper
embayments are not takeninto account
BreadthLength
and
orientation
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
49/61
More Terminology-3Convex perimeter: The length of thepolygon fitting to the object
Think of a rubber band around the object.
Convex area: the area of the mentioned
polygon.
Area:area of the object
Orientation:orientation of the longest feret
Aspect ratio:ratio of shortest and longest feret
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
50/61
More Terminology-4 Perimeter: real perimeter, or the total length of the
boundary of the detected object
Roundness: a shape factor defined as
064.1***4
2
area
perimeterroundness
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
51/61
More Terminology-5In the roundness equation, what is the factor 1.064 for?
The perimeter is nothing more but the sum of all such pixels.
This is different from the true length of a curve.
The factor 1.064 is an empirical correction factor for this effect.
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
52/61
Program: Leica QWIN
Image files:
Group (G: ) : .AES0101
File names probably without extension !
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
53/61
DAY 2More Operations
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
54/61
Logical Operators-1Because binary images consist of pixels with value 1 or 0, it ispossible to use Boolean logical rules for adding and
subtracting the images .
The logical condition NOT must be interpreted as
INVERTED : every pixel which is set becomes unset, and
vice versa
Logical Operators-2
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
55/61
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
56/61
Skeleton Skeletonizing is a special kind of erosion, creating a
conditional thinning of the features in an image.
Exhaustive Skeletonizing reduces features to a single pixel
width, thus thinning the feature to its central framework
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
57/61
Pruning-1 Very often skeltonized features contain many branches or
dendrites, or they may be caused by the digital nature of thepixel grid.
To reduce these effects, the skeleton can be prunedby
iteratively removing the end points. Pruning is a conditional erosion, in which only those pixels are
removed, that have only one side connected to their neighbour.
Pruning can also be exhaustive, in which no branches are left,only loops
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
58/61
Pruning-2Image
Skeleton
Pruned skeleton
(non-exhaustive)
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
59/61
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
60/61
Skiz-2A group of features and the
boundary lines formed by
the Skiz operation
The dark spots are theoriginal features, the lines
represent the boundaries of
equal distance.
-
8/12/2019 Introductie Beeldanalyse8 2013 [Compatibility Mode]
61/61
Assignments