HumanSignal / labelImg

LabelImg is now part of the Label Studio community. The popular image annotation tool created by Tzutalin is no longer actively being developed, but you can check out Label Studio, the open source data labeling tool for images, text, hypertext, audio, video and time-series data.
https://youtu.be/p0nR2YsCY_U
MIT License
22.51k stars 6.27k forks source link

"Save as" filename bug: "Save as" truncates filename if no extension is added in "File name:" textbox #317

Open Shappenny opened 6 years ago

Shappenny commented 6 years ago

When using "File -> Save As" to save a label in either PascalVOC or YOLO format, if no extension is added to the filename, the tool truncates the filename to 44 characters then adds the extension. This behavior happens whether or not any bounding boxes have been drawn. Once the appropriate file extension is added to the name, the label file is saved with the proper name.

I'm using the 1.7.0 release executable for Windows that's available for download from your github.io page.

I've attached a screenshot to try and illustrate this bug. github_labelimg_bug_filenametruncation

vdalv commented 6 years ago

I was able to recreate the issue when using the v1.7.0 binary as you mentioned, but not when I run the latest code... So in the meantime I recommend running/building from source. I personally run it from Anaconda, which was a pretty painless setup.

Side-note: Are you using the 'Save as' operation for every image? If you set a default save directory (clicking the "Change Save Dir" button), then simply clicking the Save button will save the annotation file in that dir... Side-note2: Having parentheses and spaces in your filenames may cause some issues down the road

vdalv commented 6 years ago

Bump @Shappenny

Shappenny commented 6 years ago

Thanks for looking into it. It's a pretty obscure edge case, so I'll just work around it for now.

Side-note: No, just for images with no labels in order to create an empty label file. The "Save" button and "Ctrl-S" do nothing for me unless there's at least one label drawn on the image, even with the save dir set.

Side-note2: Yeah, though the code creating those file names is legacy and it hasn't been a priority to change it.

Thanks, Sean

On Sat, Jun 23, 2018, 00:38 vdalv notifications@github.com wrote:

I was able to recreate the issue when using the v1.7.0 binary as you mentioned, but not when I run the latest code... So in the meantime I recommend running/building from source https://github.com/tzutalin/labelImg#windows. I personally run it from Anaconda, which was a pretty painless setup https://github.com/tzutalin/labelImg#windows--anaconda.

Side-note: Are you using the 'Save as' operation for every image? If you set a default save directory (clicking the "Change Save Dir" button), then simply clicking the Save button will save the annotation file in that dir... Side-note2: Having parenthesis and spaces in your filenames may cause some issues down the road

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/tzutalin/labelImg/issues/317#issuecomment-399647403, or mute the thread https://github.com/notifications/unsubscribe-auth/AGbCB7Codpxrwxb7sSMt24pUKC5Oxcbxks5t_fBYgaJpZM4Uy_Ue .

vdalv commented 6 years ago

Thanks for bringing it to our attention anyhow, I'll be sure to look out for it in the next release.

With regards to creating an empty label file, the "Verify Image" button will allow you to do that. I've been meaning to update the docs with that info for a while now, should get around to it soon.

Best,

-Vlad

Shappenny commented 6 years ago

You're welcome.

Ahh, thanks for the tip! I didn't really know what that button does, but that'll be much easier to use.

Thanks, Sean

On Thu, Jun 28, 2018, 00:26 vdalv notifications@github.com wrote:

Thanks for bringing it to our attention anyhow, I'll be sure to look out for it in the next release.

With regards to creating an empty label file, the "Verify Image" button will allow you to do that. I've been meaning to update the docs with that info for a while now, should get around to it soon.

Best,

-Vlad

— You are receiving this because you were mentioned.

Reply to this email directly, view it on GitHub https://github.com/tzutalin/labelImg/issues/317#issuecomment-400938742, or mute the thread https://github.com/notifications/unsubscribe-auth/AGbCBwKjzF12RrFoROycw39ltew0yFNOks5uBIURgaJpZM4Uy_Ue .