Visualize object detections

Draw bounding boxes on images to visualize object detection results.

Images · Notebook · Updated

Colab runs it in your browser. If it calls a model provider, it asks for that provider's API key in a cell.

How it works

You create a pipeline that detects objects and then draws the results on the original image.

What it covers

  • Run object detection with YOLOX
  • Draw bounding boxes on images
  • Color-code by object class

What it uses

Install
terminal
pip install pixeltable pixeltable-yolox
Pixeltable calls
yolox.yolox()vision.bboxes_draw()pxt.create_table()add_computed_column()insert()

A look at the code

img-visualize-detections.ipynb
# Step 1: Run object detection
images.add_computed_column(
detections=yolox(images.image, model_id='yolox_m', threshold=0.5)
)

One cell of the notebook, copied as it is. Open it in Colab for the rest.

Browse all 103