# Integrate an AI Hub model in an application

This section describes how to use an AI Hub model in a
reference application. This example uses an image classification
model from AI Hub.

Note

Preprocessing and postprocessing for most of the publicly available image classification
models is similar and is likely supported by the `qtimlpostprocess` plugin.

Qualcomm AI Hub provides optimized AI models for Qualcomm devices,
allowing them to operate on CPU, GPU, or NPU using either LiteRT
(previously Tensorflow Lite) or Qualcomm® AI Engine Direct.

This example explains how to use a
[inception_v3](https://aihub.qualcomm.com/iot/models/inception_v3)
model from AI Hub and integrate the model into the
`gst-ai-classification` reference application.

| **S.No** | **Reference Application** | **Verified AI Hub model** | **Label file** |
| --- | --- | --- | --- |
| 1 | gst-ai-classification | GoogLeNet | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/classification.json) |
| 2 | gst-ai-classification | inception\_v3 | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/classification.json) |
| 3 | gst-ai-classification | mobilenet-v2 | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/classification.json) |
| 4 | gst-ai-classification | MobileNet-v3-Large | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/classification.json) |
| 5 | gst-ai-classification | ResNet101 | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/classification.json) |
| 6 | gst-ai-classification | SqueezeNet-1\_1 | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/classification.json) |
| 7 | gst-ai-classification | ResNet18 | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/classification.json) |
| 8 | gst-ai-classification | ResNeXt50 | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/classification.json) |
| 9 | gst-ai-classification | WideResNet50 | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/classification.json) |
| 10 | gst-ai-classification | Shufflenet-v2 | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/classification.json) |
| 11 | gst-ai-classification | ResNeXt101 | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/classification.json) |
| 12 | gst-ai-segmentation | deeplabv3\_plus\_mobilenet | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/deeplabv3_resnet50.json) |
| 13 | gst-ai-segmentation | fcn\_resnet50[\[1\]](https://docs.qualcomm.com/doc/80-80022-15B/topic/integrate-ai-hub-models.html#f1) | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/deeplabv3_resnet50.json) |
| 14 | gst-ai-segmentation | ffnet\_40s | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/deeplabv3_resnet50.json) |
| 15 | gst-ai-segmentation | ffnet\_54s | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/deeplabv3_resnet50.json) |
| 16 | gst-ai-segmentation | ffnet\_78s | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/deeplabv3_resnet50.json) |
| 17 | gst-ai-object-detection | Yolo-v7 | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/yolox.json) |
| 18 | gst-ai-object-detection | YOLOv8-Detection | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/yolox.json) |
| 19 | gst-ai-superresolution | QuickSRNetLarge | Not applicable |
| 20 | gst-ai-superresolution | QuickSRNetMedium | Not applicable |
| 21 | gst-ai-superresolution | QuickSRNetSmall | Not applicable |
| 22 | gst-ai-superresolution | XLSR | Not applicable |
| 23 | gst-ai-monodepth | Midas-V2 | [Labels](https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/monodepth.json) |
| 24 | gst-ai-pose-detection | HRNetPose | <ul class="simple"><br><li><p><a href="https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/hrnet_pose.json" class="xref cursorpointer" onclick="Window.BookmapComponent.navigateExternalFile('https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/hrnet_pose.json')">Labels</a></p></li><br><li><p><a href="https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/hrnet_settings.json" class="xref cursorpointer" onclick="Window.BookmapComponent.navigateExternalFile('https://github.com/quic/sample-apps-for-qualcomm-linux/blob/main/qualcomm-linux/artifacts/json_labels/hrnet_settings.json')">Settings</a></p></li><br></ul> |
|  |  |  |  |
|  |  |  |  |
|  |  |  |  |
|  |  |  |  |
|  |  |  |  |
|  |  |  |  |
|  |  |  |  |
|  |  |  |  |
|  |  |  |  |
|  |  |  |  |

[[1](https://docs.qualcomm.com/doc/80-80022-15B/topic/integrate-ai-hub-models.html#id1)]

FCN-Resnet50 Model is not supported on QCS6490.

Note

Some models only have LiteRT or Qualcomm AI Engine Direct
SDK models available with AI Hub. However, AI Hub frequently updates
its library to include more models and enhance existing ones.

Prerequisites

1. Download [AI Hub models](https://aihub.qualcomm.com/iot/models/inception_v3).

    1. Search for the model in the search bar and select the model.
    2. Select the runtime, precision, and device for which you want to download the model.

        - Runtime: *TFLite*
        - Precision: *w8a8*
        - Device:

            - Qualcomm Dragonwing™ RB3 Gen 2: *Qualcomm QCS6490*
            - Qualcomm Dragonwing™ IQ-9075: *Qualcomm QCS9075*
2. Copy the label file that matches the model to the device.

    The label and media files are available for download at the following locations:

    - [Label files](https://github.com/quic/sample-apps-for-qualcomm-linux/tree/main/qualcomm-linux/artifacts/json_labels).
    - [Media files](https://github.com/quic/sample-apps-for-qualcomm-linux/tree/main/qualcomm-linux/artifacts/videos)

Note

The following sections use placeholder model names for models downloaded through AI Hub.
Update the model name in the commands with the appropriate model name as downloaded
through AI Hub.
3. [Download the necessary scripts and artifacts](https://docs.qualcomm.com/doc/80-80022-15B/topic/classify-objects-with-default-model.html#download-model-files).

Note

You can skip this step if you have already completed Steps 1 and 2.

## Modify the configuration

1. On the host device, run the following command:

export USER=root
        Copy to clipboard
2. Copy the model to the device.

scp inception_v3-inception-v3-w8a8.tflite $USER@<IP address of the target device>:/etc/models/
        Copy to clipboard
3. Copy the labels to the device.

wget https://raw.githubusercontent.com/quic/sample-apps-for-qualcomm-linux/refs/heads/main/qualcomm-linux/artifacts/json_labels/classification.json
        Copy to clipboard

scp classification.json $USER@<IP addr of the target device>:/etc/labels/
        Copy to clipboard
4. Update the `/etc/configs/config_classification.json` file as shown below.

{
        "file-path": "/etc/media/video.mp4",
        "ml-framework": "tflite",
        "model": "/etc/models/inception_v3-inception-v3-w8a8.tflite",
        "labels": "/etc/labels/classification.json",
        "threshold": 40,
        "runtime": "dsp"
        }
        Copy to clipboard

## Run the sample application

1. Run the reference application:

gst-ai-classification --config-file=/etc/configs/config_classification.json
        Copy to clipboard
2. Use sample applications to run various AI Hub models
on your devices. To run different AI Hub models:

    1. Download the model and label files that you want to run.
    2. Copy the model and label files to the device.
    3. Run the sample application by following the steps below.

Tab gst-ai-object-detection
Tab gst-ai-segmentation
Tab gst-ai-superresolution

1. Download the [Yolox Quantized LiteRT model file](https://aihub.qualcomm.com/iot/models/yolox)
(used for object detection).
        2. Update the `/etc/configs/config_detection.json` file as shown below.

{
                "file-path": "/etc/media/video.mp4",
                "ml-framework": "tflite",
                "yolo-model-type": "yolox",
                "model": "/etc/models/yolox_quantized.tflite",
                "labels": "/etc/labels/yolox.json",
                "threshold": 40,
                "runtime": "dsp"
                }
                Copy to clipboard

Note

Update the model name in the configuration file according to the model you obtained.
        3. Run the sample app.

Note

Ensure that you have copied the model and label files to the device.

gst-ai-object-detection --config-file=/etc/configs/config_detection.json
                Copy to clipboard

1. Update the `/etc/configs/config_segmentation.json` file as follows:

            Take the `deeplabv3_plus_mobilenet_quantized.tflite` model file (used
for segmentation) and the `deeplabv3_resnet50.json` file as an
example.

{
                "file-path": "/etc/media/video.mp4",
                "ml-framework": "tflite",
                "model": "/etc/models/deeplabv3_plus_mobilenet_quantized.tflite",
                "labels": "/etc/labels/deeplabv3_resnet50.json",
                "runtime": "dsp"
                }
                Copy to clipboard
        2. Run the sample app.

gst-ai-segmentation --config-file=/etc/configs/config_segmentation.json
                Copy to clipboard

1. Update the `/etc/configs/config-superresolution.json` file as shown below.

{
                "input-file-path": "/etc/media/video.mp4",
                "model": "/etc/models/quicksrnetsmall_quantized.tflite",
                "output-file-path":"/etc/media/out.mp4"
                }
                Copy to clipboard
        2. Run the sample app:

gst-ai-superresolution --config-file=/etc/configs/config-superresolution.json
                Copy to clipboard

Note

Ensure that the video used has a 128x128 resolution, which is the input to the model.

        For additional details regarding the input parameters, see the
help section of the application.

Note

In cases of segmentation, objects that aren’t recognized
may appear against a white background. This issue stems from the
label file and will be addressed in future updates.
3. Recompile the reference application if you want to make any changes
and run it. See the [Qualcomm Intelligent Multimedia Software Development Kit (IM SDK) Quick Start Guide](https://docs.qualcomm.com/doc/80-80022-51/topic/introduction.html)
for instructions on how to compile reference applications with the eSDK.

Last Published: May 14, 2026

[Previous Topic
Integrate a custom AI model in an application](https://docs.qualcomm.com/bundle/publicresource/80-80022-15B/topics/integrate-custom-model.md) [Next Topic
Add postprocessing support for a custom model](https://docs.qualcomm.com/bundle/publicresource/80-80022-15B/topics/add-postprocessing-support-custom-model.md)

Source: [https://docs.qualcomm.com/doc/80-80022-15B/topic/integrate-ai-hub-models.html](https://docs.qualcomm.com/doc/80-80022-15B/topic/integrate-ai-hub-models.html)