未验证 提交 64b46122 编写于 作者: L littletomatodonkey 提交者: GitHub

Fix softmax unittest (#25371)

* test=develop, fix softmax
上级 2989c012
...@@ -47,6 +47,7 @@ class TestSoftmaxOp(OpTest): ...@@ -47,6 +47,7 @@ class TestSoftmaxOp(OpTest):
self.shape = self.get_x_shape() self.shape = self.get_x_shape()
self.axis = self.get_axis() self.axis = self.get_axis()
np.random.seed(0)
x = np.random.uniform(0.1, 1, self.shape).astype(self.dtype) x = np.random.uniform(0.1, 1, self.shape).astype(self.dtype)
out = np.apply_along_axis(stable_softmax, self.axis, x) out = np.apply_along_axis(stable_softmax, self.axis, x)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册