A loop that can repetitively extract features?

5 vues (au cours des 30 derniers jours)
Kelly Howard
Kelly Howard le 5 Oct 2015
Hi guys,
i would like to seek help! i'm trying to do a extract HOG feature from a list of UCF sport videos and save the size of hoefeature into a folder. how can i do it?
clc; clear; close;
% video data
vidObj=VideoReader('Kicking-Side-004.avi');
video=read(vidObj);
img=zeros(size(video,1),size(video,2),size(video,4));
for j=1:size(video,4)
img(:,:,j)=im2single(rgb2gray(video(:,:,:,j)));
end
% spatio temporal orientation filter
SOE = SpatialTemporalEnergy(img,'G3',3,0);
% seperate motion energy from static and unstructure energy
structure=max(SOE(:))/100;
SOE=max(bsxfun(@minus,SOE(:,:,:,1:end-1),SOE(:,:,:,end)+structure),0);
% normalization
SOE=bsxfun(@rdivide,SOE,sum(SOE,4)+eps);
% dense HOE
hoefeature=HOE(SOE,4,4,4);
% dense HOG
[gradient_x,gradient_y] = gradient(img);
hogfeature = HOG(gradient_x,gradient_y,4,4,4,8);

Réponses (0)

Catégories

En savoir plus sur Robotics dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by