Reading and processing Images
Show older comments
Hello I have images saved in a mat file and I'm trying to read and extract feautures from the images. I need help please. Here is my codes reading the txt file
fid = fopen('file.txt');
for i = 1: 100
x = textscan(fid,'%s\n');
fn{i,1};
fn{i,1} = x{1,1};
end
save filenames fn
% My code to read the image I need help with
for i = 1:100
I = imread([fn{i,1}]);
3 Comments
Naman Bhaia
on 26 Feb 2019
Hey Chidiebere,
The question is not very clear. Can you please explain
- The purpose of reading the text file?
- Where you want to fit the "code to read the image" ?
- What error you are getting?
- Your overall aim for the code
Chidiebere Orisakwe
on 26 Feb 2019
Edited: Chidiebere Orisakwe
on 26 Feb 2019
Bjorn Gustavsson
on 27 Feb 2019
Well, first read the error-message. Then check if it is giving you information of value. In this case:
- Does the directory "C :\users\chidiebere \onedrive\documents\project" exist? (Should there be a white-space between the C and the :?, between chidiebere and \onedrive?)
- Do you have read-permissions in that directory?
Once youve checked that then you can proceed with further questions.
HTH
Answers (0)
Categories
Find more on Low-Level File I/O in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!