Sei sulla pagina 1di 93

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Fractals I
Overview and applications

Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Brief history
1877 - George Cantor proved that the infinite number of points in a one-dimensional line segment is equal to the number of points inside any 3D cube. Cantor himself wrote: I see it but I dont believe it Late 1800 - the gallery of monsters unusual analytic structures such as the Weierstrass curve, the cantor dust, the Sierpinski gasket and the Menger sponge 1918 - Gaston Julia: Mmoires sur litrations des fonction rationnelles 1919 - Theory about Hausdorff-Besicovitch dimension (metrics) 1967 - Mandelbrot published how long is the coast of britain?
Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

The gallery of monsters Cantor set (or dust) Hilbert-Peanos curve Kochs stars Sierpinski triangles
Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

What are they?

Fractals are mathematical functions with some distinctive features: Invariance or self-similarity Thin structure Irregularity Hausdorff dimension topological dimension

Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Invariance or self-similarity
A fractal F is an object with subsets that look like (or are identical to) the whole i.e.: a fractal is a collection of zoomed parts of itself.

Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Thin structure

Fractals show details at every resolution They are resolution independent They cannot be represented with simple mathematical functions: they are recursive functions

Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

E.g. fine resolution

Zoomed

Original image

Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

First fractals: Cantor set


Is a construction involving only the real numbers between 0 and 1 Is defined by repeatedly removing the middle thirds of line segments
It starts by removing the middle third from the unit interval [0, 1], leaving [0, 1/3] [2/3, 1] Next, the "middle third" of each of the remaining intervals is removed This process is continued ad infinitum

The Cantor set consists of all points in the interval [0, 1] that are not removed at any step in this infinite process
Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

First fractals: Cantor set

Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

First fractals: Cantor set


Characteristics:
The nth iteration of the algorithm that produces the Cantor set yields 2n intervals, each of them of length 3n Since the actual Cantor set is the infinite intersection of these iterations, it follows that the intervals shrink to zero size as n approaches infinity One of the most fascinating properties of the Cantor set is that it is uncountable

Elaborazione di Immagini e Video A.A. 2010-11

10

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

First fractals: Sierpinski triangle


Its a fractal triangle Construction:
Start with any triangle in a plane (usually an equilateral triangle) Shrink the triangle by 1/2, make two copies, and position the three shrunken triangles so that each triangle touches the two other triangles at a corner Repeat step 2 with each of the smaller triangles

Elaborazione di Immagini e Video A.A. 2010-11

11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Affine transform
Fractals are usually created using affine transformations. A typical affine transformation in the {x,y} plane consist of a linear system:

X a 11 T = = Y a 21

a 12 x b1 y + b = A x + b a 23 2

Where ai are rotation and scaling coefficients while bi force translations


Elaborazione di Immagini e Video A.A. 2010-11

12

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Some kind of affine transforms

Among infinite possibilities of affine transforms, those used by fractals are similar i.e. inner angles do not change:
Homothety Rotations Translations Symmetries

Elaborazione di Immagini e Video A.A. 2010-11

13

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Homothety It is defined by a matrix A:


K A = 0 0 K

It is a scale shift: it transforms a geometrical figure into another congruent scaled geometrical figure

Elaborazione di Immagini e Video A.A. 2010-11

14

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Example

Elaborazione di Immagini e Video A.A. 2010-11

15

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Rotations

Are defined by a rotation matrix A:

cos A = sin

sin cos

It rotates a figure by an angle

Elaborazione di Immagini e Video A.A. 2010-11

16

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Example

/6 rotation
Elaborazione di Immagini e Video A.A. 2010-11

17

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Translations

They are defined by a matrix A=I and b0


1 A = 0 t1 b = t2 0 1

Elaborazione di Immagini e Video A.A. 2010-11

18

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Example

Translation:

+ 1 b = 2
19

Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Symmetries
They are transforms that reflect figures by reference
e.g: Central Symmetry

Elaborazione di Immagini e Video A.A. 2010-11

20

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Affine transforms composition Affine transform can be composed Using a known set of affine transforms and iterating them infinitely we produce a fractal
i T , n ( ) = { 1 ( ), 2 ( ),...., ( ) m }
=
n

( ), n

Elaborazione di Immagini e Video A.A. 2010-11

21

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Why fractals?
They were born as a more precise representation of nature, when Euclidian geometry seems to be inappropriate. E.g.:
Coastlines Leafs Neural Networks Arteries & Veins

Elaborazione di Immagini e Video A.A. 2010-11

22

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Measuring a coastline
Measuring a coastline using standard metrics is impossible because every time the measure unit become smaller, the size of the coastline increases. This happens because when we decrease the unit we discover other details, like gulfs, bays, harbors and so on. So it seems that length is dependent from the unit of measure chosen, which is not true in Euclidian geometry. A coastline is not a monodimensional curve, it is a FRACTAL!!
Elaborazione di Immagini e Video A.A. 2010-11

23

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Example

As with any curve, the obvious answer for the mathematician is to approximate the curve with a polygonal path, each side of which is of length . Then by evaluating the length of these polygonal paths as 0, we expect to see the length estimate approach a limit. Unfortunately, it appears that for coastlines the approximated length l
Elaborazione di Immagini e Video A.A. 2010-11

24

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Fractal dimension
Fractals can be thought as an object with fractional dimension Fractal dimension is not equal to topological (classical) dimension: it is defined by Hausdorff dimension
In fact, Mandelbrot defined fractals as geometrical entities with fractional dimension where: topological dimension < Hausdorff dimension

Elaborazione di Immagini e Video A.A. 2010-11

25

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Example: Koch curve

Elaborazione di Immagini e Video A.A. 2010-11

26

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Kochs stars

Infinite perimeter Finite area (limited inside circumscribed circle)


Elaborazione di Immagini e Video A.A. 2010-11

27

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Proof
1 = 3l
l 3 l2 1 = l = 3 2 2 4
2 = 34 2 = 1
3
l 4 4 = 3l = 1 3 3 3
2

3 l h = l2 = l 2 2

(l 3 ) +
4

1 l2 3 = 1 + 3 9 4
4 3
2

3 3 = 1 1 + 9

42 l = 4 4 3 = 3l 2 = 1 9 3

3 = 2 +

(l 9 )
4

3 = 2

1 l2 + 34 2 9 4

3 4 3 = 1 1 + + 3 2 9 9


28

Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Proof
4 n = 1 3
n 1

4 = 3l 3

n 1

3 n = 1 1 + 9

4 9 n =1

n 1

Geometric series q<1, convergent!

Elaborazione di Immagini e Video A.A. 2010-11

29

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Fractal dimension
When the fractal growing law is known, we can easily compute its fractal dimension i.e. Koch algorithm.

N=number of copies=4 R=scaled factor=1/3


Is replaced by..

D =log(N)/log(1/R)
=log(4)/log(3)=1.26
Elaborazione di Immagini e Video A.A. 2010-11

30

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Deterministic fractals
They are completely defined by a known function. e.g.: Sierpinsky triangle
1. Take the half point of every side 2. Join them to form another triangle 3. Repeat step 1 for every sub triangle obtained
31

Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Probabilistic fractals
There is a probability p associated with the creating function e.g.: Sierpinsky random triangle
1. Take the half point of every side 2. Join them to form another triangle 3. Repeat step 1 with p probability for every sub triangle
Elaborazione di Immagini e Video A.A. 2010-11

32

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Chaos theory
Fractal theory is strictly joined to chaos theory In fact, we can state that fractal is the geometry of chaos The chaos theory is a mathematical theory that tries to exploit extremely complex problems An event can be said chaotic when the results of its evolution are unpredictable:
E.g.:
Meteorological events butterfly effect Error propagation fixed digit math Quantistic effects subatomic movements

Elaborazione di Immagini e Video A.A. 2010-11

33

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Chaos game
Select three non-colinear points to be the vertices of the largest triangle Randomly select one of these points and call its coordinates (x,y) Randomly select a point inside the triangle and draw a point halfway between (x,y) and the vertex Redefine (x,y) to be the coordinates of the new point and repeat the last step

Elaborazione di Immagini e Video A.A. 2010-11

34

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Chaos game

Elaborazione di Immagini e Video A.A. 2010-11

35

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Chaos game
i = 10 i = 100 i = 1000

i = 100000

http://trevorstone.org/applets/Chaos Game.html 36

Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Some fields in which fractals are used..

1.Reality representation
Neural networks Organic structures Mineral textures Landscapes

2.Synthetic Video 3.Games & virtual reality

Elaborazione di Immagini e Video A.A. 2010-11

37

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Synthetic reality example


How to render a landscape with fractal theory?
Start with a single horizontal line segment. Repeat for a sufficiently large number of times { Repeat over each line segment in the scene { Find the midpoint of the line segment. Displace the midpoint in Y by a random amount. Reduce the range for random numbers. } }

2D 3D
Elaborazione di Immagini e Video A.A. 2010-11

38

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Landscape generator

Elaborazione di Immagini e Video A.A. 2010-11

39

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Fractals II
Iterated Function Systems Using fractal theory for image and video compression

Elaborazione di Immagini e Video A.A. 2010-11

40

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

From fractals to I.F.S.


I.F.S. (Iterated Function Systems) are the way to exploit fractal theory for image (or signal) compression purpose Affine transforms can be used to find hidden relationship between the image and its subparts These transformation are stored

Elaborazione di Immagini e Video A.A. 2010-11

41

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

An I.F.S. simple example


The Barnsley I.F.S. copy machine: 1. 2. 3. Take a sheet with a picture as input Make 3 copy (properly scaled) of it, placed on the vertex of an equilateral triangle Take this copy as output and repeat step 1
Barnsley et al., US patent No.5,065,447, Nov.12 1991 http://www.pat2pdf.org/patents/pat5065447.pdf A.E.Jacquin Image Coding Based on a Fractal Theory of Iterated Contractive Image Transformations, IEEE Transactions on Image Processing , Vol.1, No.1, Jan 1992
Elaborazione di Immagini e Video A.A. 2010-11

42

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

I.F.S. copy machine

Elaborazione di Immagini e Video A.A. 2010-11

43

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

I.F.S. Machine
We can notice some peculiarities:
Copies converge to a stable image (attractor) Source image (the smile) does not have influence on the target image (Sierspinski triangle) Different transforms lead to different attractors Images obtained with this method leads to images which have details at every resolution. In this sense these images can be called fractals Chosen transforms must be contractive

Elaborazione di Immagini e Video A.A. 2010-11

44

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Inverse problem
We can use IFS for compression purpose solving the inverse problem. i.e.:
Identify the image to be compressed as attractor Look for affine transforms that lead to this attractor

J.Kominek, Advances in Fractal Compression for Multimedia Applications, Multimedia Systems, Vol.5,No.4, July 1997
Elaborazione di Immagini e Video A.A. 2010-11

45

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Inverse problem
So, the inverse problem is how to build a contractive transform which has the image as the attractor Attractor

(.)
k iterations

source image

N.B.: a linear transform is said to be contractive if we can take any 2 point from the transform domain, P1 and P2 and their distance is: d(w (P1 ) ; w (P2 )) < s d(P1 ; P2) with s < 1
46

Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Inverse problem
Does the inverse problem always leads to a stable solution?
i.e.: do we ALWAYS find a set of transforms that applied to a whatever source image lead to the wished target image?

The answer for this question came from the Barnsley collage theorem that state:
if we use a set of contractive affine transforms and iterate them infinitely we are assured that those transforms leads to the desired image

Elaborazione di Immagini e Video A.A. 2010-11

47

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Inverse problem

Premises: Inverse problems have no simple solution With the actual state of art it cannot be performed automatically SOLUTION: P.I.F.S.

Elaborazione di Immagini e Video A.A. 2010-11

48

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

P.I.F.S.

Rather than force self-similarity to the whole image itself, we allow the self-similarity to be found only for subpart of the image. These concept leads to P.I.F.S. which is an acronym that stands for Partitioned Iterated Function Systems

Elaborazione di Immagini e Video A.A. 2010-11

49

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

P.I.F.S.
We consider an image to be composed by a set of copies of subparts of itself properly transformed (see affine transforms) What we obtain with this technique is usually an approximation of the desired image. So this is a LOSSY technique

Elaborazione di Immagini e Video A.A. 2010-11

50

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Self-similarity

Elaborazione di Immagini e Video A.A. 2010-11

51

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Partitioning
To process images with PIFS, we first need to partition it the image is partitioned into a set of range blocks usually non-overlapping A D partition of domain blocks is settled up using blocks greater than range blocks

Elaborazione di Immagini e Video A.A. 2010-11

52

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Domain pool
For each domain block we build a set of contractive transform The union of those transformed domains is called domain pool Let suppose we have n domain blocks and m transforms, the dimension of the domain pool is: nxm

Elaborazione di Immagini e Video A.A. 2010-11

53

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

The goal
Approximate every range block with a domain block properly transformed Store only information about which domain and transform is used

Elaborazione di Immagini e Video A.A. 2010-11

54

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Simple PIFS
The image is partitioned into n RxR range blocks (usually square) For each range block, we look for the domain block DxD that best matches

Elaborazione di Immagini e Video A.A. 2010-11

55

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Distortion measure
How can we say that a domain block is better than another one? We use a distortion distance:
MSE RMS EMD

Elaborazione di Immagini e Video A.A. 2010-11

56

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Standard transforms used


Affine transforms
Generally 8 isometries + homothethies and translations

Massive transforms
Luminance shift () Contrast scaling () Color reversal

Elaborazione di Immagini e Video A.A. 2010-11

57

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Affine transforms
Identity Vertical reflection (mirroring)

Horizontal reflection

Rotation 180

Rotation 90

Rotation 90

Reflection 1. diag

Reflection 2. diag

Elaborazione di Immagini e Video A.A. 2010-11

58

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Massive transforms

g0 - absorption - contrast scaling - luminance shift


Elaborazione di Immagini e Video A.A. 2010-11

59

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Transforms
Given an image , we can divide transform into 3 main parts:
M (massive) S (shuffle) G (geometric)

so:

= M o S o G = M (S (G (

))) = ( G ( )) +

Elaborazione di Immagini e Video A.A. 2010-11

60

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

How to search domain blocks


Once the range and domain block dimension is chosen, for every range block a DxD window scans the image for each position, the resulting domain block with all its transformations is compared to the range block through a distortion measure
When the best set of domain&transform is found the code is stored.

Elaborazione di Immagini e Video A.A. 2010-11

61

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Searching methods
Due to the huge amount of data to be compared, a good search policy is needed

Elaborazione di Immagini e Video A.A. 2010-11

62

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Block definition
To speed up searching algorithm, blocks are defined into 3 classes:
Shade blocks: mainly composed by uniform areas (a). They are build at decoding time using only massive transforms Edge blocks: there is a big gradient thru the block (c). For those an exhaustive searching is needed. Midrange blocks: middle way between edge and shade (b). A good policy should be chosen to keep a good quality/compression ratio.

Elaborazione di Immagini e Video A.A. 2010-11

63

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Feature space

To limit coding time, we can restrict the search area to a portion of the image usually a surrounding of the range block This area is called feature space

Elaborazione di Immagini e Video A.A. 2010-11

64

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Quadtree subdivision
To speed up encoding, another useful technique is the quadtree subdivision. The goal of this technique is to use range block with no fixed dimension, and to decrease dimension only for strong edge parts of the image. With this technique we usually obtain some big shade blocks and a lot of smaller edge block.

Elaborazione di Immagini e Video A.A. 2010-11

65

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Quadtree
Subdivision must not always be squared Other polygons can be used, generally improving quality

Elaborazione di Immagini e Video A.A. 2010-11

66

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Decoding
The fractal code is a collection of transformation parameters, e.g.:
For the range block n take the domain block with offse t 4 (10,48), rotate it by 90and apply a luminance shift of +80

NB: there is no range or domain block size definition We start with any image and iterating the process the initial image converges to the desired (previously coded) image

Elaborazione di Immagini e Video A.A. 2010-11

67

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Comparison
BMP: 901KB Original JPG: 56 KB dB PSNR: 46.79

STN (PIFS): 56KB PSNR: 53.97 dB

IFS: 153KB 27.00 dB

PSNR:

Elaborazione di Immagini e Video A.A. 2010-11

68

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Fractal zoom

Probably the most important feature of fractal encoding is the possibility to easily produce scaled image versions Once coded the original image, fractal code has all the information to be expanded

Elaborazione di Immagini e Video A.A. 2010-11

69

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Fractal zoom
In fact, due to the fact that fractal code isnt anything else than linear transforms:

X = Ax + b
Zoom can be achieved just by multiplying it by a scaling factor! In practice, zoom is obtained during the decoding process using domain and range blocks bigger than those used at encoding time
Elaborazione di Immagini e Video A.A. 2010-11

70

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Fractal zoom

The technique used for zooming images are usually interpolative or though replication Fractal zoom results, at big scaling factor, more realistic than those techniques

Elaborazione di Immagini e Video A.A. 2010-11

71

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Fractal zoom

Lena 5x bicubic

Lena 5x fractal
Elaborazione di Immagini e Video A.A. 2010-11

72

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Fractal zoom
NB: using fractal zoom we cannot obtain information that was unknown at encoding time! We might achieve a more realistic zoom than that obtained though replication or interpolation Information storage is limited by the Nyquist theorem; once digitized, an image is bound to the information caught by the frequency samples. So, for example, if we fractalize a face, we wont be able to see cells or atoms by zooming it!!!

Elaborazione di Immagini e Video A.A. 2010-11

73

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Infinite compression?
Fractal zoom is the origin of the misunderstanding about fractal compression Because an IFS generates detail down to the infinitesimal, one can claim infinite compression. However, the legitimate use of compression ratio applies in the reverse direction - in beginning with a digitized image and seeking an alternate representation that requires less information. We are not generating an image, we are approximating it

Elaborazione di Immagini e Video A.A. 2010-11

74

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Fractal compression issues


Promising lossy technology but: does not meet initial expectations
promise of 10,000:1 compression (real: 8:1 to 50:1) very slow, compared to other techniques image dependant Barnsley's patent referred to:
Graduate Student Algorithm 1. Acquire a graduate student. 2. Give the student a picture and a room with a graphics workstation. 3. Lock the door. 4. Wait until the student has reverse engineered the picture. 5. Open the door.

The technology is patented


Elaborazione di Immagini e Video A.A. 2010-11

75

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Fractal video

We can extend the fractal compression technique for video processing. There are two ways to do that:
1. Predictive compression 2. 3D PIFS (Partial iterated function system) compression

Elaborazione di Immagini e Video A.A. 2010-11

76

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Predictive compression

PIFS predictive compression tries to use the previous frame as the domain pool for the next in a video sequence exploiting high correlation between adjacent frames to achieve high compression ratios Range & domain blocks are still 2-dimensional

Elaborazione di Immagini e Video A.A. 2010-11

77

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Predictive compression

Frame #2 Frame #1
Elaborazione di Immagini e Video A.A. 2010-11

78

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Full 3D coding
Range and domain blocks (cubes) are considered in a 3D space
2 dimension for image plane 1 dimension for time axis

This is the real extension from PIFS for images to PIFS for videos
Range Cubes

Domain cubes

Range Cube
Elaborazione di Immagini e Video A.A. 2010-11

x
79

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

3D fractal zooming

Exactly like the 2 dimensional case, we can extend the fractal zoom technique for 3D coding We can expand a three-dimensional fractal code of a video sequence

Elaborazione di Immagini e Video A.A. 2010-11

80

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

3D fractal zooming
Exactly like 2D, we can extend the fractal zoom technique for 3D coding we can expand a 3D fractal code of a video sequence:
1. Zoom the frame 2. Get an implicit interpolation of the frame sequence

Elaborazione di Immagini e Video A.A. 2010-11

81

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Fractal video expansion


Original sequence Coding Fractal code

Void sequence

Fractal zoom

decoding

Expanded sequence

Elaborazione di Immagini e Video A.A. 2010-11

82

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Main applications
Slow motion replay
Using 3d fractal zoom, we obtain a bigger number of frames, and the effect achieved is a slow motion replay of the sequence (keeping frame rate constant)

Video summarization & presentation


Only some frames of the sequence are stored in a web server, and a preview of the sequence can be created by a client using fractal zoom web Fractal zoom samples
Elaborazione di Immagini e Video A.A. 2010-11

83

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

and what about quality?

Since fractal-created frames are not real, we can say nothing about objective quality. We can only discuss about subjective quality

Elaborazione di Immagini e Video A.A. 2010-11

84

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Problems with fractal expansion

Main problems with fractal zoom of video sequences are:


Spatial discontinuity Temporal discontinuity

In addition, fractal 3D encoding is a great cpu-time consuming algorithm

Elaborazione di Immagini e Video A.A. 2010-11

85

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Spatial discontinuity
It is a innate problem of PIFS Since code is generated by partitioning images in block, once decoded there is a blockiness effect, that is proportional to the expansion rate

Elaborazione di Immagini e Video A.A. 2010-11

86

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Time discontinuity

The effect of time discontinuity is jerkiness along time axis


jerkiness

120 100 M (S SE ) 80 60 40 20 fractal 0 1 6 11 16 21 26 31 36 41 46 51 56 61 frame

Elaborazione di Immagini e Video A.A. 2010-11

87

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Solutions

Actual techniques to solve those problems are:


Overlapped range block coding (ORB) Ordered square overlapping (OSO) Filtering Wavelets

Elaborazione di Immagini e Video A.A. 2010-11

88

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

ORB and OSO


In 2dimensional coding we use 4 partition of the image with range block of difference Those partition are fractal encoded separately They are decoded using a median filtering
O.R.B. O.S.O.

Overlapped partition

windowed median reassembly


89

Elaborazione di Immagini e Video A.A. 2010-11

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

ORB & OSO

Noise due to blockiness

Noise reduction using overlapped technique

Elaborazione di Immagini e Video A.A. 2010-11

90

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Wavelets
Wavelet transform is used to speed up fractal encoding since: 1. We can neglect high frequencies 2. We can use high approximation on low information bands 3. Images are subsampled 4. The process is parallelized

Original sequence

Wavelet transform (1st level)


Elaborazione di Immagini e Video A.A. 2010-11

Wavelet inverse transform


91

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Advanced fractal video coding

We can use all those techniques together:


WAVELET + ORB + FRACTAL + OSO

Elaborazione di Immagini e Video A.A. 2010-11

92

UNIVERSIT DEGLI STUDI DI CAGLIARI Corso di Laurea Specialistica in Ingegneria delle Telecomunicazioni

Advanced fractal video coding

Fractal Encod. ORC Fractal Encod.

Fractal decoding O.C.O. Fractal decoding

Indirect Direct Wavelet T Fractal Encod. Fractal decoding O.C.O. Fractal Encod. Fractal decoding Wavelet T

Stream IN

ORC

Stream OUT

Elaborazione di Immagini e Video A.A. 2010-11

93

Potrebbero piacerti anche