Last updated 2 months ago
from aibrary import AiBrary aibrary = AiBrary() # 1 aibrary.object_detection( providers="google", file=open("tests/assets/ocr-test.jpg", "rb").read(), file_name="test.jpg", ) # 2 aibrary.object_detection( providers="google", file_url="https://builtin.com/sites/www.builtin.com/files/styles/ckeditor_optimize/public/inline-images/5_python-ocr.jpg", ) # 3 aibrary.object_detection( providers="google", file="tests/assets/ocr-test.jpg" )
true
false
POST /v0/images/object_detection HTTP/1.1 Host: api.aibrary.dev Authorization: Bearer YOUR_SECRET_TOKEN Content-Type: multipart/form-data Accept: */* Content-Length: 174 { "providers": "text", "settings": "text", "response_as_dict": true, "attributes_as_list": false, "show_base_64": true, "show_original_response": false, "file": "binary", "file_url": "text" }
Successful Response
{ "items": [ { "label": "text", "confidence": 1, "x_min": null, "x_max": null, "y_min": null, "y_max": null } ] }