How can i create a image array includes files from a specific folder?
Mostrar comentarios más antiguos
how can i create a database from images in a folder? here is my code but it is giving error.
directory = fullfile('./buildings');
images = dir(fullfile(directory,'*.jpg'));
names = {images.name}';
I=zeros(numel(names),144,176,3); %size of the images are constant and 144*176*3
for k=1: numel(names)
I{k} = imread(fullfile(directory,names{k}));
I{k}=tempI;
figure; imshow(I{k});
%operations
end
Error is this:
Cell contents assignment to a non-cell array object.
Error in application2exercise3 (line 9)
I{k} = imread(fullfile(directory,names{k}));
Ty for your help.
Respuesta aceptada
Más respuestas (1)
koray
el 18 de Oct. de 2012
0 votos
Categorías
Más información sobre Image Arithmetic en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!