HaveAGitGat / Tdarr

Tdarr - Distributed transcode automation using FFmpeg/HandBrake + Audio/Video library analytics + video health checking (Windows, macOS, Linux & Docker)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Can't max out CPU

whytf opened this issue · comments

Hey,

I don't have a gpu that i can use for a big transcoding task like this is aimed to do but i got a dual socket xeon, 48 threads in total that i can't seem to max out, just about 10% with one file being transcoded, in the report of a "transcode cpu" the log looks like this and it is stuck at the last line running cli:

2024-05-12T00:09:45.984Z y1Bxmnd0H:Node[minor-myna]:Worker[oblong-owl]:[Step W05] [C1] Launching subworker
2024-05-12T00:09:45.985Z y1Bxmnd0H:Node[minor-myna]:Worker[oblong-owl]:Preparing to launch subworker
2024-05-12T00:09:45.986Z y1Bxmnd0H:Node[minor-myna]:Worker[oblong-owl]:Subworker launched
2024-05-12T00:09:45.986Z y1Bxmnd0H:Node[minor-myna]:Worker[oblong-owl]:[1/3] Sending command to subworker
2024-05-12T00:09:45.987Z y1Bxmnd0H:Node[minor-myna]:Worker[oblong-owl]:[2/3] /root/tdarr/Tdarr_Node/node_modules/ffmpeg-static/ffmpeg -i "xxxx" -map 0 -c:v libx265 -b:v 788k -minrate 551k -maxrate 1024k -bufsize 1577k -c:a copy -c:s copy -max_muxing_queue_size 9999 "xxxx"
2024-05-12T00:09:45.988Z y1Bxmnd0H:Node[minor-myna]:Worker[oblong-owl]:[3/3] Command sent
2024-05-12T00:09:45.989Z y1Bxmnd0H:Node[minor-myna]:Worker[oblong-owl]:To see live CLI output, enable 'Log full FFmpeg/HandBrake output' in the staging section on the Tdarr tab before the job starts. Note this could increase the job report size substantially.
2024-05-12T00:09:45.998Z y1Bxmnd0H:Node[minor-myna]:Worker[oblong-owl]:Subworker:Online
2024-05-12T00:09:46.000Z y1Bxmnd0H:Node[minor-myna]:Worker[oblong-owl]:Subworker:Receiving transcode settings
2024-05-12T00:09:46.002Z y1Bxmnd0H:Node[minor-myna]:Worker[oblong-owl]:Subworker:Running CLI

I am using the default decision maker, handbrake-cli just had to be configured directly into the config, rest of the configuration was done via webui.

Screenshots
image
image
image

  • OS: Ubuntu 22.04 VM, running as 24 cores, 2 sockets with numa enabled
  • Version 2.17.01

Wondering if i should just crank it up to transcode 10 tasks at once or if there's a way to use all core for a single file so it completes sequentially faster?

There's a -threads argument that can be used but leaving it out or setting it to -threads 0 is meant to be the optimal solution.

https://superuser.com/questions/155305/how-many-threads-does-ffmpeg-use-by-default

So in this case it seems FFmpeg is not optimized for that CPU so best to run multiple workers.

There's a -threads argument that can be used but leaving it out or setting it to -threads 0 is meant to be the optimal solution.

https://superuser.com/questions/155305/how-many-threads-does-ffmpeg-use-by-default

So in this case it seems FFmpeg is not optimized for that CPU so best to run multiple workers.

How can i edit the transcoding task to add that parameter?

@whytf on the classic plugins tab you'd need to copy the plugin locally:

image

Then edit it:

image

image

The save and add the local plugin to your stack.