how to read labels of image dataset from mat files

6 visualizaciones (últimos 30 días)
Suheer Ali
Suheer Ali el 28 de Oct. de 2018
Comentada: Suheer Ali el 29 de Oct. de 2018
I have a dataset which contains two folders one for images and another one is the truth_ground which has mat files that has the information about images (number of heads per image) I want to read this dataset so I can get the images with their labels.

Respuesta aceptada

Image Analyst
Image Analyst el 28 de Oct. de 2018
Try this
folder = 'c:\whatever\truth_ground';
fullFileName = fullfile(folder, 'someName.mat')
s = load(fullFileName);
  3 comentarios
Image Analyst
Image Analyst el 28 de Oct. de 2018
Never, ever, EVER overwrite the built in path variable with a variable of your own with the same name. Notice I did not do that. I used folder instead.
You can also use sprintf() - it's simpler than that strcat stuff.
Attach your .mat file if you want more help.
Suheer Ali
Suheer Ali el 29 de Oct. de 2018
hi thanks for your replay I used a dataset in this lisnk
https://github.com/desenzhou/ShanghaiTechDataset
my problem is now with imageDatasore function.
thanks

Iniciar sesión para comentar.

Más respuestas (0)

Community Treasure Hunt

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

Start Hunting!

Translated by