-
Notifications
You must be signed in to change notification settings - Fork 77
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
new upload parameter for overwriting annotations #216
new upload parameter for overwriting annotations #216
Conversation
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.
Really nice work! Just one comment about supporting backwards compatibility on the single_upload
method.
roboflow/core/project.py
Outdated
@@ -469,6 +469,7 @@ def single_upload( | |||
image_path=None, | |||
annotation_path=None, | |||
annotation_labelmap=None, | |||
annotation_overwrite=False, |
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.
Can you move to the end of the parameters list so as to keep backwards compatible with previous versions?
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.
Done :)
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.
@SolomonLake I accidentally closed the issue before actually merging. I think you need to approve a second time. Sorry for the inconvenience.
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.
Failed to build due to styling -- running make style
in the root directory should fix the issue.
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.
Hope the styling checks out now.
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.
Looks good, i'll merge the PR now!
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.
LGTM, after you merge it will be included in the next package release.
Description
Added a new parameter for the single_upload method to enable overwriting annotations via the API. This has been requested by multiple other users. The option was available via the REST API, but not the python SDK.
Type of change
Please delete options that are not relevant.
How has this change been tested, please provide a testcase or example of how you tested the change?
Tested upload of image with annotations then deleted part of the annotations manually, and re-uploaded only the annotations.
Any specific deployment considerations
One of the unittests was already broken on the main branch (
test_download_returns_dataset
intests.test_version
. I did not touch this.Docs