Welcome to Jetson Orin NX Developer Kit repository
当製品の日本語版マニュアル資料は、こちらからご取得ください。
11.Transformer-based person detection
TAO PeopleNet Transformer person detection
TAO PeopleNet Transformer person detection1. Case objective and processing flow2. Checks before running3. Starting the detection4. Real-time detection with a USB camera5. Real-time detection with a CSI camera6. Common issues7. References
Applicable environment: Jetson Orin NX, JetPack 7.2.1, DeepStream 9.1. The video entry point can run and preview.
1. Case objective and processing flow
The PeopleNet Transformer of this course configuration filters out the other classes and only outputs person; it does not detect face or bag. It uses different model assets and a different configuration from the CNN version of PeopleNet, and the engine/parser must not be mixed between them.
Video/USB/CSI → Transformer TensorRT inference → detection box/class → desktop preview
2. Checks before running
xcd ~/deepstream_tao_apps/deepstream_app_tao_configs# Confirm the configuration and the input sourcegrep -E "uri=|config-file=|custom-lib-path|parse-bbox" run_transformer.txt# Confirm the dedicated Transformer model and the enginels -la /opt/nvidia/deepstream/deepstream-9.1/samples/models/tao_pretrained/peoplenet_transformer_vdeployable_v1.1/# Confirm the custom parserls -la ~/deepstream_tao_apps/post_processor/libnvds_infercustomparser_tao.sonm -D ~/deepstream_tao_apps/post_processor/libnvds_infercustomparser_tao.so | grep DDETR
Please operate in the graphical session of the Jetson desktop/VNC. Confirm that the input exists; the Transformer has a high computational load, so the offline frame rate may be lower than the frame rate of the material.
3. Starting the detection
Video mode:
xxxxxxxxxxcd ~export DISPLAY=:0export DISPLAY=:0 && ~/deepstream_tao_demo/run_case.sh transformer video

The entry point uses the sample_720p.h264 that comes with DeepStream, and the window shows the detection results related to people. The current configuration by default only previews or outputs to the internal sink.
To replace the test video: modify the uri=file:// of the [source0] section in run_transformer.txt to the absolute path of an MP4/H.264 file on the Jetson itself. First use gst-discoverer-1.0 to confirm that the device can decode it, and keep the original material.
4. Real-time detection with a USB camera
After confirming that the USB camera device node exists, run:
xxxxxxxxxxls -l /dev/video*v4l2-ctl -d /dev/video0 --list-formats-extexport DISPLAY=:0 && ~/deepstream_tao_demo/run_case.sh transformer usb

The script automatically detects the USB camera node and the supported resolution/frame rate.
The USB mode is used for the real-time preview. The script preferentially generates a temporary 640x480@15 configuration that the camera supports; the frame only shows Person + Tracker ID and does not show face/bag.
5. Real-time detection with a CSI camera
The CSI mode supports the real-time preview, and the entry point captures through Argus.
Start:
xxxxxxxxxxexport DISPLAY=:0 && ~/deepstream_tao_demo/run_case.sh transformer csi

USB/CSI is a continuous stream and does not naturally play to the end. The frame only shows person and the Tracker ID. To stop it, press Ctrl+C once in the terminal where it was started, wait for the application and the camera to be released, and only then start another camera task.
6. Common issues
| Symptom | Check and handling |
|---|---|
| No window is shown | Check the graphical session of the Jetson, the input file and the display authorization. |
| The class/the result is abnormal | Check the dedicated Transformer engine, the parser and the labels; do not use the CNN PeopleNet assets. |
It reports that NvDsInferParseCustomDDETRTAO cannot be found | Confirm that the function is in ~/deepstream_tao_apps/post_processor/libnvds_infercustomparser_tao.so: nm -D ... \| grep DDETR. |
Failed to load config file | Check the config-file= path in run_transformer_csi.txt (the trap of the path missing the configs/ prefix was hit before). |
| The processing frame rate is low | The Transformer load is relatively large; it was measured at about 20 FPS on an Orin NX. |
ONNX file does not exist | Check that the ONNX path referenced by the config-file is valid; the resnet50_peoplenet_transformer_op17.onnx under the peoplenet_transformer_vdeployable_v1.1 directory comes with DS 9.1. |
| No picture with USB/CSI | Check the device node, the format, the permissions and the occupancy; the CSI entry point directly uses the Argus type=5. |
nvv4l2h264enc has no property named 'gpu-id' | It is a known non-blocking warning of DS 9.1 and does not affect the inference or the display. |
7. References
NVIDIA DeepStream TAO application examples: https://github.com/NVIDIA/DeepStream/tree/main/src/apps/tao_apps
DeepStream TAO integration documentation: https://docs.nvidia.com/metropolis/deepstream/dev-guide/text/DS_TAO_integration.html