Rockchip · AI & Linux Hub

AI inference

Finding starvation in a two-stream RKNN application on RK3588

When two cameras share a Rockchip NPU, only looking at the total FPS will cover up the situation that one camera cannot be scheduled for a long time.

Baseline with two fixed videos and the same target frame rate before considering concurrency context or core allocation. The value of the core settings depends on the current runtime library and chip support range.

Separate accounting

Save the number of inputs, the number of frames actually entering inference, the number of completions, queue waiting and end-to-end delay for each path. If channel A continuously achieves 25 FPS and channel B only achieves 5 FPS, the total of 30 FPS may still meet the original dashboard target, but it cannot meet the business constraints of 15 FPS for each channel.

Exclude input deviation

Swap the input sources of the two videos, and let each channel run once. If you always follow the video, you should first look at the resolution, decoding and number of targets. If the slowness always follows the channel number, then look at the task distribution, lock granularity and result aggregation method.

Let acceptance protect each road

Record the worst performance of one channel when two channels are started at the same time, one channel is disconnected and reconnected, and one channel suddenly encounters a complex picture. After agreeing on the minimum completion rate and upper limit of delay for each channel, the total throughput is used to compare different scheduling solutions.

Board documentation and references

ArmSoM Sige7

Products and development resources

Check the hardware revision, carrier, image and interfaces in the product documentation. An article association is not evidence that a configuration has been tested.

Explore this topic → · Learning paths →