805 views

Uploaded by pi194043

The article describes how to obtain a
polynomial approximation of a 2D signal about a neighborhood about a given point using mean square estimation

save

You are on page 1of 9

Pi19404

February 6, 2014

Contents

Contents

Polynomial approximation of 1D signal

0.1 Introduction . . . . . . . . . . 0.2 Polynomial Approximation 0.3 2D projection . . . . . . . . References . . . . . . . . . . . . . . . . . . . . . . . . . of 2D signal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

3

3 3 3 8

2 | 9

Polynomial approximation of 2D signal

**Polynomial approximation of 2D signal
**

0.1 Introduction

In this article we will look at the concept for polynomial expansion to approximate a neighborhood of a pixel with a polynomial.

0.2 Polynomial Approximation of 2D signal

The idea of polynomial expansion is to approximate a neighborhood of a point in a 2D function with a polynomial. Considering only a quadratic polynomial ,pixel values in a neighborhood is given by

f (x) x

T

Ax

+b

T

x

+c

where A is a symmetric matrix,b is a vector and c is a scalar

The coefficients can be estimated by weighted least square estimate of pixel values about neighborhood. Let us consider a polynomial of order 2.The basis functions of the subspace where the local signal is being approximated are

1; x2 ; y 2 ; x; y; xy

The basis function are defined on the discrete grid of -N to N considering a window/neighborhood of (2 £ N + 1) ,for the present example let N=7;

0.3 2D projection

We need to project a 2D function onto these basis As in the case on 1D projection we simply,take the innerproduct of the given signal with the basis 1; x; y; x2 ; y 2 ; xy

3 | 9

Polynomial approximation of 2D signal

(a) 2D basis function

(b) 2D gaussian function

4 | 9

Polynomial approximation of 2D signal

To compute the projection parameters ,one can directly take the inner production of the signal with each of the basis. We also need to consider a weighing function ,in the present example we consider a 2D gaussian with variance of 1 along the x and y direction. We get the projection matrix as follows.

**2 1:0000 6 0 6 6 0 6 6 0:9959 6 40:9959
**

0

0 0:9959 0 0 0 0

0 0 0:9959 0 0 0

0:9959 0 0 2:9304 0:9918 0

0:9959 0 0 0:9918 2:9304 0

0 0 0 0 0 0:9918

3 7 7 7 7 7 7 5

(1)

**Again we use the same method used in the 1D case
**

res

= (G 1)

£

A

T

£

fA

T

=

B

£

W;

where B is the basis vector and W is gaussian weights

A

T =

B

£

W

will give us a scalar for each of the basis function

This gives us the projection of the signal onto the basis function The inverse transformation gives us the mean square estimate of the polynomial function in the local neighborhood about the point. In the below function we are obtaining the polynomial estimate of the function 5x2 + 10x + 3 The below matlab sript computes the 2D polynomial approximation At (4; 4) of result array we get the coefficients This corresonds to result translated by 3.

[78; 40; 0; 5; 0; 0]

Replacing x by x 3 we obtain the desired coefficients [3; 10; 0; 5; 0; 0]

sigma=1; N=7; delta=(N-1)/2; x=(-delta:delta)'; y=(-delta:delta)';

5 | 9

Polynomial approximation of 2D signal

%generating the meshgrid [bx,by]=meshgrid(x,y); %gaussian weighing function ax=exp((-bx.^2-by.^2)/(2*sigma.^2)); ax=ax/sum(sum(ax)); figure(1); surf(bx,by,ax); shading interp; %the basis functions figure(2); b0=ones(N,N); b1=bx; b2=by; b3=bx.^2; b4=by.^2; b5=by.*bx; subplot(3,2,1) surf(bx,by,b0); grid on; shading interp; subplot(3,2,2) surf(bx,by,b1) grid on; shading interp; subplot(3,2,3) surf(bx,by,b2) grid on; shading interp; subplot(3,2,4) surf(bx,by,b3) grid on; shading interp; subplot(3,2,5) surf(bx,by,b4)

6 | 9

Polynomial approximation of 2D signal

grid on; shading interp; subplot(3,2,6) surf(bx,by,b5) grid on; shading interp; %y=ones(N,N); %computing the G matrix G=B'*W*B=AA' G1=zeros(6,6); G1(1,1)=sum(sum(ax.*b0)); G1(2,2)=sum(sum(ax.*b4)); G1(4,4)=sum(sum(ax.*b4.^2)); G1(6,6)=sum(sum(ax.*bx.^2.*by.^2)); G1(3,3) =G1(2,2); G1(1,4) = G1(2,2); G1(1,5) = G1(2,2); G1(4,1) = G1(2,2); G1(5,1) = G1(2,2); G1(5,5) = G1(4,4); G1(4,5) = G1(6,6); G1(5,4)= G1(6,6);

xx=0:20; yy=0:20; [xx,yy]=meshgrid(xx,yy); S=5*xx.^2+10*xx+3; %computing the matrix A'*I for each of the basis function f0 = b0.*ax; f0 = f0(end:-1:1,end:-1:1); f1 = b1.*ax; f1 = f1(end:-1:1,end:-1:1); f2 = b2.*ax; f2 = f2(end:-1:1,end:-1:1); f3 = b3.*ax; f3 = f3(end:-1:1,end:-1:1); f4 = b4.*ax; f4 = f4(end:-1:1,end:-1:1); f5 = b5.*ax; f5 = f5(end:-1:1,end:-1:1); r1=imfilter(S,f0,'conv','replicate');

7 | 9

Polynomial approximation of 2D signal

r2=imfilter(S,f1,'conv','replicate'); r3=imfilter(S,f2,'conv','replicate'); r4=imfilter(S,f3,'conv','replicate'); r5=imfilter(S,f4,'conv','replicate'); r6=imfilter(S,f5,'conv','replicate');

%computing the means square estimate using normalized convoltion res=arrayfun(@(x1,x2,x3,x4,x5,x6)inv(G1)*[x1;x2;x3;x4;x5;x6],r1,r2,r3,r4,r5,r6 %displaying the value of function at x-3 cell2mat(res(4,4))

8 | 9

Bibliography

Bibliography

[1] Kenneth Andersson and Hans Knutsson. Continuous normalized convolution. In: ICME (1). IEEE, 2002, pp. 725728.

**dblp.uni-trier.de/db/conf/icmcs/icme2002-1.html#AnderssonK02.
**

[2]

isbn:

0-7803-7304-9.

url: http://

Kenneth Andersson, Carl-Fredrik Westin, and Hans Knutsson. Prediction from 87.3 (Mar. 22, 2007), pp. 353365. url: http://dblp.uni- trier.de/db/ journals/sigpro/sigpro87.html#AnderssonWK07. o-grid samples using continuous normalized convolution. In: Signal Processing

[3]

Gunnar Farnebäck. Motion-based Segmentation of Image Sequences. LiTH-ISYEX-1596. MA thesis. SE-581 83 Linköping, Sweden: Linköping University, 1996.

[4]

Gunnar Farnebäck. Polynomial Expansion for Orientation and Motion Estimation. Dissertation No 790, ISBN 91-7373-475-6. PhD thesis. SE-581 83 Linköping, Sweden: Linköping University, Sweden, 2002.

[5]

Gunnar Farneback. Two-Frame Motion Estimation Based on Polynomial Expansion. In: SCIA. LNCS 2749. Gothenburg, Sweden, 2003, pp. 363370.

9 | 9

- Local Binary PatternUploaded bypi194043
- Modified Canny Edge DetectionUploaded bypi194043
- Polynomial Approximation of 1D signalUploaded bypi194043
- SubPixel Corner Localization AlgorithmUploaded bypi194043
- Polynomial Approximation of 2D image patch -Part 2Uploaded bypi194043
- Multi Class Logistic Regression Training and TestingUploaded bypi194043
- Gaussian Multivariate Distribution -Part 1Uploaded bypi194043
- Fast Asymmetric Learning for Cascade Face Detection Training/Testing UtilityUploaded bypi194043
- ARM Neon Optimization for image interleaving and deinterleavingUploaded bypi194043
- A linear channel filterUploaded bypi194043
- Adaptive Skin Color DetectorUploaded bypi194043
- Continuous Emission Hidden Markov Model for sequence classificationUploaded bypi194043
- Fast 2D Separable Symmetric/Anti-Symmmetric ConvolutionUploaded bypi194043
- Dense optical flow expansion based on polynomial basis approximationUploaded bypi194043
- Normalized convolution for image interpolationUploaded bypi194043
- OpenCL 2D Convolution Using Separable Filters -Box FilterUploaded bypi194043
- Android OpenCV Face detectionUploaded bypi194043
- Fast 3D Extension of Fast Feature Detection for SpatioTemporal Corner DetectionUploaded bypi194043
- Feature Detection - Overview of Harris Corner Feature DetectionUploaded bypi194043
- Computing Rectangular Haar Features for Cascade Detection TrainingUploaded bypi194043
- Image enhancement using FusionUploaded bypi194043
- Uniform Color QuantizationUploaded bypi194043
- Random Ferns for Patch DescriptionUploaded bypi194043
- A simple color balance algorithmUploaded bypi194043
- OpenCL Image Convolution Filter - Box FilterUploaded bypi194043
- Android OpenCV Simple Face TrackerUploaded bypi194043
- Control Limited Adaptive Histogram Equalization for Image EnhancementUploaded bypi194043
- Uniform Local Binary Pattern and Spatial Histogram ComputationUploaded bypi194043
- A detailed descriptions and results for different color constancy algorithmsUploaded bypi194043
- OpenCL Heterogenenous program for Image Processing - ColorSpace conversion BGR-HSV,HSV-BGR,BGR-GRAYUploaded bypi194043

- Compiling Native C/C++ library for AndroidUploaded bypi194043
- Multi Class Logistic Regression Training and TestingUploaded bypi194043
- Gaussian Multivariate Distribution -Part 1Uploaded bypi194043
- ARM Neon Optimization for image interleaving and deinterleavingUploaded bypi194043
- A linear channel filterUploaded bypi194043
- Adaptive Skin Color DetectorUploaded bypi194043
- OpenVision Library Gaussian Mixture Model ImplementationUploaded bypi194043
- Continuous Emission Hidden Markov Model for sequence classificationUploaded bypi194043
- Fast 2D Separable Symmetric/Anti-Symmmetric ConvolutionUploaded bypi194043
- Dense optical flow expansion based on polynomial basis approximationUploaded bypi194043
- Implementation of discrete hidden markov model for sequence classification in C++ using EigenUploaded bypi194043
- Markov chain implementation in C++ using EigenUploaded bypi194043
- C++ InheritanceUploaded bypi194043
- Mean Shift AlgorithmUploaded bypi194043
- C++ Const,Volatile Type QualifiersUploaded bypi194043
- Random Ferns for Patch DescriptionUploaded bypi194043
- Integral Image for Computation of Mean And VarianceUploaded bypi194043
- C++ Class Members and friendsUploaded bypi194043
- Embedded Systems Programming with ARM on Linux - Blinking LEDUploaded bypi194043
- C++ virtual functions and abstract classUploaded bypi194043
- C++ static members and functionUploaded bypi194043
- Mean Shift TrackingUploaded bypi194043
- Uniform Local Binary Pattern and Spatial Histogram ComputationUploaded bypi194043
- Tan and Triggs Illumination normalizationUploaded bypi194043
- Normalized convolution for image interpolationUploaded bypi194043

- Motor Policy Schedule Cum Certificate of InsuranceUploaded byAr Mani
- 37DL_Plus_%20Español BrochureUploaded byDanny Milton Silva Vasquez
- Costos Por Ordenes de ProducciónUploaded byterrymi
- TFG_definitivo (1) (4)Uploaded byPablo Camino
- Legalizacion de utilidades.pdfUploaded byPollo Ramírez
- HTML5 AAC Audio Playback TestsUploaded byWilbert Nina Linares
- Aplicaciones Terapeuticas de Los cosUploaded byJunior Maia
- TJ MaxxUploaded byArpit Jain
- Derecho ComercialUploaded bynacho
- Port a Folio Virtual-johanna JuradoUploaded byibrain23
- Teoria de Flujo de Fluidos en Tuberias1Uploaded byJofreddy A. Angeles
- 06 - Firewalls [updated].pdfUploaded byAneudy Hernandez Peña
- Herbal PlantsUploaded byCarl Angelo Santiago
- USO DEL LENGUAJE CORPORAL COMO TÉCNICA DE COMUNICACIÓNUploaded byAngel Byrd
- 1 Lista de Exercicio Introducao EconomiaUploaded byGustavo Pitasse Santos
- Alteracion Genetica en Las PlantasUploaded byOscar Emir Velarde
- 1809.00946Uploaded byfoliox
- NB-502Uploaded byArumugam Pillai
- Organisational Behaviour with case studiesUploaded bySalman
- PptUploaded byRenu Sharma
- Fst 640 ApuntesUploaded byenrique
- Avaliação de História I Unidade - 8ª série AUploaded byEtevaldo Lima
- Región AndinaUploaded byDeyguerman Guzman
- practica 9Uploaded bykire35
- Relatos IIUploaded bycarlosdiez63
- Diapositivas Ergonomia - CopiaUploaded byCelsoNadin
- Trabajo Grupal Fsis-fasUploaded byPatricia Gonzales Calderón
- CANDLESTICK+METHODUploaded byMazlan Ismail
- Online Library SystemUploaded byArora_Raj
- Duplicate Sip ReportUploaded byprincy chauhan