What does it mean "merge column vector for each training face"?

0 views
Skip to first unread message

Ali

unread,
Oct 14, 2009, 7:44:28 AM10/14/09
to Face Recognition Research Community
Hi
I need little help, about how to merge column of an image in MATLAB.
Is there any direct function to I have to make it manually.

thanks
M.Ali Subhani

Oh Beom Seok

unread,
Oct 14, 2009, 7:50:43 AM10/14/09
to face...@googlegroups.com
Hi, Ali
 
What does mean "merge column of an image"?
Give the question in detail.
 
Regards,
Beom Seok Oh.

2009/10/14 Ali <your...@gmail.com>

Ali

unread,
Oct 14, 2009, 7:55:27 AM10/14/09
to Face Recognition Research Community
Hi,
I am working on Feature Extraction

% merge column vector for each training face ...... ( I dont
understand this comment)

X = [x1 x2 ... xM] where M training images. sized N pixels wide by
N pixels tall

thanks..

anouar

unread,
Oct 14, 2009, 8:09:12 AM10/14/09
to face...@googlegroups.com
giving an image with N pixels; N=c*l ("c" means columns, and "l" lines)

to merge column of an image

A=imread("yourimage");
A=double(A(:));

so your image will be transformed from an uint8 matrix (c x l) to a
column of doubles with N component

to create your Data matrix for T training images you have to create The
D matrix

d=zeros(N,T); % just to boost
for i=1:T
V=double(imread("your-i-image"));
D(:,i)=V(:);
end

that's all

Oh Beom Seok

unread,
Oct 14, 2009, 8:15:18 AM10/14/09
to face...@googlegroups.com
Hi,
 
I think, the X is a matrix representing a set of converted face image vectors.
 
x1 represent a first face image vector converted from face image.
And the "merge" means concatenating the image vectors in horizontally to generate a matrix.
 
In the example you gave, the number of training image is M sized N pixels.
So the size of matrix X should be NxM matrix.

Regards,
Beom Seok.
 
2009/10/14 Ali <your...@gmail.com>

TrulyOurs

unread,
Oct 16, 2009, 9:13:27 AM10/16/09
to face...@googlegroups.com
hi,
thank you for helping.

I also got this..

if i have two matrices of size 5 rows and 5 columns (5 x 5)

let say    A --> 5 x 5   and B ---->   5 x 5

then X has 1st column containing all columns of A and 2nd Column of X contains all columns of B

X = a11  b11
      a12  b12
      a13  b13
      a14  b14
      a15  b15
      a21  b21
      a22  b22
      a23  b23
      a24  b24
      a25  b25
       ...    ...
      a55  b55

I hope it helps others also...

In MATLAB it will be written as X(1,1) = reshap(A)   and X(1,2) =  reshap(B)

Reagards and thanks

--
------------------------------------------------------
Engineer Muhammad Ali Subhani
----
Mob: +44-(0)-7787878823
-----------------------------------------------------
Reply all
Reply to author
Forward
0 new messages