Clear Filters
Clear Filters

Incorrect Dimension of matrix multiplication Where I= 178*284 T =8*8, how to make the I compatible to T, If multiplication is done element wise

1 view (last 30 days)
I = imread('Published\SAMPLE1.jfif');
figure();
imshow(I);
%display(I);
I = rgb2gray(I);
figure();
imshow(I);
I = im2double(I);
title("Vein Image");
n = input("enter the basis matrix dimension: ");
T= dctmtx(n);
disp(T);
dct1 = @(block_struct) T * block_struct.data * T';
B = blockproc(I,[n n],dct1);
I1 = imresize(I,0.90);
display(B);
figure();
imshow(B);
invdct = @(block_struct) T' * block_struct.data * T;
I2 = blockproc(B,[8 8],invdct);
figure();
imshow(I2);
title("Image");

Answers (0)

Categories

Find more on Matrices and Arrays in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!