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

Function CreateTensor

tensorflow/core/kernels/data/dataset_test_base.h:86–91  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

84// Creates a tensor with the specified dtype, shape, and value.
85template <typename T>
86static Tensor CreateTensor(const TensorShape& input_shape,
87 const gtl::ArraySlice<T>& input_data) {
88 Tensor tensor(DataTypeToEnum<T>::value, input_shape);
89 test::FillValues<T>(&tensor, input_data);
90 return tensor;
91}
92
93// Creates a vector of tensors with the specified dtype, shape, and values.
94template <typename T>

Callers 1

BuildTensorMethod · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected