MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / CopyFrom

Function CopyFrom

tensorflow/core/kernels/einsum_op.cc:302–307  ·  view source on GitHub ↗

Returns a reshaped input Tensor. The underlying buffer is not copied.

Source from the content-addressed store, hash-verified

300
301// Returns a reshaped input Tensor. The underlying buffer is not copied.
302Status CopyFrom(const Tensor& input, const TensorShape& shape, Tensor* output) {
303 if (output->CopyFrom(input, shape)) return Status::OK();
304 return errors::Internal(
305 "Encountered error while reshaping a Tensor of shape ",
306 input.shape().DebugString(), " to shape ", shape.DebugString());
307}
308
309// Returns whether transposing would be a no-op; whether input has rank < 2 or
310// the permutation is the identity permutation.

Callers 6

TransposeOperandFunction · 0.85
StrideOrInflateFunction · 0.85
ReduceOperandFunction · 0.85
ReshapeToRank3Function · 0.85
ContractOperandsFunction · 0.85
ComputeMethod · 0.85

Calls 4

InternalFunction · 0.85
CopyFromMethod · 0.45
DebugStringMethod · 0.45
shapeMethod · 0.45

Tested by

no test coverage detected