EsTensorLike Constructor and Destructor

Applicability

Product

Supported or Not

Atlas A3 training products/Atlas A3 inference products

Atlas A2 training products/Atlas A2 inference products

Atlas 200I/500 A2 inference products

Atlas inference products

Atlas training products

Header File/Library File

  • Header file: #include <ge/es_tensor_like.h>
  • Library files: libeager_style_graph_builder_base.so and libeager_style_graph_builder_base_static.a

Function Usage

Constructs and destructs an object of class EsTensorLike.

Prototype

1
2
3
4
5
6
7
EsTensorLike(const EsTensorHolder &tensor)
EsTensorLike(const std::nullptr_t)
EsTensorLike(const int64_t value)
EsTensorLike(const float value)
EsTensorLike(const std::vector<int64_t> &values)
EsTensorLike(const std::vector<float> &values)
~EsTensorLike()

Parameters

Parameter

Input/Output

Description

tensor

Input

EsTensorHolder object.

nullptr_t

Input

Null pointer.

value

Input

int64_t and float scalars.

values

Input

int64_t and float vectors.

Returns

None

Constraints

None

Examples

1
2
EsTensorHolder tensor = builder->CreateScalar(int64_t(1));
EsTensorLike tensor_like(tensor);