Conversation
…endency Co-authored-by: lmangani <1423657+lmangani@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix ImportError at output stage due to missing TorchCodec
Fix output stage crash: replace torchaudio.load with ffmpeg+wave to avoid torchcodec
Mar 14, 2026
…e MP3/WAV via shutil Co-authored-by: lmangani <1423657+lmangani@users.noreply.github.com>
Copilot
AI
changed the title
Fix output stage crash: replace torchaudio.load with ffmpeg+wave to avoid torchcodec
AcestepCPPGenerate: eliminate all audio decoding on output — copy native MP3/WAV directly
Mar 14, 2026
Co-authored-by: lmangani <1423657+lmangani@users.noreply.github.com>
Copilot
AI
changed the title
AcestepCPPGenerate: eliminate all audio decoding on output — copy native MP3/WAV directly
Remove all Python audio I/O — pass native MP3/WAV files directly to acestep.cpp
Mar 14, 2026
…o decoding Co-authored-by: lmangani <1423657+lmangani@users.noreply.github.com>
Copilot
AI
changed the title
Remove all Python audio I/O — pass native MP3/WAV files directly to acestep.cpp
Remove Python audio I/O — pass native WAV/MP3 directly to/from acestep.cpp
Mar 14, 2026
Copilot AI
added a commit
that referenced
this pull request
Mar 14, 2026
…eAudio nodes work PR #14 set RETURN_TYPES=() on AcestepCPPGenerate, removing the audio output slot entirely. Any workflow with a PreviewAudio node connected to slot 0 failed with "tuple index out of range" because RETURN_TYPES[0] did not exist. - nodes.py: RETURN_TYPES=("AUDIO",) + RETURN_NAMES=("audio",); lazy- import torchaudio inside generate() after writing the output file so the waveform is returned as {"result": (audio,), "ui": {...}}, giving both an inline player on the node and a proper AUDIO connection for downstream PreviewAudio / SaveAudio nodes. - tests/test_nodes.py: update RETURN_TYPES assertions to ("AUDIO",); fix TestNoPythonAudioProcessing import scan to flag only true module- level (non-indented) imports; replace test_generate_return_types_empty with test_generate_has_audio_output. - tests/test_workflows.py: replace tests that asserted no PreviewAudio / no output links with tests that assert PreviewAudio IS present and the AUDIO output IS connected. - workflow-examples/*.json: add a PreviewAudio node wired to the AUDIO output of AcestepCPPGenerate in all four example workflows. Co-authored-by: lmangani <1423657+lmangani@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The node was unnecessarily converting audio through Python tensor pipelines on both input and output.
acestep.cppreads and writes WAV/MP3 natively, so all Python audio decoding/encoding is dead weight.Input (
src_audio)src_audio_input(AUDIOconnection) and thetorchaudio.save()conversion block that serialised a ComfyUI tensor back to WAV for the binary to re-readimport torchaudiosrc_audioSTRING widget remains — users provide a file path; the binary reads it as-isOutput
AcestepCPPGenerateis a terminalOUTPUT_NODE(RETURN_TYPES = ()) — the binary's native MP3/WAV is copied to ComfyUI's output directory viashutil.copy2and{"ui": {"audio": [...]}}is returned so ComfyUI renders an inline player on the nodeWorkflows
src_audio_inputslot from all four workflow JSONsLoadAudionode andAUDIOlink from cover and reference-audio workflowsTests
TestNoPythonAudioProcessingclass that scansnodes.pyfor top-level imports oftorchaudio,torch,wave,numpy,soundfile,pyduband fails if any are foundsrc_audio_inputis absent fromINPUT_TYPESandRETURN_TYPES == ()💬 Send tasks to Copilot coding agent from Slack and Teams to turn conversations into code. Copilot posts an update in your thread when it's finished.