SetTensorShape

Description

Sets the shape of a tensor.

Prototype

bool SetTensorShape(const TensorShape *shape)

Parameters

Parameter

Input/Output

Description

shape

Input

A TensorShape for the tensor shape.

Returns

A bool:

  • true on success;
  • false on failure.

Restrictions

None

Example

bool ret = tensor->SetTensorShape(shape);