Skip to content

fix(transcode): wire GPU H264/H265 encoders into the live path too#27

Open
Pon-node wants to merge 1 commit into
livepeer:rs/av1-transcodefrom
Pon-node:fix/live-path-gpu-encoders
Open

fix(transcode): wire GPU H264/H265 encoders into the live path too#27
Pon-node wants to merge 1 commit into
livepeer:rs/av1-transcodefrom
Pon-node:fix/live-path-gpu-encoders

Conversation

@Pon-node

@Pon-node Pon-node commented Jul 9, 2026

Copy link
Copy Markdown

Summary

Follow-up to #25. _handle_batch passes h264_encoder/h265_encoder through to profiles.normalize(), but _handle_live never did — live/trickle sessions always fall back to the CPU defaults (libx264/libx265) regardless of --h264-encoder/--h265-encoder, even on a fully GPU-configured runner.

Found running in production: with TRANSCODE_H264_ENCODER=h264_nvenc set, 19 concurrent live sessions were silently encoding on CPU the whole time. nvidia-smi showed a single ffmpeg process (an unrelated batch job) using the GPU — all the live sessions' encode work was invisible to it because it was never touching the GPU at all.

Test plan

  • Confirmed the gap: _handle_live's prof.normalize() call only ever passed av1_encoder
  • Confirmed via nvidia-smi that concurrent live sessions showed zero GPU utilization/process presence despite GPU encoders being configured
  • Applied the same fix locally and verified _handle_live now passes all three encoder overrides, matching the batch path

🤖 Generated with Claude Code

_handle_batch (fixed in livepeer#25) passes h264_encoder/h265_encoder through to
profiles.normalize(), but _handle_live never did — live sessions always
fall back to the CPU defaults (libx264/libx265) regardless of
--h264-encoder/--h265-encoder, even on a GPU-configured runner.

Found running in production: with TRANSCODE_H264_ENCODER=h264_nvenc set,
19 concurrent live sessions were silently encoding on CPU. nvidia-smi
showed a single ffmpeg process (an unrelated batch job) using the GPU,
while all the live sessions' encode work was invisible to it.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant