Closed corenel closed 6 years ago
Thank you very much for your contribution and your ideas! I don't want to directly implement any format because i want to keep the flexibility at the highest possible level. So i'd rather add functionality to the export creation itself. As far as i see, the path is the only problem here. The filename has the %%image placeholder. Because the path to the file depends on the system i'd recommend using a shell variable (e.g. export IMAGE_SET_PATH='/home/nfiedler/Bit-Bots/imagetagger') and saving the images in a directory in that path named after the imageset. Then you could use the export format as follows:
<folder>%%imageset</folder>
<filename>%%image</filename>
<path>$IMAGE_SET_PATH/%%imageset/%%image</path>
Therefore the %%imageset placeholder is needed in the annotation format. This is missing right now.
Thanks for your help! I'v tried this:
for Base format
<annotation>
<folder>%%imageset</folder>
<location>%%setlocation</location>
<team>%%team</eram>
<source>
<database>Unknown</database>
</source>
<segmented>0</segmented>
%%content
</annotation>
for Annotation format
<filename>%%image</filename>
<path>$IMAGE_SET_ROOT/%%imageset/%%image</path>
<size>
<width>%%imagewidth</width>
<height>%%imageheight</height>
<depth>%imagedepth</depth>
</size>
<object>
<name>%%type</name>
<noobject>0</noobject>
<pose>Unspecified</pose>
<truncated>0</truncated>
<difficult>0</difficult>
<verified>%%veriamount</verified>
<bndbox>
<xmin>%%x1</xmin>
<ymin>%%y1</ymin>
<xmax>%%x2</xmax>
<ymax>%%y2</ymax>
</bndbox>
</object>
for Not in image format
<filename>%%image</filename>
<path>$IMAGE_SET_ROOT/%%imageset/%%image</path>
<size>
<width>%%imagewidth</width>
<height>%%imageheight</height>
<depth>%imagedepth</depth>
</size>
<object>
<name>%%type</name>
<noobject>1</noobject>
<pose>Unspecified</pose>
<truncated>0</truncated>
<difficult>0</difficult>
<verified>%%veriamount</verified>
</object>
But there comes two problems:
You don't supply the placeholders for width, height and depth of a single image file;
It seems that current exporting util is designed to export all annotations of all images into single file. I'm wondering if it's convenient for you to add a feature to export all annotations of each image into a single file and then compress them up.
Of course, if you're focusing on add other useful features which is much more important, I can also write a tiny Python script to convert the current all-in-one annotation file into what I desired. That's quite easy.
Thanks for your great contribution on building such an excellent image labelling tool!
Now i understand the problem. I think two features are needed to realize this functionality:
The aggregation of annotations by image would make it very easy to split the file locally until the splitting feature is implemented.
Thanks for your quick reply! Then I'll write my own scripts for temporary use and wait for the splitting feature.
Meanwhile the aggregation by image is possible and the additional placeholders are implemented. I wouldn't like to have the splitting feature on our hosted version, because it leads to a high server load (creation and zipping of thousands of files for large imagesets), and is easily achievable with a simple script on the client side.
I notice that placeholders in
Create new Exportformat
page isn't sufficient to create a PASCAL-VOC-like export format.For example, PASCAL VOC format looks like this:
The
filename
andpath
part isn't shown on given placeholders, thus it's impossible to create a PASCAL-VOC-like export format.I'll appreciate it if you could supply more placeholders, or directly support built-in PASCAL-VOC-like export format.