-
Notifications
You must be signed in to change notification settings - Fork 133
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open Images: implement bounding box support #352
Open Images: implement bounding box support #352
Conversation
Also add a test like in #346 |
I have examined the implementation in #346, and it would be tricky to implement something like that for OID, because the annotation files often don't have fixed names - just possible suffixes. So it wouldn't be possible to specifically remove the annotation files for a particular subset that was removed. Would it work if I just removed all existing annotation files at the beginning of |
Honestly, it is tricky every time. We know from the patch which items were added, removed or modified and which subsets were modified. During writing it is also easy to find out modified subsets that became empty now. Will this information be enough to remove unnecessary files in this format? |
The problem is that we don't know which files which annotations/metadata came from. For the training subset, it could be Although I guess for safety I could do the nuking after the new files are written, instead of before. |
Anyway, I think patching support is a distinct issue from bounding box support, so I think I'm going to work on it separately. |
if label_index is None: | ||
raise UndefinedLabel( | ||
item_id=item.id, subset=item.subset, | ||
label_name=label_name, severity=Severity.error) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think, the severity argument should be separate from the error class. Probably, I see reporting a dataset problem as an Extractor
(Converter
) - base class - method, which could have such severity parameter. Then, it could be handled according to the current error control policy - e.g. a warning could be promoted to an error or ignored. #142. It is a big new feature, though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand - do you want me to change something in the code? I didn't implement the UndefinedLabel
class, I'm just using it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably, this error class is not supposed to be used outside dataset validators. But we can leave it.
Make it explicit that this file can also be used to load bounding box annotations on a machine that doesn't have images at all.
Summary
This continues the implementation of #274.
How to test
You can download some of the bounding boxes for OID, create
images.meta
as described in the documentation and try to import the dataset.Checklist
develop
branchLicense
Feel free to contact the maintainers if that's a concern.