Repository navigation
Make spectral rolloff return bound values - #318
Closed
Polochon-street wants to merge 1 commit into
Closed
Polochon-street wants to merge 1 commit into
Polochon-street wants to merge 1 commit into
Conversation
Contributor
Author
|
Build seems to fail because of missing public keys? |
Polochon-street
force-pushed
the
fix-order-rolloff
branch
from
November 18, 2020 17:19
1f61fcc to
6eb5347
Compare
Polochon-street
force-pushed
the
fix-order-rolloff
branch
from
November 18, 2020 17:20
6eb5347 to
88c6a5a
Compare
Contributor
Author
|
@rec yep, tried to rebuild it today - failed. I guess we just need to wait til the key is updated 😄 |
Closed
Copilot AI
added a commit
to LedFx/aubio-ledfx
that referenced
this pull request
Nov 13, 2025
Co-authored-by: shauneccles <21007065+shauneccles@users.noreply.github.com>
piem
added a commit
that referenced
this pull request
Nov 16, 2025
…hon-street) We now return at least the first bin, and at most the last bin number, to prevent returning a value greater than the length of the norm vector size.
Member
|
hey @Polochon-street thank you for that. I adopted a slightly different approach just for clarity. I also added unit tests to check the behavior is correct for both edge cases. cheers, piem |
8000
Contributor
Author
|
no worries, glad that it's fixed! Cheers. |
piem
added a commit
that referenced
this pull request
Nov 16, 2025
…hon-street) We now return at least the first bin, and at most the last bin number, to prevent returning a value greater than the length of the norm vector size.
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.
Hi,
The current code returns an out of bound bin (length + 1) if everything is contained in the last bin. This returns instead the last bin.
Not really sure where to test that, but here's a small excerpt that shows it working:
It returns
4(the right value), and if you instead useyou can see it returns 5, one too much.
We could also do it the other way, where you go through the norm array and then break whenever you reach 95% of the energy, but I didn't want to change stuff too much :)