Finding energy of a window with specified dimensions

조회 수: 1 (최근 30일)
med-sweng
med-sweng 2013년 1월 30일
I'm planning to do the following:
1- Slide a window with dimensions 4X4 on an image 2- For each window calculate the `energy` 3- Find the histogram
For sliding the window over an image, I know that we can use `nlfilter`, but this requires a `fun`. Will this function be the energy? How can I use this with `nlfiler`?
So, how do you think I can go with 1,2, and 3 in `matlab`?
Thanks.

답변 (1개)

Matt J
Matt J 2013년 1월 30일
Convolution might be enough if the energy is something like the sum of squares
e=ones(1,4);
Energy = conv2(e,e, Image.^2,'valid');
Then use HISTC or IMHIST to get the histogram...

카테고리

Help CenterFile Exchange에서 Spline Postprocessing에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by