!48554 solve the st case error

Merge pull request !48554 from zong_shuai/gathernd_debug
This commit is contained in:
i-robot 2023-02-08 07:49:30 +00:00 committed by Gitee
commit 14dbfec344
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 3 additions and 3 deletions

View File

@ -164,10 +164,10 @@ def gathernd2(nptype):
[3., 7., 2., 7., 4.],
[4., 2., 8., 2., 9.]]).astype(np.float16))
indices = Tensor(np.array([[4000], [1], [300000]]).astype(np.int32))
expect = np.array([[0., 0., 0., 0., 0.],
indices = Tensor(np.array([[0], [1], [3]]).astype(np.int32))
expect = np.array([[4., 5., 4., 1., 5.],
[4., 9., 5., 6., 4.],
[0., 0., 0., 0., 0.]])
[0., 4., 2., 2., 8.]])
context.set_context(mode=context.GRAPH_MODE, device_target="GPU")
gathernd = GatherNdNet()