Inference

Run inference on an image and retrieve predictions.

Inference via Python SDK (roboflow package) – Deprecated


What's Changed?

Roboflow has introduced more powerful and flexible inference options, including:

  • ✅ Native support for all models

  • ✅ Access to foundation models (YOLO-World, CLIP, OCR, SAM, Florence2, etc.)

  • ✅ Improved performance and latency using GPU-accelerated infrastructure

  • ✅ A simplified and unified inference endpoint


Use These Instead

Use this package for running inference across a wide range of model types, with local and hosted backends supported out-of-the-box. It supports modern use cases like versionless models and foundation models.

👉 Explore: https://inference.roboflow.com


A GPU-accelerated cloud API with unified endpoints for all tasks. Offers lower latency for inference requests and support for powerful models such as Florence2 and SAM2.

🔗 Learn more: Serverless Hosted API V2 Documentation


If you're using older models or workflows, the original serverless API is still available. This includes individual endpoints for object detection, classification, segmentation, and more.

🔗 Learn more: Serverless Hosted API (V1)


Why Deprecate the Python SDK Inference Method?

While the roboflow Python SDK remains useful for other interactions (e.g., uploading data, managing datasets), its inference capabilities have been replaced by more efficient and modern solutions:

  • It does not support all models (models uploaded without dataset version, Roboflow Instant)

  • It offers limited access to newer model types

  • It lacks performance improvements found in GPU-accelerated APIs

  • It is not compatible with newer deployment workflows


Need Help Migrating?

If you're using the legacy SDK for inference and want help transitioning to the new tools, check out our guides at:

Last updated

Was this helpful?