Cell #20. Can't compile the student's code. Error: AssertionError('Wrong values in out')

Hello everyone! I am working on the last assignment for the specialization. For DecoderLayer, Decoder and Transformer i get the “AssertionError: Wrong values in outd”.

{mentor edit: code removed}

I have revised all of the functions and everything and I have no idea why they are not working. Any suggestions?

Thanks,
Dima

This issue has been resolved.
The problem was missing the sum in layernorm2().

I am still facing this issue in exercise 7. I am not missing the sum in layernorm2() in the previous exercise.

Perhaps your code has a different error.