Guide

How do I train YOLOX and export it to ONNX?

Train a YOLOX object detection model on Pictograph and you get an ONNX artifact you can run anywhere. Annotate or import a dataset, call one training function, and download the .onnx file when the run completes. The training runs on managed GPUs, so there is no CUDA setup, no Colab timeout, and no GPU droplet to babysit.

from pictograph import Client
from pictograph.pipelines import train_pipeline

client = Client()

# Export the dataset, train on a managed GPU, fetch the model
run, model = train_pipeline(
    client,
    "road-signs",
    pipeline="yolox",   # object detection
    gpu="a10g",         # a10g / a100
)

client.models.download(model.id, "road_signs.onnx")

What you need first

  • A dataset with bounding box annotations. Label it by hand, with SAM3 auto-annotation, or import it from V7 or Roboflow.
  • At least a handful of images per class so the train, validation, and test split is meaningful.

Step by step

  1. Prepare the dataset. Annotate objects as bounding boxes, since YOLOX is a detector.
  2. Call train_pipeline. It exports the dataset to the format YOLOX expects, starts the run, and waits for completion. Pick gpu="a10g" for most datasets or gpu="a100" for larger ones.
  3. Track progress. The run reports per-epoch progress; train_pipeline returns once the model is ready.
  4. Download the ONNX model. client.models.download(model.id, "...onnx") writes the artifact locally.

A note on naming and output

This is YOLOX, an Apache-2.0 object detection architecture. It is not Ultralytics YOLO, and Pictograph does not impose Ultralytics licensing on your model. The training output is a standard ONNX file, so you can run it with onnxruntime, convert it for an edge target, or serve it directly.

Deploy it in one click

Once you have a trained model, you can stand it up as an always-on endpoint without leaving Pictograph:

deployment = client.deployments.create(model_id=model.id, gpu="t4")
print(deployment.endpoint_url)   # one authenticated /predict URL

See training for the full architecture list and deployments for serving the result.

Start building with computer vision today

$5/mo free compute. No payment method required.