221 Star 941 Fork 693

GVPMindSpore/mindscience

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
sponge.function.keepdims_mean.rst 763 Bytes
一键复制 编辑 原始数据 按行查看 历史
俞涵 提交于 2023-12-25 14:23 +08:00 . modify sponge docs format

sponge.function.keepdims_mean

.. py:function:: sponge.function.keepdims_mean(x: Tensor, axis: Union[int, Tuple[int], List[int]] = ())

    对轴中从维度为 `x` 减小到维度为 1 的元素求平均值,并且输出和输入的维度相同。

    参数:
        - **x** (Tensor[Number]) - 输入张量。要约简的张量的 dtype 是 number。
          :math:`(N,*)` 其中的 :math:`*` 代表任意数量的附加维度,其维度应小于 8。
        - **axis** (Union[int, tuple(int), list(int)]) - 要减小的维度。默认值:(),减小所有维度。
          只允许常量值。必须在范围 [-rank(`x`), rank(`x`))。

    输出:
        Tensor。和 `x` 有相同的dtype。
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/mindspore/mindscience.git
git@gitee.com:mindspore/mindscience.git
mindspore
mindscience
mindscience
master

搜索帮助