> ## Documentation Index
> Fetch the complete documentation index at: https://imsdkdocs.qualcomm.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Quickstart Guide

> Explore object detection pipelines with QIM SDK

## Object detection

<video src="https://mintcdn.com/qimsdk/tjig8H-FpOyOkPbR/blogs/images/obj_detect.mp4?fit=max&auto=format&n=tjig8H-FpOyOkPbR&q=85&s=dab7bd7d30189ed6486fb4455bf26720" autoPlay muted loop playsInline style={{ width: "100%", height: "auto", display: "block" }} data-path="blogs/images/obj_detect.mp4" />

**Given a video frame, identify objects, and draw bounding boxes around them**.

<Note>
  Ensure you have QIM SDK installed. [QIM SDK Installation Guide](/installation)
</Note>

## Prerequisites

Run these commands on your device first:

<Accordion title="Set environment variables">
  ```bash theme={null}
  mkdir -p $HOME/Downloads/qimsdk_samples/models $HOME/Downloads/qimsdk_samples/labels $HOME/Downloads/qimsdk_samples/media $HOME/Downloads/qimsdk_samples/media/output
  export MODEL_NAME=yolox_w8a8.tflite
  export LABELS_NAME=yolov8.json
  export SRC_VIDEO_NAME=ai_demo_sample.mp4
  ```
</Accordion>

<Accordion title="Download the label, model, and video file">
  ```bash theme={null}
  # Download YOLO-X W8A8 model
  curl -L -o $HOME/models/$MODEL_NAME \
    https://huggingface.co/Qualcomm/Yolo-X/resolve/v0.30.5/Yolo-X_w8a8.tflite

  # Download detection labels
  curl -L -o $HOME/labels/$LABELS_NAME \
    https://imsdkdocs.qualcomm.com/labels/yolov8.json

  # Download sample video
  curl -L -o $HOME/media/$SRC_VIDEO_NAME \
    https://github.com/qualcomm/sample-apps-for-qualcomm-linux/raw/refs/heads/main/qualcomm-linux/artifacts/videos/demo_samples/ai_demo_sample.mp4
  ```
</Accordion>

***

## Object detection pipeline command

<Note>
  Ensure you have followed the [prerequisites](/quickstart#prerequisites) before continuing
</Note>

<Steps>
  <Step title="Run the pipeline command">
    ```bash theme={null}
    gst-launch-1.0 -e --gst-debug=2 \
    filesrc location=$HOME/media/$SRC_VIDEO_NAME ! qtdemux ! h264parse ! \
    v4l2h264dec capture-io-mode=4 output-io-mode=4 ! video/x-raw,format=NV12 ! queue ! \
    tee name=t ! qtimetamux name=obj_mux ! qtivoverlay ! waylandsink fullscreen=true sync=true \
    t. ! queue ! qtimlvconverter ! queue ! \
    qtimltflite model=$HOME/models/$MODEL_NAME delegate=external external-delegate-path=libQnnTFLiteDelegate.so external-delegate-options="QNNExternalDelegate,backend_type=htp,log_level=(string)1;" ! queue ! \
    qtimlpostprocess module=yolov8 labels=$HOME/labels/$LABELS_NAME settings="{\"confidence\": 51.0}" ! text/x-raw ! queue ! obj_mux.
    ```
  </Step>

  <Step title="View results">
    Your display shows the video feed with bounding boxes and class labels rendered over each detected object. The pipeline processes frames in real time <br /> Press `Ctrl+C` to stop the pipeline gracefully.

    * In case you want to build around this demo, command line might not be the most robust solution
    * You could paste it into a shell file...
    * But if you want other code to interact with this, you would want a cpp or python file (pipeline application).
  </Step>
</Steps>

***

## How it works

The pipeline reads an H.264 video file, hardware-decodes it, branches the decoded stream, runs YOLO-X inference on the Qualcomm® AI Engine (HTP backend), post-processes the bounding-box results, blends the annotations back onto the original frame using a hardware compositor, and displays the output to a screen.

**Pipeline Diagram**

<img src="https://mintcdn.com/qimsdk/p8bRJ_K0_Mx14HV0/images/qsg.png?fit=max&auto=format&n=p8bRJ_K0_Mx14HV0&q=85&s=4503460bd827deddecf0ef2e41c81650" alt="Pipeline Diagram" width="2365" height="571" data-path="images/qsg.png" />

***

## Next Steps

You've run an object detection pipeline on Qualcomm® hardware. Here's where to go next:

<CardGroup cols={2}>
  <Card title="AI Sample Pipelines" icon="book-open" href="/sample-pipelines/aipipelines">
    Ready-to-run GStreamer pipelines for classification, segmentation, pose estimation, super resolution, and more.
  </Card>

  <Card title="Blogs" icon="message" href="/blogs/blog-index">
    Real-world examples built by the QIM SDK community — covering object detection, PPE compliance, security cameras, and more.
  </Card>

  <Card title="Supported Models" icon="people-carry-box" href="/supportedmodels">
    Full catalogue of quantized TFLite models tested on Qualcomm® hardware, with pipeline commands for each.
  </Card>

  <Card title="Plugin Reference" icon="book" href="/plugin-reference">
    API-level documentation for every QIM SDK GStreamer plugin — properties, caps, and usage examples.
  </Card>
</CardGroup>
