未验证 提交 fe94db6c 编写于 作者: Z zhiboniu 提交者: GitHub

Fix LayerNorm Problem (#33420)

* Eliminate numerical differences of LayerNorm; fix LayerNorm Nan Bug while large data input

* fix bug while large shape of data input
上级 24bde98f
此差异已折叠。
......@@ -51,6 +51,7 @@ class TestDygraphLayerNormv2(unittest.TestCase):
self.assertTrue(np.allclose(y1, y2))
def test_static(self):
paddle.enable_static()
places = [fluid.CPUPlace()]
if core.is_compiled_with_cuda() and core.op_support_gpu("layer_norm"):
places.append(fluid.CUDAPlace(0))
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册