Repository navigation
audioconv64: add VADPCM beam-search refinement - #14
Open
Boxingbruin wants to merge 6 commits into
Open
Boxingbruin wants to merge 6 commits into
Boxingbruin wants to merge 6 commits into
Conversation
Contributor
|
Why is the |
Author
Yep no problem, I can change that, I honestly just didn't know which licence to choose and chose the same one VADPCM runs under. Though I think Depp is going to merge beam search upstream into VADPCM anyways. |
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.
Improves VADPCM encoding quality by searching alternative predictor, scale, and residual choices.
Tradeoff: This method greatly increased audio compression times.
audioconv64 changes:
I believe the tradeoffs are worth it for 2bit VADPCM specifically, it reduces enough static to make it a viable choice which unlocks a lower level of compression. Not something to be done on every clean build, but something to enable for a cartridge release to save even more space. Currently to my ears, 2 bit VADPCM is not a viable choice, it contains too much static to use, this method unlocks it.
I have test results, a quality score was determined by a locally run model and noise/artifact detection that I tuned to my ear. It is not 100% accurate but pretty damn close.
Playback cost and ram usage remain the same.
You can also visually see the error rate reduction in the spectrogram:

Algorithm reference: https://en.wikipedia.org/wiki/Beam_search
AI Disclaimer: I used AI to help me learn VADPCM inside and out first to ensure I knew what I was doing going into this. I also had it help me write the beam search algorithm into c and interface it with VADPCM's codebook. I did writethe code by hand, only using it for assistance to make sure it was done correctly. I also used a locally run model trained on audio clip similarity and tuned it along with noise detection algorithms to match my ear as closely as I could for the quality rating.