数据集 —— ground truth 数据集

来源:互联网 发布:淘宝访客来源 网址 编辑:程序博客网 时间:2024/06/05 17:15

1. matlab 自带含 ground truth 数据集

%% 加载停车标志数据到内存;data = load('stopSignsAndCars.mat', 'stopSignsAndCars');stopSignsAndCars = data.stopSignsAndCars;% 将 stopSignsAndCars 下的图像名,拓展为绝对路径加图像名,以方便读取imagePath = fullfile(toolboxdir('vision'), 'visiondata');stopSignsAndCars.imageFilename = fullfile(imagePath, stopSignsAndCars.imageFilename);summary(stopSignsAndCars)               % 查看该数据集的主要描述信息,主要标注了 stop sign,car rear:车尾,car front:车头stopSignsAndCarRears = stopSignsAndCars(:, {'imageFilename', 'stopSign', 'carRear'});% 使用已给的标注信息,对其中一副图像进行标注I = imread(stopSignsAndCarRears.imageFilename{1});I = insertObjectAnnotation(I, 'rectangle', stopSignsAndCarRears.stopSign{1}, 'stop sign', 'linewidth', 4, 'color', 'r');I = insertObjectAnnotation(I, 'rectangle', stopSignsAndCarRears.carRear{1}, 'car rear', 'linewidth', 4, 'color', 'g');imshow(I)



0 0