-
Notifications
You must be signed in to change notification settings - Fork 158
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
Bug in wave normalization. #49
Comments
Thank you for the detailed report! This is a great catch, and it's striking that the code works regardless. I'll push the fix shortly. |
Just a quick question, was the model trained on audio normalized the old / incorrect way? I am using a PyTorch port of this repo with your weights, and am wondering whether I should change or update the normalization code? Or if the model requires re-training with the fixed normalization? |
The pre-processing code I used for training is different from this, which did not have the normalization bug in this issue. So it shouldn't require retraining and you can use the same pre-trained model, unless you want to fine-tune the model with some other dataset. |
@jongwook will you be releasing an updated pip package with this fix? |
Yes :) @jongwook let me know if you're slammed right now and I can make a release. Cheers! |
@adarob @justinsalamon Thanks for the heads up! Just pushed v0.0.11 :) Btw you can use:
in
for a specific commit. |
@angusturner |
Hi, thank you for sharing this awesome work.
I've encountered this code below, and I dont' think this is correct.
This code is meant to normalize wave by each frame, but numpy's as_strided function does not allocate new memory, but does just create a new view of the array. (for example, the memory of first frame and the memory of second frame is not separated.)
See numpy documentation for more details.
So when do "in-place" calculation on that array, unintented result may raise. Here is an example.
Since frame is normalized, its sum should be about zero. but it's not.
To avoid this behavior, target array should be copied or something, to do operation correctly as intended. here is an example. only one line is changed. (.copy())
The text was updated successfully, but these errors were encountered: