The official Roboflow Python package. Manage your datasets, models, and deployments. Roboflow has everything you need to build a computer vision application.
After troubleshooting a clients uploading problems, I'm making this PR with two incremental QoL features:
Adds -r retry parameter to roboflow import CLI command. This controls how many times the CLI may retry a failed upload before giving up. This is important because sometimes the API will reply with a 503 (GCP is the culprit and there's not much we can do except for retrying)
Adds the actual number of retry attemps to each line log. Which is useful when we see "DUPLICATE" log entries for images that are not really dupes (the cause here is that, we got an error from the API but the upload went through, so the second call returns falsely flagged as duplicate)
When uploading coco datasets, if the image has 0 annotations, the annotation json is not recognized as a valid annotation format. This is a bug in the backend. But I'm adding a workaround here to bypass that condition. The workaround is to add a fake annotation to the list (which will be ignored because it doesn't match the image_id, but makes the backend happy with the format)
Type of change
Please delete options that are not relevant.
[x] Bug fix (non-breaking change which fixes an issue)
[x] Reliability improvements
How has this change been tested, please provide a testcase or example of how you tested the change?
Uploaded the same dataset to prod until I got no errors on my terminal!
Description
After troubleshooting a clients uploading problems, I'm making this PR with two incremental QoL features:
-r retry
parameter toroboflow import
CLI command. This controls how many times the CLI may retry a failed upload before giving up. This is important because sometimes the API will reply with a 503 (GCP is the culprit and there's not much we can do except for retrying)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?
Uploaded the same dataset to prod until I got no errors on my terminal!