MCPcopy Create free account
hub / github.com/ARM-software/ComputeLibrary / copy

Function copy

tests/validation/reference/Copy.cpp:37–44  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

35{
36template <typename T>
37SimpleTensor<T> copy(const SimpleTensor<T> &src, const TensorShape &output_shape)
38{
39 ARM_COMPUTE_ERROR_ON_MISMATCHING_DIMENSIONS(src.shape(), output_shape);
40
41 SimpleTensor<T> dst(output_shape, src.data_type());
42 std::copy_n(src.data(), src.num_elements(), dst.data());
43 return dst;
44}
45
46template SimpleTensor<uint8_t> copy(const SimpleTensor<uint8_t> &src, const TensorShape &output_shape);
47template SimpleTensor<int8_t> copy(const SimpleTensor<int8_t> &src, const TensorShape &output_shape);

Callers 11

gemm_reshape_lhs_matrixFunction · 0.70
widthconcatenate_layerFunction · 0.70
conv2d_dftFunction · 0.70
depthconcatenate_layerFunction · 0.70
gemm_reshape_rhs_matrixFunction · 0.70
flatten_layerFunction · 0.70
channel_shuffleFunction · 0.70
get_tileFunction · 0.50
compute_targetMethod · 0.50
compute_referenceMethod · 0.50

Calls 4

shapeMethod · 0.45
data_typeMethod · 0.45
dataMethod · 0.45
num_elementsMethod · 0.45

Tested by

no test coverage detected