mindspore-ai / mindspore

MindSpore is a new open source deep learning training/inference framework that could be used for mobile, edge and cloud scenarios.
https://gitee.com/mindspore/mindspore
Apache License 2.0
4.24k stars 700 forks source link

Why the mathematical derivation of GRU is different from the wiki #149

Open rsgok opened 3 years ago

rsgok commented 3 years ago

math on wiki:

However, mindspore math:inference

image

Ignoring the slight difference of the first three equations, at least the last one should be: h{t+1} = (1-z{t+1}) ht + z{t+1} n_{t+1}

BTW, I am quite confused about the relevant Implement code, is DynamicGRUV2 the detailed implement code?

yuuuky commented 3 years ago

Our formula is consistent with pytorch.