How to rearrange tables

3 Ansichten (letzte 30 Tage)
Conner Carriere
Conner Carriere am 21 Nov. 2022
Beantwortet: Matt J am 21 Nov. 2022
I am working with a CNN and need to set up mutilple classes, this is what I have so far
I have a table that looks like this (or does in matlab, kinda have to peice stuff together here)
IMAGE | BBOX | Class
"img1" [212,28,300,591] 'Taillight-Damage'
"img2" 3x4 double 3x1 cell
"img3" [188,250,263,148] 'fender-dent'
"img4" [56,219,354,257;338,1,300,330] 2x1 cell
"img5" [96,287,347,350;1,1,238,574] 2x1 cell
"img6" [1,82,342,218;384,132,106,214] 2x1 cell
"img7" [1,240,443,396] 'front-bumper-dent'
"img8" [76,391,359,153] 'Rear-windscreen-Damage'
"img9" [290,206,158,305] 'Taillight-Damage'
"img10" [9,122,629,515] 'front-bumper-dent'
each bounding box coralates to the same image, and class. The 3x1 and 2x1 cells have the class of the respective bbox.
How would I move those into this format on the boxlabeldatastore() function doc
another option is to move it to this format
whatever is easier

Akzeptierte Antwort

Matt J
Matt J am 21 Nov. 2022
Boxes=tbl.BBOX;
Labels=cellfun(@string, tbl.Class,'uni',0);
newtbl=table(Boxes,Labels);

Weitere Antworten (0)

Kategorien

Mehr zu Get Started with Deep Learning Toolbox finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by