Info

此问题已关闭。 请重新打开它进行编辑或回答。

How to save multiple Histogram from 1 database into 1 otuput folder?

1 次查看(过去 30 天)
I wanna call all images in database and all of them have output in histogram the after that I wanna save them into 1 output folder but I got an error for this code:
Images=dir('D:\DIAH\[MATLAB]cv1-fingerspelling-recognition-master\cv1-fingerspelling-recognition-master\imagesss\'); %Database Image folder
%......................[] ^ IS this OK?
for k = 1 : length(Images)
baseFileName = Images(k).name;
fullFileName = fullfile(Images(k), baseFileName);
methodFile = imread(fullFileName);
grayscale = rgb2gray(methodFile);
histogram = imhist(grayscale);
currentImageArray = grayscale;
currentImage{k}=currentImageArray;
end
for i=1:1
outputFolder = 'D:\DIAH\[MATLAB]cv1-fingerspelling-recognition-master\cv1-fingerspelling-recognition-master\Hasil Histogram Dataset\1';
% outputFileName = fullfile(outputFolder, ['Hasil Citra Lab_' num2str(i) '.jpg']);
outputFileName = fullfile(outputFolder, sprintf('Hasil Citra Ground Truth_%d_%d.jpg', k, i));
imwrite(currentImage{k}, outputFileName);
end

回答(0 个)

此问题已关闭。

Community Treasure Hunt

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

Start Hunting!

Translated by