# ビデオのフレームにセマンティック・セグメンテーションを適用する

モデルのパイプライン・コマンドを実行する前に、必ず必要となる [前提条件](https://docs.qualcomm.com/doc/80-70018-15BJ/topic/ai-hub-qualcomm-im-sdk.html#prerequisites) に従ってください。

以下のコマンドを実行し、接続されたディスプレイに結果が表示されることを確認します。

export XDG_RUNTIME_DIR=/dev/socket/weston && export WAYLAND_DISPLAY=wayland-1
    Copy to clipboard

## DeepLabV3-Plus\_MobileNet-Quantized

DeepLabv3 Quantizedは、複数のスケールでのセマンティック・セグメンテーション用に設計されており、さまざまなデータセットで学習済みです。

AI Hubモデルは、 [このDeepLabV3-Plus-MobileNet-Quantized の実装](https://github.com/jfzhang95/pytorch-deeplab-xception) に基づいています。

- モデル： [deeplabv3_plus_mobilenet_quantized.tflite](https://aihub.qualcomm.com/iot/models/deeplabv3_plus_mobilenet_quantized)
- ラベル： [voc_labels.txt](https://github.com/quic/ai-hub-models/blob/main/qai_hub_models/labels/voc_labels.txt)

gst-launch-1.0 -e --gst-debug=2 \
    filesrc location=/etc/media/video.mp4 ! qtdemux ! queue ! h264parse ! v4l2h264dec capture-io-mode=4 output-io-mode=4 ! video/x-raw,format=NV12 ! queue ! tee name=split \
    split. ! queue ! qtivcomposer name=mixer sink_1::alpha=0.5 ! queue ! waylandsink sync=true fullscreen=true \
    split. ! queue ! qtimlvconverter ! queue ! qtimltflite delegate=external external-delegate-path=libQnnTFLiteDelegate.so \
    external-delegate-options="QNNExternalDelegate,backend_type=htp;" model=/etc/models/deeplabv3_plus_mobilenet_quantized.tflite ! queue ! \
    qtimlvsegmentation module=deeplab-argmax labels=/etc/labels/voc_labels.txt \
    constants="deeplab,q-offsets=<92.0>,q-scales=<0.04518842324614525>;" ! video/x-raw,format=BGRA,width=256,height=144 ! queue ! mixer.
    Copy to clipboard

## FCN-Resnet50-Quantized

FCN\_ResNet50は、COCOデータセットから画像をセグメント化できる量子化された機械学習モデルです。

AI Hubモデルは、[このFCN-ResNet50-Quantizedの実装](https://github.com/pytorch/vision/blob/main/torchvision/models/segmentation/fcn.py) に基づいています。

- モデル： [FCN-ResNet50-Quantized.tflite](https://aihub.qualcomm.com/iot/models/fcn_resnet50_quantized)
- ラベル： [voc_labels.txt](https://github.com/quic/ai-hub-models/blob/main/qai_hub_models/labels/voc_labels.txt)

注釈

このパイプラインは現在、QCS6490ではサポートされていません。

gst-launch-1.0 -e --gst-debug=2 \
    filesrc location=/etc/media/video.mp4 ! qtdemux ! queue ! h264parse ! v4l2h264dec capture-io-mode=4 output-io-mode=4 ! video/x-raw,format=NV12 ! queue ! tee name=split \
    split. ! queue ! qtivcomposer name=mixer sink_1::alpha=0.5 ! queue ! waylandsink sync=true fullscreen=true \
    split. ! queue ! qtimlvconverter ! queue ! qtimltflite delegate=external external-delegate-path=libQnnTFLiteDelegate.so \
    external-delegate-options="QNNExternalDelegate,backend_type=htp;" model=/etc/models/fcn_resnet50_quantized.tflite ! queue ! \
    qtimlvsegmentation module=deeplab-argmax labels=/etc/labels/voc_labels.txt \
    constants="deeplab,q-offsets=<0.0>,q-scales=<1.0>;" ! video/x-raw,format=BGRA,width=256,height=144 ! queue ! mixer.
    Copy to clipboard

## FFNet-40S-Quantized

FFNet-40S-Quantizedは「手間のかからないネットワーク」で、道路、歩道、歩行者などのピクセルごとのクラスで街路風景画像をセグメント化します。

都市景観データセットで学習済みです。

AI Hubモデルは、[このFFNet-40S-Quantizedの実装](https://github.com/Qualcomm-AI-research/FFNet) に基づいています

- モデル： [ffnet_40s_quantized.tflite](https://aihub.qualcomm.com/iot/models/ffnet_40s_quantized)
- ラベル： [voc_labels.txt](https://github.com/quic/ai-hub-models/blob/main/qai_hub_models/labels/voc_labels.txt)

gst-launch-1.0 -e --gst-debug=2 \
    filesrc location=/etc/media/video.mp4 ! qtdemux ! queue ! h264parse ! v4l2h264dec capture-io-mode=4 output-io-mode=4 ! video/x-raw,format=NV12 ! queue ! tee name=split \
    split. ! queue ! qtivcomposer name=mixer sink_1::alpha=0.5 ! queue ! waylandsink sync=false fullscreen=true \
    split. ! queue ! qtimlvconverter ! queue ! qtimltflite delegate=external external-delegate-path=libQnnTFLiteDelegate.so \
    external-delegate-options="QNNExternalDelegate,backend_type=htp;" model=/etc/models/ffnet_40s_quantized.tflite ! queue ! \
    qtimlvsegmentation module=deeplab-argmax labels=/etc/labels/voc_labels.txt constants="ffnet,q-offsets=<178.0>,q-scales=<0.31378185749053955>;" ! \
    video/x-raw,format=BGRA,width=256,height=144 ! queue ! mixer.
    Copy to clipboard

## FFNet-54S-Quantized

FFNet-54S-Quantizedは「手間のかからないネットワーク」で、道路、歩道、歩行者などのピクセルごとのクラスで街路風景画像をセグメント化します。

都市景観データセットで学習済みです。

AI Hubモデルは、[このFFNet-54S-Quantizedの実装](https://github.com/Qualcomm-AI-research/FFNet) に基づいています。

- モデル： [ffnet_54s_quantized.tflite](https://aihub.qualcomm.com/iot/models/ffnet_54s_quantized)
- ラベル： [voc_labels.txt](https://github.com/quic/ai-hub-models/blob/main/qai_hub_models/labels/voc_labels.txt)

gst-launch-1.0 -e --gst-debug=2 \
    filesrc location=/etc/media/video.mp4 ! qtdemux ! queue ! h264parse ! v4l2h264dec capture-io-mode=4 output-io-mode=4 ! video/x-raw,format=NV12 ! queue ! tee name=split \
    split. ! queue ! qtivcomposer name=mixer sink_1::alpha=0.5 ! queue ! waylandsink sync=false fullscreen=true \
    split. ! queue ! qtimlvconverter ! queue ! qtimltflite delegate=external external-delegate-path=libQnnTFLiteDelegate.so \
    external-delegate-options="QNNExternalDelegate,backend_type=htp;" model=/etc/models/ffnet_54s_quantized.tflite ! queue ! \
    qtimlvsegmentation module=deeplab-argmax labels=/etc/labels/voc_labels.txt constants="ffnet,q-offsets=<178.0>,q-scales=<0.2929433584213257>;" ! \
    video/x-raw,format=BGRA,width=256,height=144 ! queue ! mixer.
    Copy to clipboard

## FFNet-78S-Quantized

FFNet-78S-Quantizedは「手間のかからないネットワーク」で、道路、歩道、歩行者などのピクセルごとのクラスで街路風景画像をセグメント化します。

都市景観データセットで学習済みです。

AI Hubモデルは、[このFFNet-78S-Quantizedの実装](https://github.com/Qualcomm-AI-research/FFNet) に基づいています。

- モデル： [ffnet_78s_quantized.tflite](https://aihub.qualcomm.com/iot/models/ffnet_78s_quantized)
- ラベル： [voc_labels.txt](https://github.com/quic/ai-hub-models/blob/main/qai_hub_models/labels/voc_labels.txt)

gst-launch-1.0 -e --gst-debug=2 \
    filesrc location=/etc/media/video.mp4 ! qtdemux ! queue ! h264parse ! v4l2h264dec capture-io-mode=4 output-io-mode=4 ! video/x-raw,format=NV12 ! queue ! tee name=split \
    split. ! queue ! qtivcomposer name=mixer sink_1::alpha=0.5 ! queue ! waylandsink sync=false fullscreen=true \
    split. ! queue ! qtimlvconverter ! queue ! qtimltflite delegate=external external-delegate-path=libQnnTFLiteDelegate.so \
    external-delegate-options="QNNExternalDelegate,backend_type=htp;" model=/etc/models/ffnet_78s_quantized.tflite ! queue ! \
    qtimlvsegmentation module=deeplab-argmax labels=/etc/labels/voc_labels.txt constants="ffnet,q-offsets=<171.0>,q-scales=<0.3849360942840576>;" ! \
    video/x-raw,format=BGRA,width=256,height=144 ! queue ! mixer.
    Copy to clipboard

Last Published: Oct 15, 2025

[Previous Topic
物体検出](https://docs.qualcomm.com/bundle/publicresource/80-70018-15BJ/topics/object-detection.md) [Next Topic
超解像度で画像をアップスケールする](https://docs.qualcomm.com/bundle/publicresource/80-70018-15BJ/topics/super-resolution.md)