ComfyUI Node

Load AudioX Video

Load AudioX Video turns your clip into the video condition — and it wants a real path

By Yuan-ManX·Created about a year ago·Updated about a year ago· 12
Load AudioX Video
  • target_fps
  • video_tensor
video_pathexample/V2M_sample-1.mp4
duration10

This is the node most people are actually here for. AudioX's whole selling point is that it can take a silent video and produce sound that plausibly matches what's on screen - rain for the rainy scene, footsteps for the corridor, an engine for the car. LoadAudioXVideo is the front door for that: it reads your clip with decord, downsizes every frame to 224×224, samples frames down to your target fps, and hands the result to Condition as a TENSOR.

The pipeline the pack builds around this is a textbook foley setup. You have a Wan or Hunyuan video with no audio, you load it here, you write a sound-designer prompt in AudioXPrompt, you run ConditionGenerateSaveAudioXAudio, and you mux the WAV back onto the video with ffmpeg. In the community this is the canonical use for AudioX - people slotting it in right after their video generator to add SFX. The honest caveat: the video-to-audio crowd is split between AudioX and MMAudio, and neither is magic. Some users report results that are clearly useful; others call the same models "completely useless." Treat the first run as a quality check, not a verdict.

Inputs

  • video_path (STRING, default "example/V2M_sample-1.mp4") - this default will not exist on your machine. The pack ships no example video; you must give an absolute path to a real file, or the node errors on VideoReader. The default is a leftover from the upstream repo's demo.
  • duration (INT, default 10) - seconds of video to read. The node pads or truncates to exactly duration × target_fps frames, so a short clip gets its last frame repeated rather than failing.
  • target_fps (FPS) - the frame rate to sample at. Wire this from LoadAudioXModel's target_fps output (5 fps for the stock AudioX checkpoint).

Nice bonus buried in the code: if the path points at a .jpg or .png instead of a video, the node reads it as a still image and repeats it for the full duration. That gives you a cheap "image → sound" mode without any extra node.

How the mechanism works

Internally it's a decord VideoReader that picks frame indices at a stride of roughly video_fps / target_fps, converts them to a [frames, 3, 224, 224] tensor, and ensures the count matches duration × target_fps. That tensor is then squeezed through the model's CLIP-based video conditioner, so what the model actually sees is a small, uniform grid of frames - resolution doesn't carry over. A 4K clip and a 720p clip end up identical after this node, which is by design, not a bug.

Installing AudioX

Install via ComfyUI Manager (search "ComfyUI-AudioX") or cd ComfyUI/custom_nodes && git clone https://github.com/Yuan-ManX/ComfyUI-AudioX.git, then pip install -r requirements.txt and conda install -c conda-forge ffmpeg libsndfile, then restart. The requirements are heavy (pinned pandas==2.0.2, descript-audio-codec, laion-clap, wandb) - a managed ComfyUI install may want its own venv. The checkpoint auto-downloads on first LoadAudioXModel run.

Gotchas

Besides the dead default path, two things. First, decord and its video decoding depend on your ffmpeg install - the pack's README tells you to conda install -c conda-forge ffmpeg libsndfile, and if you skip that, video reads can throw cryptic errors. Second, because Condition requires text and audio inputs too, this node alone won't do anything - you must complete the chain. And remember the ~11-second ceiling baked into the model (485100 samples at 44.1 kHz): for longer videos, chunk them and generate per segment, or you'll just be repeating frames for nothing.

CategoryAudioX

Inputs (3)

NameTypeDefaultDescription
video_pathSTRINGexample/V2M_sample-1.mp4
durationINT10
target_fpsFPS

Outputs (1)

NameTypeDescription
video_tensorTENSOR