PLEASE EXPLAIN The SUM operation on an (L,M,N) array returns a (1,M,N) array. CODE THAT FOLLOWS IS AS WRITTEN gray_average_2d(1:m,1:n) = gray_average(1,1:m,1:n); ?

조회 수: 1 (최근 30일)
PLEASE EXPLAIN THE STATEMENT ALONG THE CODE...THIS STATEMENT IS BEING USED FOE ENHANCING THE CONTRAST OF AN IMAGE. AFTER THIS THE NEXT CODING FOLLOWS...
  댓글 수: 2
Jos (10584)
Jos (10584) 2014년 3월 3일
YOU DO NOT HAVE TO SHOUT, WE ARE NOT BLIND!!
Please, use lower case and be a little bit more polite, … unless you are my boss and pay me lots ;-)
Gursheen
Gursheen 2014년 3월 3일
lol...ok...is that fine now sir...??....now please also try and help me out..i am stuck with the coding part....thanks

댓글을 달려면 로그인하십시오.

답변 (1개)

Jos (10584)
Jos (10584) 2014년 3월 3일
It is because you asked for a single slice in a 3D array. This might help you
A = reshape(1:(2*3*4),2,3,4) ; % 3D test data, a cube with 2 slices. Each slice is 3-by-4
B = A(1,:,:) % still 3D, but with only one slice, so you could say it is 2D
C = squeeze(B) % squeeze out the singleton dimensions
help squeeze
  댓글 수: 1
Gursheen
Gursheen 2014년 3월 3일
ok...thanks sir...but what exactly is slice????? please elaborate a little more... is it that (1,m,n) here means that we are dealing with only one face of the 3d image..although i am not using 3d image....:(

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Image Filtering and Enhancement에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by