Skip to main content

Api for Box21.ai

Project description

box21_api

A python package for interacting with your Box21 via the api

Install

pip install box21_api

How to use

from box21_api.box21_api import Box21Api
box21_api = Box21Api(API_USERNAME, API_PASSWORD, 'https://box21.ai', 443, API_PROJECT_ID)
labels = box21_api.get_labels()
print('Number of labels retrieved', len(labels))
print('First label', labels[0])
Number of labels retrieved 2
First label Label(('Bounding box', 'Chital', 1))
annotations = box21_api.get_label_annotations(labels[0])
print('Number of annotations retrieved', len(annotations))
print('First annotation', annotations[0])
Number of annotations retrieved 2
First annotation BoundingBox(Chital, (0.1641, 0.5291, 0.2766, 0.3381))
first_annotation = annotations[0]
pil_image = box21_api.download_asset(first_annotation.asset_id)
pil_image

See more examples on: https://ramonhollands.github.io/box21_api/

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

box21_api-0.0.7.tar.gz (11.7 kB view details)

Uploaded Source

Built Distribution

box21_api-0.0.7-py3-none-any.whl (24.4 kB view details)

Uploaded Python 3

File details

Details for the file box21_api-0.0.7.tar.gz.

File metadata

  • Download URL: box21_api-0.0.7.tar.gz
  • Upload date:
  • Size: 11.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.8.14

File hashes

Hashes for box21_api-0.0.7.tar.gz
Algorithm Hash digest
SHA256 481bd3a48b7d905fe2db65cf3256b62f4b343f6fb6c418725161835ebcf46245
MD5 936c8a7d919ca943e8691b3cce78b94d
BLAKE2b-256 398173a662b9b2d31080fc38041ebfade676c1390cc4566e8ca827ad592a2b76

See more details on using hashes here.

File details

Details for the file box21_api-0.0.7-py3-none-any.whl.

File metadata

  • Download URL: box21_api-0.0.7-py3-none-any.whl
  • Upload date:
  • Size: 24.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.8.14

File hashes

Hashes for box21_api-0.0.7-py3-none-any.whl
Algorithm Hash digest
SHA256 9745fcf331f23159fd59ffbbcbc4cfebbe1f7201a0b4b5be4cedc428f90b20cb
MD5 001c62af2c3b4196a24f3790915ef893
BLAKE2b-256 248372f2e0b6081f8ae92bf7ccfc24e5662a89e92476c7507ac978bfc44d352c

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page