You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

mindspore.ops.Flatten.rst 540 B

12345678910111213141516171819
  1. mindspore.ops.Flatten
  2. ======================
  3. .. py:class:: mindspore.ops.Flatten
  4. 扁平化(Flatten)输入Tensor,不更改0轴上的batch size。
  5. **输入:**
  6. - **input_x** (Tensor) - 待扁平化的Tensor,其shape为 :math:`(N, \ldots)`, :math:`N` 表示batch size。
  7. **输出:**
  8. Tensor,输出shape为 :math:`(N, X)` 的Tensor,其中 :math:`X` 是余下维度的乘积。
  9. **异常:**
  10. - **TypeError** - `input_x` 不是Tensor。
  11. - **ValueError** - `input_x` 的shape长度小于1。