read all images from subfolders
1 次查看(过去 30 天)
显示 更早的评论
hi.i have a folder with subfolders that each folder contains ten folder and these folders have 4 image files. how can resize all images with matlab code?
0 个评论
回答(1 个)
Image Analyst
2014-5-21
Combine the FAQ: http://matlab.wikia.com/wiki/FAQ#How_can_I_process_a_sequence_of_files.3F with imresize() and you can do it. Create two filenames with sprintf() and fullfile(). Call imread() then imresize() then imwrite(). If you cannot do that, then post your code for us to fix.
12 个评论
Image Analyst
2014-5-24
Well figure it out. Step through one line at a time until you see the value of it vanish. See http://blogs.mathworks.com/videos/2012/07/03/debugging-in-matlab/
In the meantime, I attach a program to recurse into subfolders getting image names.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 File Operations 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!