Save a group of processed imags output from a for loop in a specific folder
Show older comments
Hello,
I have an image database, i process them through a for loop, i want to save the output processed images in anther folder, i have the following error when i trying to do that:
Error using imwrite
unable to open file " ********.bmp" for writing. you might not have write permission
the code i have used is:
SNLImagepath='F:\SNL_images\';
FileName = fullfile(savepath, sprintf(ImageName,ext));
imwrite(a, FileName);
Accepted Answer
More Answers (1)
Ajay Kumar
on 9 Nov 2019
Have you correctly given the permission to the folder you are writing?
Once try this,
savepath = 'C:\Some_dir\Some_folder';
FileName = fullfile(savepath, sprintf(ImageName,ext));
imwrite(a, FileName);
3 Comments
Amelia
on 10 Nov 2019
Ajay Kumar
on 11 Nov 2019
you need to edit the line
FileName = fullfile(SNLImagepath, sprintf(ImageName,ext));
Amelia
on 12 Nov 2019
Categories
Find more on Images in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!