Size

Size - 25

版本

  • 名称: Size (GitHub)

  • : main

  • since_version: 25

  • 函数: False

  • 支持级别: SupportType.COMMON

  • 形状推断: True

此版本的操作符已在版本 25 及之后可用。

摘要

接受一个张量作为输入,并输出一个 int64 标量,其值等于输入张量的元素总数。

输入

  • data (异构) - T

    一个输入张量。

输出

  • 大小(异构) - T1

    输入张量的元素总数

类型约束

  • T 位于 ( tensor(bfloat16), tensor(bool), tensor(complex128), tensor(complex64), tensor(double), tensor(float), tensor(float16), tensor(float4e2m1), tensor(float8e4m3fn), tensor(float8e4m3fnuz), tensor(float8e5m2), tensor(float8e5m2fnuz), tensor(float8e8m0), tensor(int16), tensor(int2), tensor(int32), tensor(int4), tensor(int64), tensor(int8), tensor(string), tensor(uint16), tensor(uint2), tensor(uint32), tensor(uint4), tensor(uint64), tensor(uint8) )

    输入张量可以是任意类型。

  • T1 在 ( tensor(int64) )

    将输出约束为 int64 张量,尽管它应该是一个标量。

Size - 24

版本

  • 名称: Size (GitHub)

  • : main

  • 起始版本24

  • 函数: False

  • 支持级别: SupportType.COMMON

  • 形状推断: True

此版本的操作符已可用于版本 24 及以上

摘要

接受一个张量作为输入,并输出一个 int64 标量,其值等于输入张量的元素总数。

输入

  • data (异构) - T

    一个输入张量。

输出

  • 大小(异构) - T1

    输入张量的元素总数

类型约束

  • T 位于 ( tensor(bfloat16), tensor(bool), tensor(complex128), tensor(complex64), tensor(double), tensor(float), tensor(float16), tensor(float4e2m1), tensor(float8e4m3fn), tensor(float8e4m3fnuz), tensor(float8e5m2), tensor(float8e5m2fnuz), tensor(float8e8m0), tensor(int16), tensor(int32), tensor(int4), tensor(int64), tensor(int8), tensor(string), tensor(uint16), tensor(uint32), tensor(uint4), tensor(uint64), tensor(uint8) )

    输入张量可以是任意类型。

  • T1 在 ( tensor(int64) )

    将输出约束为 int64 张量,尽管它应该是一个标量。

Size - 23

版本

  • 名称: Size (GitHub)

  • : main

  • 起始版本23

  • 函数: False

  • 支持级别: SupportType.COMMON

  • 形状推断: True

此版本的操作符已可用于版本 23 及以上

摘要

接受一个张量作为输入,并输出一个 int64 标量,其值等于输入张量的元素总数。

输入

  • data (异构) - T

    一个输入张量。

输出

  • 大小(异构) - T1

    输入张量的元素总数

类型约束

  • T 位于 ( tensor(bfloat16), tensor(bool), tensor(complex128), tensor(complex64), tensor(double), tensor(float), tensor(float16), tensor(float4e2m1), tensor(float8e4m3fn), tensor(float8e4m3fnuz), tensor(float8e5m2), tensor(float8e5m2fnuz), tensor(int16), tensor(int32), tensor(int4), tensor(int64), tensor(int8), tensor(string), tensor(uint16), tensor(uint32), tensor(uint4), tensor(uint64), tensor(uint8) )

    输入张量可以是任意类型。

  • T1 在 ( tensor(int64) )

    将输出约束为 int64 张量,尽管它应该是一个标量。

Size - 21

版本

  • 名称: Size (GitHub)

  • : main

  • since_version: 21

  • 函数: False

  • 支持级别: SupportType.COMMON

  • 形状推断: True

此版本的操作符自 版本 21 起可用。

总结

接受一个张量作为输入,并输出一个 int64 标量,其值等于输入张量的元素总数。

输入

  • data (异构) - T

    一个输入张量。

输出

  • 大小(异构) - T1

    输入张量的元素总数

类型约束

  • T 位于 ( tensor(bfloat16), tensor(bool), tensor(complex128), tensor(complex64), tensor(double), tensor(float), tensor(float16), tensor(float8e4m3fn), tensor(float8e4m3fnuz), tensor(float8e5m2), tensor(float8e5m2fnuz), tensor(int16), tensor(int32), tensor(int4), tensor(int64), tensor(int8), tensor(string), tensor(uint16), tensor(uint32), tensor(uint4), tensor(uint64), tensor(uint8) )

    输入张量可以是任意类型。

  • T1 在 ( tensor(int64) )

    将输出约束为 int64 张量,尽管它应该是一个标量。

Size - 19

版本

  • 名称: Size (GitHub)

  • : main

  • since_version: 19

  • 函数: False

  • 支持级别: SupportType.COMMON

  • 形状推断: True

此版本的操作符自 版本 19 起可用。

总结

接受一个张量作为输入,并输出一个 int64 标量,其值等于输入张量的元素总数。

输入

  • data (异构) - T

    一个输入张量。

输出

  • 大小(异构) - T1

    输入张量的元素总数

类型限制

  • T 位于 ( tensor(bfloat16), tensor(bool), tensor(complex128), tensor(complex64), tensor(double), tensor(float), tensor(float16), tensor(float8e4m3fn), tensor(float8e4m3fnuz), tensor(float8e5m2), tensor(float8e5m2fnuz), tensor(int16), tensor(int32), tensor(int64), tensor(int8), tensor(string), tensor(uint16), tensor(uint32), tensor(uint64), tensor(uint8) )

    输入张量可以是任意类型。

  • T1 在 ( tensor(int64) )

    将输出约束为 int64 张量,尽管它应该是一个标量。

Size - 13

版本

  • 名称: Size (GitHub)

  • : main

  • 起始版本: 13

  • 函数: False

  • 支持级别: SupportType.COMMON

  • 形状推断: True

此版本的运算符自 版本 13 起可用。

摘要

接受一个张量作为输入,并输出一个 int64 标量,其值等于输入张量的元素总数。

输入

  • data (异构) - T

    一个输入张量。

输出

  • 大小(异构) - T1

    输入张量的元素总数

类型限制

  • T 位于 ( tensor(bfloat16), tensor(bool), tensor(complex128), tensor(complex64), tensor(double), tensor(float), tensor(float16), tensor(int16), tensor(int32), tensor(int64), tensor(int8), tensor(string), tensor(uint16), tensor(uint32), tensor(uint64), tensor(uint8) )

    输入张量可以是任意类型。

  • T1 在 ( tensor(int64) )

    将输出约束为 int64 张量,尽管它应该是一个标量。

Size - 1

版本

  • 名称: Size (GitHub)

  • : main

  • 起始版本: 1

  • 函数: False

  • 支持级别: SupportType.COMMON

  • 形状推断: True

此版本的运算符自 版本 1 起可用。

摘要

接受一个张量作为输入,并输出一个 int64 标量,其值等于输入张量的元素总数。

输入

  • data (异构) - T

    一个输入张量。

输出

  • 大小(异构) - T1

    输入张量的元素总数

类型约束

  • T 位于 ( tensor(bool), tensor(complex128), tensor(complex64), tensor(double), tensor(float), tensor(float16), tensor(int16), tensor(int32), tensor(int64), tensor(int8), tensor(string), tensor(uint16), tensor(uint32), tensor(uint64), tensor(uint8) )

    输入张量可以是任意类型。

  • T1 在 ( tensor(int64) )

    将输出约束为 int64 张量,尽管它应该是一个标量。