Browse Source

docs(mge/functional): fix functional.eye docstring

GitOrigin-RevId: 2645af5e35
release-1.10
Megvii Engine Team 3 years ago
parent
commit
8fcbe8258d
1 changed files with 2 additions and 1 deletions
  1. +2
    -1
      imperative/python/megengine/functional/tensor.py

+ 2
- 1
imperative/python/megengine/functional/tensor.py View File

@@ -92,7 +92,8 @@ def eye(N, M=None, *, dtype="float32", device: Optional[CompNode] = None) -> Ten
r"""Returns a 2D tensor with ones on the diagonal and zeros elsewhere.

Args:
shape: a list, tuple or integer defining the shape of the output tensor.
N: an integer defining the number of rows.
M: an integer defining the number of columns. If ``M`` is not specified, the number of columns is ``N``. Default: ``None``.
dtype: the desired data type of the output tensor. Default: ``float32``.
device: the desired device of the output tensor. Default: if ``None``,
use the default device (see :func:`~.megengine.get_default_device`).


Loading…
Cancel
Save