Skip to content

Add regression test for MusicgenMelody audio conditioning (GH #45647)#45737

Open
voodoovampire wants to merge 6 commits intohuggingface:mainfrom
voodoovampire:fix-musicgenmelody-audio-conditioning-45647
Open

Add regression test for MusicgenMelody audio conditioning (GH #45647)#45737
voodoovampire wants to merge 6 commits intohuggingface:mainfrom
voodoovampire:fix-musicgenmelody-audio-conditioning-45647

Conversation

@voodoovampire
Copy link
Copy Markdown

This PR adds a regression test for issue #45647.

Test behavior:

  • Creates two different 1-second sine reference audios (A4 at 440 Hz, Eb4 at 311.13 Hz).
  • Generates audio from each using AutoProcessor with text=["jazz"], same seed, same params.
  • Asserts that the generated outputs differ by at least 1e-3 in mean absolute difference.

Current status:
On facebook/musicgen-melody, this test fails with mean abs diff=0.00000000, confirming that audio conditioning is ignored.

Next step:
This test provides a reliable repro. The model fix is being coordinated with @adityachoksi2512, who has already bisected the regression to the cache refactor in PR #38635.

Closes #45647 (once the model fix is merged).

@adityachoksi2512
Copy link
Copy Markdown

Hey @voodoovampire - thanks for the co-author credit! Could you update the email in the co-authored-by line to adityachoksi2512@gmail.com? The current one is an old work email that won't link to my GitHub profile. Also looks like there's a duplicate entry with a slightly different username. Thanks!

@voodoovampire voodoovampire force-pushed the fix-musicgenmelody-audio-conditioning-45647 branch from 77d04d5 to 0be51a4 Compare May 1, 2026 17:14
@voodoovampire
Copy link
Copy Markdown
Author

Hey bro @adityachoksi2512 - absolutely! Just updated the co-authored-by email to adityachoksi2512@gmail.com. The duplicate was my mistake - I initially used the work email from your original commit metadata. Should be fixed now!
Thanks for being collaborative about this. Really appreciate it. 🙏

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 1, 2026

[For maintainers] Suggested jobs to run (before merge)

run-slow: musicgen_melody

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.

MusicgenMelody ignores audio conditioning (regression between 4.48 and 4.57)

2 participants