How to convert a .csv file into a MATLAB groundtruth format for different classes of vehicles in a dataset?

2 visualizzazioni (ultimi 30 giorni)
Hi. Below is the attached csv file for different classes of vehicles corresponding to their respective images.
When I open this csv file in MATLAB, after running the following code, I get the following view of the table :
T=readtable('C:\Users\Muhammad Sanwal\Desktop\COMSATS\The 9th Semester (FA20)\FYP pt 1\MIO-TCD-Localization\gt_train.csv');
% ^^^^^^^^^------ your csv filename
p=T{:,1};
q=T{:,2};
save('C:\Users\Muhammad Sanwal\Desktop\COMSATS\The 9th Semester (FA20)\FYP pt 1\MIO-TCD-Localization\gt_train.mat','p','q')
% ^^^^^^^^^----- your resulting .mat filename
Figure 1:Table in .csv format:
Figure 2: Table in .mat format
However, I want the table to be in the following format:
Figure 3: Desired format (with bounding boxes to be shown in square brackets)
Since my vehicle dataset contains more than 100000 images, is there a code that can convert the csv file that i have attached into a table of the desired format? Because doing it manually using image labeler takes a lot of time.
For more details, my friend has posted a similar query in the following link:
Kindly help me solve this problem
  7 Commenti
Ashaikh Saad
Ashaikh Saad il 26 Apr 2022
Modificato: Ashaikh Saad il 26 Apr 2022
Hi @dpb @Muhammad Sanwal @tara saber I am currently working on this dataset and facing the same issue, I would like to convert the above csv file to a YOLO txt or XML format, any help would be highly appreciated. Thanks!

Accedi per commentare.

Risposte (0)

Categorie

Scopri di più su Data Type Conversion in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by