We're ecstatic to announce the launch of our newest pip package, a way for you to natively interface with your Roboflow workspace through your Python scripts and Jupyter notebooks! Read the full package documentation here.
Your API Key
Each API Key is tied to a specific workspace; treat it like a password and keep it private because your API Key can be used to access and modify the data in your workspace.
Through the Roboflow python package you can:
- Access information about your workspaces, projects, and versions programmatically.
- Upload images locally to your web Roboflow project.
- Perform inference on models you've trained through our web UI.
- Visualize, and save predictions that you've made on the model.
import roboflow rf = roboflow.Roboflow("MY_API_KEY") project = rf.workspace().project("my-project") model = project.versions().model # assuming you have trained a model already predictions = model.predict("IMAGE.jpg") prediction.plot() print(prediction.json()) prediction.save(output_path="predictions.jpg")
We're building a lot more integrations to the Web UI and REST API. Soon enough, you'll be able to upload and download batches of images that are in your projects, start training jobs, and perform preprocessing all through the Roboflow Python Package.
Build something cool with the pip package or have an idea for a feature that might be helpful? Either let us us know on the repository or drop us a line!