Skip to content
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

MIOpenBatchNormBwdPerAct.cl kernel bug #104

Closed
joye opened this issue May 28, 2019 · 5 comments
Closed

MIOpenBatchNormBwdPerAct.cl kernel bug #104

joye opened this issue May 28, 2019 · 5 comments
Assignees

Comments

@joye
Copy link

joye commented May 28, 2019

in https://github.com/ROCmSoftwarePlatform/MIOpen/blob/master/src/kernels/MIOpenBatchNormBwdPerAct.cl#L174

the tmp2's calculation is wrong, which should be

dyelem = (_FLOAT_PREC)(dy_in[index]);
tmp2 = mad((_FLOAT_PREC)N, dyelem * pvt_scale, -tmp1);

please check the formula of this derivative.

After this change, the result can match with cuDNN result for the same input.

@ce1adon
Copy link
Contributor

ce1adon commented May 29, 2019

@joye @atamazov
Thank you Mei! You are right. This calculation is wrong.

Based on this information the calculation at
https://github.com/ROCmSoftwarePlatform/MIOpen/blob/master/src/kernels/MIOpenBatchNormBwdPerAct.cl#L265
also need to be corrected.

Considering we don't have error report in ctest or driver, I think the verification in ctest and driver also need to be changed. Can you setup a priority level?

@ce1adon
Copy link
Contributor

ce1adon commented May 29, 2019

I think instead of doing a patch here, maybe put it in the next release. What do you think? @atamazov

@atamazov
Copy link
Contributor

Yes, let's fix during normal development process. Anyone who needs the fix ASAP can ask us explicitly (right here) for the patch.

@daniellowell
Copy link
Contributor

I’ll fix it for the next release.

@daniellowell
Copy link
Contributor

Fixed in MIOpen 2.0.0

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

No branches or pull requests

4 participants