You are on page 1of 5

Code:

clc;
clear all;
close all;
i = imread('peppers.png');
imshow(i);
i=rgb2gray(i);
imshow(i);
i= double(i/max(max(i)));

gx= [-1 1]; gy= gx';


ix = conv2(i,gy,'same');
iy=conv2(i,gx,'same');
figure; imshow(ix); figure;imshow(iy);

edgefis = readfis ('Shweta_00157_e14.fis');


for i= 1: size(i,1)
ieval(i,:)= evalfis([ ix(i,:);iy(i,:)]', edgefis);
end

ieval = ieval*255;
figure;
imshow(uint8(ieval));

You might also like