Skip to content

echo: live playback stutters with --mode robot (upstream SDK bug) #67

Description

@rickstaa

echo --mode robot publishes a video and an audio track together. On the live path (- in, - out, piped to a player) the picture freezes for a moment roughly every 2 seconds while the audio stays continuous. The same clip recorded to a file is complete and in sync, so this only affects live playback.

The cause is in the SDK, not in this repo: livepeer/livepeer-python-gateway#60.

Frames leave the client's write_frame smoothly (0.061 - 0.081 s gaps, never blocking) and arrive at the runner in 0.354 - 0.541 s bursts; video only, through the identical path, stays at 0.046 - 0.071 s. The runner adds nothing of its own. Nothing in echo/ participates in that span.

Seven mitigations were tried here and upstream, and none changed the result: keyframe_interval_s at 0.5 / 0.25 / 10.0, video queue_size at 32 and 64 (this just moves the loss onto audio), moving the transform off the event loop with asyncio.to_thread, a shared idle-wait budget across tracks, and timestamp-ordered track selection.

Until it is fixed upstream

echo/README.md documents recording to a file and playing it back, which is unaffected. The live variant is mentioned there too and should be treated as the lossy option when audio is involved.

Nothing to do in this repo beyond closing this issue when #60 lands and re-checking the live path.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions