Labelbox Python API
Project description
Labelbox Python API
Labelbox is the training data workbench for ML teams. It allows you to label data with the fastest and most intuitive annotation tools. Visit https://labelbox.com/ for more information.
The Labelbox Python API allows you to interact with Labelbox back-end in a simple, user-friendly way.
Requirements
To use the Labelbox Python API you will need a Labelbox account. Once you login to the Labelbox web page, generate an API key as described in the documentation: https://labelbox.com/docs/api/api-keys. Store the key to a safe location. You will need it for using the Labelbox Python API.
Installation
Labelbox Python API can be installed using Python's Pip manager:
pip install labelbox
Usage
API Key
Your Labelbox API key is required to execute the library. It can be passed to
Labelbox Python API via an environment variable LABELBOX_API_KEY
. It is then
automatically picked up by the Client
:
from labelbox import Client
client = Client() # will use the API key from the environment variable
Alternatively you can pass it to the Client
object initialization:
from labelbox import Client
client = Client("<your_api_key_here>")
Basic commands
The Labelbox Python API allows you to create, update and delete all standard Labelbox data types, such as Projects, Datasets, DataRows, Labels and others. For more info about the Labelbox data model please visit https://labelbox.com/docs.
Here is an example code for uploading some data from scratch:
from labelbox import Client
client = Client()
# Create a project and a dataset , automatically reflected on the server
project = client.create_project(name="My Great Project")
dataset = client.create_dataset(name="My Dataset")
project.datasets.connect(dataset)
# Upload some files to the dataset
task = dataset.create_data_rows(['file1.jpg', 'file2.jpg'])
# Bulk DataRow creation might take a while on the server-side
task.wait_till_done()
# Your data is now uploaded to Labelbox and ready for labeling!
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file labelbox-2.1.tar.gz
.
File metadata
- Download URL: labelbox-2.1.tar.gz
- Upload date:
- Size: 21.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f97f01bf030b115d8b7f7b12a10ec5efe54750ad66b6b3567550b517a543ad11 |
|
MD5 | 990b060cc1198de50dc499f7bb8e2544 |
|
BLAKE2b-256 | 6e0d8302afd18b51bd79272fefbf0554dbe9ef733f303c5371b870a7e6a79ac4 |
File details
Details for the file labelbox-2.1-py3-none-any.whl
.
File metadata
- Download URL: labelbox-2.1-py3-none-any.whl
- Upload date:
- Size: 28.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9f8ac07351625ff64e6e1c9f486abb6cd003b2ef523ca77a867b2fc7772e6a88 |
|
MD5 | 08084f8336381e36b6d98e9046b8c3cf |
|
BLAKE2b-256 | 8ff0d761483a981a5659cd0080b56c114146970b20eacb45efb98ef84eca8909 |