tensorflow::ops::EnsureShape

#include <array_ops.h>

Ensures that the tensor's shape matches the expected shape.

Summary

Raises an error if the input tensor's shape does not match the specified shape. Returns the input tensor otherwise.

Args:

  • scope: A Scope object
  • input: A tensor, whose shape is to be validated.
  • shape: The expected (possibly partially specified) shape of the input tensor.

Returns:

  • Output: A tensor with the same shape and contents as the input tensor or value.

Constructors and Destructors

EnsureShape(const ::tensorflow::Scope & scope, ::tensorflow::Input input, PartialTensorShape shape)

Public attributes

operation
output

Public functions

node() const
::tensorflow::Node *
operator::tensorflow::Input() const
operator::tensorflow::Output() const

Public attributes

operation

Operation operation

output

::tensorflow::Output output

Public functions

EnsureShape

 EnsureShape(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input input,
  PartialTensorShape shape
)

node

::tensorflow::Node * node() const 

operator::tensorflow::Input

 operator::tensorflow::Input() const 

operator::tensorflow::Output

 operator::tensorflow::Output() const