Nodes/comfyui-OreX/🔉 Audio Load V2 (OreX)
ComfyUI Node

🔉 Audio Load V2 (OreX)

Core ComfyUI's Audio Loader Can't Trim. This One Draws the Waveform.

By orex2121·Created about a year ago·Updated a day ago· 44
🔉 Audio Load V2 (OreX)
    • audio
    • duration_sec
    • file_path
    audio
    start_time0.00
    end_time0.00
    normalize_audio-18.0

    Core ComfyUI's LoadAudio hands you a file and calls it a day: no trim, no level, so "I just need the first twelve seconds of this track" becomes a trip to Audacity and a re-import. Audio Load V2 (OreX) is that trip, moved into the node. You get a waveform drawn on the node, drag in/out points, and on run the AUDIO that comes out is already cut to length and loudness-normalized to a target you set in LUFS.

    That's the whole value proposition, and in a stack where audio is still the bolted-on layer - good models, integration that's a maintained workaround - cutting and levelling clips inside the graph is worth having.

    What it's actually doing

    The node resolves your path, decodes the file through a fallback chain, slices the waveform at the sample level, optionally measures integrated loudness with pyloudnorm and applies gain to hit your target, then hands back the standard ComfyUI audio object: a waveform tensor plus sample_rate. Because it's the standard shape, it wires into anything that takes AUDIO - this pack's own Advanced Video Load (new_audio) and Video Preview (audio), plus foley nodes, SaveAudio, LTX's audio-VAE encode.

    Two things it does not touch: sample rate and channel count. It normalizes loudness, not format. If a downstream model wants 16 kHz mono, that's a different node's job.

    The inputs that matter

    • audio - a path string, not a dropdown. Either an absolute path on disk or a filename inside ComfyUI/input/; stray quotes are stripped, so a pasted Windows path works. The node's upload button posts large files to the pack's shared /orex/upload_chunk route, which is registered by OreX_AudioLoad.py - the pack's other audio module. Delete that file and the upload button in both nodes stops working.
    • start_time / end_time - seconds. end_time = 0 means "to the end of the file", which is a reasonable default and an easy misread. There's no HH:MM:SS field and no frame maths; it's seconds, with a waveform you can drag on instead of typing.
    • normalize_audio - target LUFS, default -18, tooltip "Target LUFS". Values below 0 switch normalization on; 0 switches it off. -18 is deliberately conservative (narration/broadcast-ish). If you're riding for music-streaming loudness, push it up toward -14.
    • Outputs: audio, duration_sec (rounded to two decimals - feed it into String Function to log or name things), and file_path, the resolved absolute path actually opened. That last one is quietly useful because audio may be relative and you'd otherwise be guessing which file the run touched.

    Installing it

    ComfyUI Manager, search comfyui-OreX (the registry name is Orex Nodes), or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/orex2121/comfyui-OreX
    

    Restart. requirements.txt pulls Pillow, soundfile, pydub, pyloudnorm and modelscope - pydub is the first decoder in the chain and it needs ffmpeg on PATH for mp3/m4a/opus; wav and flac usually survive via soundfile.

    One housekeeping note the author puts as the very first line of the README: delete the pack from custom_nodes and install it again. In-place overwriting isn't reliable here, and the pack ships a lot of custom JavaScript (~100 KB for this node alone), so hard-refresh the browser after any update or you'll be looking at last week's node.

    Where it goes wrong

    "Could not read media file" with three stacked errors. That's the fallback chain reporting in. Almost always ffmpeg: pydub needs it, soundfile can't read your codec, and torchaudio's backend is whatever your install happens to have. Install ffmpeg before debugging anything else.

    A full-length clip came out when you wanted a section. If end_time ends up at or before start_time, the node quietly falls back to the whole file instead of erroring. Check your numbers before blaming the node - it's a graceful-failure choice, not a bug, but it fails quietly.

    Normalization just doesn't happen. pyloudnorm is optional at runtime. If the import fails you get a console warning and unnormalized audio - not an exception. If your levels look untouched, read the console.

    The waveform or trim handles don't render. This is a heavy custom-UI node, which is exactly the category that breaks when ComfyUI changes its frontend (the Nodes 2.0 rewrite did this to rgthree's Power Lora Loader and friends). Hard-refresh first; if it still renders empty, it's upstream, not your install.

    A missing file is caught early. VALIDATE_INPUTS rejects a bad path with Invalid audio file path before the queue runs, so a red node means the path, not the run.

    Small print worth knowing: the marker presets you save on the node live in OreX_AudioLoad_v2.json next to the module and are stored server-side by name, so they travel with your install rather than with the workflow. And the node's download button exports an MP3 using a plain dBFS gain - a quick reference clip, not the same LUFS math the audio output uses.

    CategoryOreX/Audio

    Inputs (4)

    NameTypeDefaultDescription
    audioSTRING
    start_timeFLOAT0.000–100000
    end_timeFLOAT0.000–100000
    normalize_audioFLOAT-18.0-100–0Target LUFS

    Outputs (3)

    NameTypeDescription
    audioAUDIO
    duration_secFLOAT
    file_pathSTRING