#349 add tensor.unfold, tensor.slogdet

Merged
zoulq merged 3 commits from frelam/MSAdapter:master into master 1 year ago
frelam commented 1 year ago
zoulq reviewed 1 year ago
@@ -29,0 +31,4 @@
# TODO: To use ms.ops.slogdet instead of numpy.linalg.slogdet
input = cast_to_ms_tensor(A)
A = input.asnumpy()
sign, output = np.linalg.slogdet(A)
zoulq commented 1 year ago
ms.ops.slogdet无法对标的原因是什么?
frelam commented 1 year ago
可以对标。 下午可能搜错分支的文档, 没搜到。
zoulq reviewed 1 year ago
@@ -2914,0 +2920,4 @@
indices.append(list(range(i, i + size)))
indices = ms.Tensor(indices)
output = ms.ops.gather(input, indices, axis=dimension)
output = ms.numpy.moveaxis(output, dimension + 1, -1)
zoulq commented 1 year ago
可以用ops.movedim或者ops.moveaxis代替吗?
frelam commented 1 year ago
可以, 我换一下。
zoulq merged commit 71fe967013 into master 1 year ago
The pull request has been merged as 71fe967013.
Sign in to join this conversation.
No reviewers
No Label
No Milestone
No Assignees
2 Participants
Notifications
Due Date

No due date set.

Dependencies

This pull request currently doesn't have any dependencies.

Loading…
There is no content yet.