-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
resample fails on axis >1 #73
Comments
Thanks for noting this. I'll try to make some time to look into it later in the week, but for now I'll confirm that i see the same behavior as your example. You're almost certainly correct that this is due to the reshaping hackery we do to keep the resampling output arrays memory-contiguous and easy to compute. I don't see an obvious reason why this shouldn't work though. |
Finally circling back on this - it's amazing how many issues / PRs were abandoned in early 2020. I'm still not sure why this is happening, and suspect it may be a strange interaction with numba. FWIW we use similar shape manipulation logic in librosa (without numba) all the time and have no problems like this. |
Ok, I've tracked this one down, but I'm not sure how to resolve it. Based on the notes in the This 2d-reshape business was all to get around limitations of numba array indexing. However, I just tried it out and it seems that this is no longer necessary. I'll have to work out exactly what version of numba made this possible, but I think we should be able to sort this out and simplify things a bit. |
Thanks! I had ended up forgetting about this too, but it's cool to see things come full circle! |
Fix should go out in the 0.3 release, hopefully some time next week. |
resampy version: 0.2.1
Python: 3.7.3
numpy version: 1.16.2
Windows 10
resampy.resample
returns array of zeros of appropriate size whenaxis
parameter is greater than 1 (tested foraxis=2
andaxis=3
). See minimal working example below:Believe it's due to the lines:
I can look into submitting a PR if it's simple and desirable?
The text was updated successfully, but these errors were encountered: