You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm not too familiar with the details of video processing, but I'd like to share some performance observations from my practice.
CPU Usage for Decoding
My test involves pulling a single original video stream, doing some intermediate processing (consuming about 50% of CPU), then re-encoding and pushing it to an RTMP server(about 12% of CPU, using GPU encoding). I then watch the final processed live stream.
Here's my setup:
CPU: Intel Xeon Gold 5118 2.30GHz x8
GPU: Nvidia Tesla V100 32GB
Origin Video: 1080p 24fps, 4Mbps h264-baseline
The CPU usage below are not exact measurements, they are merely my intuitive perception from observing htop.
Decoding Scenario
Min
Avg
Max
Single stream with CPU
18%
22%
30%
Single stream with GPU
20%
23%
25%
When it comes to 6-stream parallel decoding:
With GPU: CPU usage stabilizes at nearly 100% across all 8 cores, and the resulting video stream is almost smooth.
With CPU: The total CPU usage fluctuates between 40% and 80%, but the video is more stuttered compared to using GPU.
In my case, I might opt for the GPU solution as it appears more stable, although it seems not so friendly to energy efficiency.
The text was updated successfully, but these errors were encountered:
Without SHM: About 25% CPU usage, encoding one frame takes 10~11ms
With SHM: CPU usage seems down to 23%, encoding one frame takes 9~10ms
I previously used a streaming library(WriteGear), which passed frame data to an FFmpeg process through a pipe, with FFmpeg handling GPU encoding.The py part had a CPU usage of about 12%, and ffmpeg is 30%.
So, it seems both py part and ffmpeg each take about 10% CPU usage for data delivery.
However, currently, due to the lack of full support for encoding parameters in ffio, the encoding quality is not ideal, which will be the focus in future.
koisi-io
changed the title
[Performance Insights] CPU vs. GPU
[Performance Insights] CPU vs. GPU also utilization of shm
Jan 26, 2024
I'm not too familiar with the details of video processing, but I'd like to share some performance observations from my practice.
CPU Usage for Decoding
My test involves pulling a single original video stream, doing some intermediate processing (consuming about 50% of CPU), then re-encoding and pushing it to an RTMP server(about 12% of CPU, using GPU encoding). I then watch the final processed live stream.
Here's my setup:
The CPU usage below are not exact measurements, they are merely my intuitive perception from observing
htop
.When it comes to 6-stream parallel decoding:
In my case, I might opt for the GPU solution as it appears more stable, although it seems not so friendly to energy efficiency.
The text was updated successfully, but these errors were encountered: