hello , I have an image that each intensity is a cell array of 3*3 block , how do I get the image back into pixels?

1 vue (au cours des 30 derniers jours)
this is the code i used to covert the image intensities into a 3*3 blocks :
img= imread('cameraman.tif');
d = 3; % the dimension of the sub matrix
[x,y] = size(img);
% perform integer division by three
m = floor(x/d);
n = floor(y/d);
m_rest = mod(x,d);
n_rest = mod(y,d);
new_f = img(1:(end-m_rest), 1:(end-n_rest));
cells_f = mat2cell(new_f , d*ones(1,m), d*ones(1,n));
I have done some calculations on it and i want to return it back

Réponse acceptée

Voss
Voss le 25 Mai 2022
cell2mat(cells_f)

Plus de réponses (0)

Community Treasure Hunt

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

Start Hunting!

Translated by