1 EFFICIENT BITMAP RESEMBLENCE UNDER TRANSLATION Klara Kedem & Daniel Cohen This presentation will probably involve audience discussion, which will create.

Slides:



Advertisements
Similar presentations
A Multi-Resolution Technique for Comparing Images Using the Hausdorff Distance Daniel P. Huttenlocher and William J. Rucklidge Nov Presented by.
Advertisements

Linear Time Methods for Propagating Beliefs Min Convolution, Distance Transforms and Box Sums Daniel Huttenlocher Computer Science Department December,
Indexing DNA Sequences Using q-Grams
Microcomputer Systems 1
3D reconstruction.
Introduction to Algorithms Rabie A. Ramadan rabieramadan.org 2 Some of the sides are exported from different sources.
UNIT 2. Introduction to Computer Programming
CS1010 Programming Methodology
MAT 105 SP09 Functions and Graphs
Introduction to Computer Graphics Chapter 6 – 2D Viewing Pt 2 1.
Programming with Alice Computing Institute for K-12 Teachers Summer 2011 Workshop.
Chapter 5 Raster –based algorithms in CAC. 5.1 area filling algorithm 5.2 distance transformation graph and skeleton graph generation algorithm 5.3 convolution.
SWE 423: Multimedia Systems
Comparing Images Using the Hausdorff Distance Mark Bouts 6th April 2006.
Image Enhancement To process an image so that the result is more suitable than the original image for a specific application. Spatial domain methods and.
Contents Description of the big picture Theoretical background on this work The Algorithm Examples.
Chapter 6 Continuous Random Variables and Probability Distributions
Uncalibrated Geometry & Stratification Sastry and Yang
Chamfer Matching & Hausdorff Distance Presented by Ankur Datta Slides Courtesy Mark Bouts Arasanathan Thayananthan.
SubSea: An Efficient Heuristic Algorithm for Subgraph Isomorphism Vladimir Lipets Ben-Gurion University of the Negev Joint work with Prof. Ehud Gudes.
Chapter 6 The Normal Distribution and Other Continuous Distributions
On the ICP Algorithm Esther Ezra, Micha Sharir Alon Efrat.
Chapter 5 Continuous Random Variables and Probability Distributions
Copyright © Cengage Learning. All rights reserved. CHAPTER 11 ANALYSIS OF ALGORITHM EFFICIENCY ANALYSIS OF ALGORITHM EFFICIENCY.
Circle Drawing algo..
Improved results for a memory allocation problem Rob van Stee University of Karlsruhe Germany Leah Epstein University of Haifa Israel WADS 2007 WAOA 2007.
CHAPTER 7: SORTING & SEARCHING Introduction to Computer Science Using Ruby (c) Ophir Frieder at al 2012.
VEHICLE NUMBER PLATE RECOGNITION SYSTEM. Information and constraints Character recognition using moments. Character recognition using OCR. Signature.
Chapter 4 Continuous Random Variables and Probability Distributions
Metric Self Calibration From Screw-Transform Manifolds Russell Manning and Charles Dyer University of Wisconsin -- Madison.
Computer Implementation of Genetic Algorithm
Pairwise Alignment, Part I Constructing the Values and Directions Tables from 2 related DNA (or Protein) Sequences.
Slide 1-1 Copyright © 2006 Pearson Education, Inc. Publishing as Pearson Addison-Wesley.
Fixed-Point Arithmetics: Part II
Algorithm Analysis. Algorithm An algorithm is a clearly specified set of instructions which, when followed, solves a problem. recipes directions for putting.
Video Mosaics AllisonW. Klein Tyler Grant Adam Finkelstein Michael F. Cohen.
Chapter 9.  Mathematical morphology: ◦ A useful tool for extracting image components in the representation of region shape.  Boundaries, skeletons,
Vertical and horizontal shifts If f is the function y = f(x) = x 2, then we can plot points and draw its graph as: If we add 1 (outside change) to f(x),
September 23, 2014Computer Vision Lecture 5: Binary Image Processing 1 Binary Images Binary images are grayscale images with only two possible levels of.
September 5, 2013Computer Vision Lecture 2: Digital Images 1 Computer Vision A simple two-stage model of computer vision: Image processing Scene analysis.
Morphological Image Processing
1 CS 552/652 Speech Recognition with Hidden Markov Models Winter 2011 Oregon Health & Science University Center for Spoken Language Understanding John-Paul.
CSC 211 Data Structures Lecture 13
Computer Graphics Chapter 6 Andreas Savva. 2 Interactive Graphics Graphics provides one of the most natural means of communicating with a computer. Interactive.
XP. Objectives Sort data and filter data Summarize an Excel table Insert subtotals into a range of data Outline buttons to show or hide details Create.
Numerical Methods.
CVPR2013 Poster Detecting and Naming Actors in Movies using Generative Appearance Models.
Algorithm Analysis Chapter 5. Algorithm An algorithm is a clearly specified set of instructions which, when followed, solves a problem. –recipes –directions.
Timo O. Korhonen, HUT Communication Laboratory 1 Convolutional encoding u Convolutional codes are applied in applications that require good performance.
1. Searching The basic characteristics of any searching algorithm is that searching should be efficient, it should have less number of computations involved.
Chapter 15 P, NP, and Cook’s Theorem. 2 Computability Theory n Establishes whether decision problems are (only) theoretically decidable, i.e., decides.
Sequencers SQO,SQC,SQL.
Ch 2 Quarter TEST Review RELATION A correspondence between 2 sets …say you have a set x and a set y, then… x corresponds to y y depends on x x is the.
Basic Business Statistics, 10e © 2006 Prentice-Hall, Inc.. Chap 6-1 Chapter 6 The Normal Distribution and Other Continuous Distributions Basic Business.
Image-Based Rendering Geometry and light interaction may be difficult and expensive to model –Think of how hard radiosity is –Imagine the complexity of.
Compressing Bi-Level Images by Block Matching on a Tree Architecture Sergio De Agostino Computer Science Department Sapienza University of Rome ITALY.
Image matching using the Hausdorff Distance with CUDA
Course 3 Binary Image Binary Images have only two gray levels: “1” and “0”, i.e., black / white. —— save memory —— fast processing —— many features of.
Morphological Image Processing (Chapter 9) CSC 446 Lecturer: Nada ALZaben.
Ch03-Algorithms 1. Algorithms What is an algorithm? An algorithm is a finite set of precise instructions for performing a computation or for solving a.
Computer Graphics CC416 Lecture 04: Bresenham Line Algorithm & Mid-point circle algorithm Dr. Manal Helal – Fall 2014.
Applied Discrete Mathematics Week 2: Functions and Sequences
Continuous Random Variables
Introduction to Programming
CPSC 411 Design and Analysis of Algorithms
Haim Kaplan and Uri Zwick
واشوقاه إلى رمضان مرحباً رمضان
Evaluation of Data Fusion Methods Using Kalman Filtering and TBM
Continuous Random Variables
Binary Search A binary search algorithm finds the position of a specified value within a sorted array. Binary search is a technique for searching an ordered.
Presentation transcript:

1 EFFICIENT BITMAP RESEMBLENCE UNDER TRANSLATION Klara Kedem & Daniel Cohen This presentation will probably involve audience discussion, which will create action items. Use PowerPoint to keep track of these action items during your presentation In Slide Show, click on the right mouse button Select “Meeting Minder” Select the “Action Items” tab Type in action items as they come up Click OK to dismiss this box This will automatically create an Action Item slide at the end of your presentation with your points entered.

2 Introduction  “Whether two point set A and B resemble each other ?”  minimum Hausdorff distance under translation  Use of the graphic hardware in order to speed-up run-times of the existing algorithms

3 The algorithms  Huttenlocher, Kedem and Sharir  Huttenlocher, Klanderman and Rucklidge  Chew and Kedem

4 Graphic Hardware  Pixel plane  Word for each pixel  Processor for each pixel  Operations that supported are restricted (or, and, …)  Parallel execution

5  In order to use graphic hardware the input for the algorithms will be in raster form, i.e., matrices of pixels, each having value 0 or 1, standing for white or black color of the image Bitmaps

6  Automatic navigation.  In automatic navigation two successive images are taken by a camera attached to an autonomous vehicle, with a short time interval between them. We need to find the matching features in the images in order to determine the exact motion and the new location of the vehicle The application

7  Assume that we have two consecutive images and we have a vague knowledge of motion between them, which consist of a translation value and a tolerance  We compute a rasterized approximation of the exact motion within window W

8 Example The map is known, the motion is roughly known We need to find the exact motion

9 Theoretical Background  A, B –point sets   (a,b) – any metric (for example L 1, L 2, L  )  Directed Hausdorf distance from a  A to B d(a, B) a

10 Theoretical Background  Directed Hausdorff distance from A to B  It measures the distance of the point of A which is farthest from the set B  Attention: h(A, B) is not symetric

11 Theoretical Background h(A, B) h(B, A)

12 Theoretical Background  Symmetric Hausdorff distance from A to B

13 Theoretical Background  The measure of resemblance D(A, B), between the sets A and B - the minimum value of the Hausdorff distance under translation.  A is fixed, B is allowed to translate in the plane where B + x is the set B translated by x

14 Theoretical Background  we discuss the directed Hausdorff distance only  Consider the directed distances in (*) as function that depends on the translation x of the set B.

15 Voronoi Surface  Consider the function  The graph of this function is the Voronoi surface of A

16 Voronoi Surface in one dimention x

17 Voronoi Surface on the plane

18 Upper Envelope  For each b  B, we shift by –b  f(x) is the upper envelope of these shifts

19 Upper Envelope x  Goal – is to find the translation x that minimize f(x) - this is directed minimum Hausdorff distance

20 Algorithm 1:Huttenlocher, Kedem and Sharir (i) Initialization: Generate ; Set f(x) to zero; (ii) For each b  B do f(x) = max (f(x), )), for all x  W. (iii) Find the minimum of f(x) for all x  W.

21 Speed-ups  Encode the distance values in the distance transform g A (x) into words in the pixel plane  distance i = g A (x) present by its unary representation U(i) = 2 i -1  min(U(i), U(j) = and (U(i), U(j)) max(U(i), U(j) = or (U(i), U(j))

22 Speed-ups  If the length of a word in the pixel plane is 6 bits, then g A (x) = 1 encoded by g A (x) = 6 encoded by  Restricts the distance we can represent to be smaller then the size (in bits) of words in the pixel plane  truncate g A (x)

23 Speed-ups  k –size of a word in the pixel plane in bits  first – transform g A (x) to k-g A (x)  truncate all the negative values of k-g A (x) => get k-g A (x ) if g A (x) <= k g’ A (x) = 0 otherwise

24 Horizontal mirroring of Truncated horizontal mirroring of k k

25 Inverted distance truncated distance

26  By the transformation above we compute a truncated lower envelope f’(x) of g’ A (x+b)  Maximum of f’(x) is desired minimum Hausdorff distance (under k-bit limitation)

27 Algorithm 3: The Huttenlocher, Klanderman and Rucklidge 1. Initialization: Compute ; Initialize 2. For each x  W do (a) For each b  B do d = max(d, ); (b) = min(, d);

28  Search of the minimum is done in the inner loop  Speed-up: as soon as for some b the computed distance d is grater that the current value of f min leave the inner loop since x will not yield a better Hausdorff distance

29  The framework of Chew and Kedem examines certain cross-sections of Voronoi surfaces.  Disc of radius  is put about each point of A,creating set A  (the union of these discs) A={3, 9}, B={5, 12} 0

30  Consider the set A  - b; the set A  shifted by –b  A  -b – set of all translations that map b into A   F =  b  B A  - b : set of all translations that map all points b  B into A  A={3, 9}, B={5, 12} 0 0

31  Hausdorff decision problem – for a given  whether the minimum Hausdorff distance under translation is less then   The answer is true if there exists a translation x such that the Hausdorff distance between A and B+x is less than or equal to  => F above is not empty

32 Algorithm 2:Chew and Kedem Algorithm 2:Rasterization of the Chew and Kedem algorithm 1. Given a distance , compute a disk of this radius, C(  ). 2. For each point a  A put C(  ) centered around a, thus creating. 3. For each point b  B shiftby –b and compute the intersection,, of the overlaid (shifted) with former ones, over W. 4. Check whether the intersection,, is not empty

33  Given an initial   Create a disc of radius  filled with 1’s and fill the rest of the bitmap with 0’s  Shift this bitmap about all point a  A such that the center of the disc is at a;  or operation over all the shifts gets the union A   Shifting A  by –b for all b  B, and intersecting these shifted copies, generates F  ; this can be computed by the and operation Implementation of Alg.2

34  we can perform k decision algorithms simultaneously (k –number of bits in the pixel plane)   1,  2, …,  k – ascending sequence of the  values which we chose to check simultaneously by alg.2  Number the bits in the pixel plane from 1 to k (1 and k the most significant and the least significant bits, respectively)  Relate to bit number j as to the layer representing the discs of radius  j (this layer will represent A  j )  A  - pixel plane with al the A  j, j = 1,…,k Interleaving algorithms 1 and 2

35 word size = k The k-bit pixel plane for discs of various radius about a  A (the template) k layer 2:  = 3 layer 4:  = 7 point a

36  The intersection areas, F 1, F 2, …, F k, will indicate whether A and B are closer then the corresponding  ’s  The and operation that we used for radius  can answer k decision problems  and here yields a pixel plane that contains f’ – all of the intersected F i together

37  If for  1, …,  i the answer the decision problem is false, and for  i+1, …,  k is true, refine the range(  i,  i+1 ) by creating a new sequence of  ’s in this range and we run Alg.2 again  In practice the  range diminishes very quickly (this procedure runs at most twice)

38 Template  Define template about the pixel a  A to be the pixel plane with 0 everywhere and the unary representation the set of all words in the pixel plane which get a value other than 0 by drawing the disc about a

39 Algorithm 4: a combination of 1 and 2 1. Initialization : zero f’(x) for all x  W ; 2. Build template: Given an ascending sequence of possible Hausdorff distances, create a template of disks in the pixel plane for one point a  A; 3.Create : for each point a  A copy the template, centered at a, performing an or operation between the pixel planes; 4. for each b  B shift the pixel of by –b, performing the and operation between the pixel plane containing f’ and the current shift of, f’ = and (f’, -b) 5. For each x  W, find the maximum pointin f’, by performing = or(f’(x)| x  W)

40  in algorithm 4 the distance transform g’ A is replaced by A   The word size k which restrict the largest distance that could be stored in g’ A is not restricting any more

41 Implementation and results  Alg.4 and Alg.3 were implemented in C on a Silicon Graphics Indigo with 8-bits pixel-plane  Performances of Alg.4 and Alg.3 were compared under different parameters

42 Implementation and results  Two images were taken by a moving camera, camera slightly shifted downwards  A binary images were obtained  The matching has been applied between windows in 1 and corresponding windows in 2 1 2

43 Implementation and results A comparison between the algorithms for the matching times as a function of the window size with  max =20 Fig. 3Fig. 2Fig. 1AlgorithmWindow size

44 Implementation and results The mathcing times as function of  max. Window size = 80 Fig. 3Fig. 2Fig. 1Algorithm  max

45 Summary  Alg.4 is faster than Alg.3 in most of the experiments  For now it is the fastest known sequential implementation of the minimum Hausdorff distance computation.