High GPU memory consumption when decoding RTSP video stream

Hello. When working with ffmpeg(cuvid) and decoding on GPU, I encountered that the memory consumption is too high for a single video stream. During tests, I got about 200 megabytes per video stream with a resolution of 704 * 576.

Is this normal, or are there ways to optimize memory consumption?

What operations cause such a large expense?

I have attached screenshots. In the first case, I am decoding 10 video streams.

In the second case, 40 is decoded

GPU: 2080 RTX TI
Driver: 470.199.02
OS: Ubuntu 22.04.2


Alyo! Mne kto-nubud otvetit po dannomu voprosu?

Hi there @vnukelkina and welcome to the NVIDIA developer forums!

One important thing to know would be what format the streams themselves are. If you buffer around 120 frames of 32bit encoded video data you easily reach 200 MB. But since this is unlikely it would e nice to see what exactly the format is.

How does memory consumption look like for a single stream?