Home
last modified time | relevance | path

Searched refs:new_tensor (Results 1 – 9 of 9) sorted by relevance

/external/eigen/unsupported/test/
Dcxx11_tensor_assign.cpp238 Tensor<int, 1> new_tensor(5); in test_auto_resize() local
239 new_tensor.setRandom(); in test_auto_resize()
241 tensor1 = tensor2 = tensor3 = tensor4 = new_tensor; in test_auto_resize()
243 VERIFY_IS_EQUAL(tensor1.dimension(0), new_tensor.dimension(0)); in test_auto_resize()
244 VERIFY_IS_EQUAL(tensor2.dimension(0), new_tensor.dimension(0)); in test_auto_resize()
245 VERIFY_IS_EQUAL(tensor3.dimension(0), new_tensor.dimension(0)); in test_auto_resize()
246 VERIFY_IS_EQUAL(tensor4.dimension(0), new_tensor.dimension(0)); in test_auto_resize()
247 for (int i = 0; i < new_tensor.dimension(0); ++i) { in test_auto_resize()
248 VERIFY_IS_EQUAL(tensor1(i), new_tensor(i)); in test_auto_resize()
249 VERIFY_IS_EQUAL(tensor2(i), new_tensor(i)); in test_auto_resize()
[all …]
/external/tensorflow/tensorflow/lite/delegates/
Dutils_test.cc58 TfLiteTensor* new_tensor = nullptr; in TEST() local
62 /**new_type**/ kTfLiteUInt8, &new_tensor, &new_tensor_index), in TEST()
65 EXPECT_NE(new_tensor, nullptr); in TEST()
66 EXPECT_NE(new_tensor->dims, nullptr); in TEST()
67 EXPECT_EQ(new_tensor->type, kTfLiteUInt8); in TEST()
68 EXPECT_EQ(new_tensor->allocation_type, kTfLiteArenaRw); in TEST()
Dutils.cc31 TfLiteTensor** new_tensor, in CreateNewTensorWithDifferentType() argument
35 *new_tensor = &context->tensors[*new_tensor_index]; in CreateNewTensorWithDifferentType()
36 (*new_tensor)->type = new_type; in CreateNewTensorWithDifferentType()
37 (*new_tensor)->allocation_type = kTfLiteArenaRw; in CreateNewTensorWithDifferentType()
43 if (context->ResizeTensor(context, *new_tensor, dims) != kTfLiteOk) { in CreateNewTensorWithDifferentType()
Dutils.h41 TfLiteTensor** new_tensor,
/external/tensorflow/tensorflow/compiler/xla/service/
Dindexed_array_analysis.h331 T* new_tensor = new T(std::forward<Args>(args)...); in Construct() local
332 owned_tensors_.push_back(std::unique_ptr<T>(new_tensor)); in Construct()
333 return new_tensor; in Construct()
/external/tensorflow/tensorflow/core/framework/
Dop_kernel.cc471 std::unique_ptr<Tensor> new_tensor = forward_input( in forward_input_to_output_with_shape() local
474 if (new_tensor != nullptr) { in forward_input_to_output_with_shape()
476 outputs_[output_index] = TensorValue(new_tensor.release()); in forward_input_to_output_with_shape()
571 std::unique_ptr<Tensor> new_tensor = in forward_input_or_allocate_temp() local
574 if (new_tensor != nullptr) { in forward_input_or_allocate_temp()
575 *out_temp = std::move(*new_tensor); in forward_input_or_allocate_temp()
710 Tensor new_tensor( in allocate_tensor() local
716 if (!new_tensor.IsInitialized()) { in allocate_tensor()
724 params_->step_id, new_tensor); in allocate_tensor()
726 *out_tensor = std::move(new_tensor); in allocate_tensor()
[all …]
/external/tensorflow/tensorflow/python/framework/
Dsparse_tensor_test.py103 new_tensor = source.with_values([5.0, 1.0])
104 self.assertAllEqual(new_tensor.indices, source.indices)
105 self.assertAllEqual(new_tensor.values, [5.0, 1.0])
106 self.assertAllEqual(new_tensor.dense_shape, source.dense_shape)
Dops.py1157 new_tensor = self._copy_to_device(device_name)
1160 return new_tensor
1164 new_tensor = self._copy_nograd(ctx, device_name)
1175 tape.record_operation("_copy", [new_tensor], [self], grad_fun)
1176 return new_tensor
/external/tensorflow/tensorflow/lite/delegates/nnapi/
Dnnapi_delegate.cc1094 TfLiteTensor* new_tensor = &context_->tensors[*tensor_index]; in AddNewInputConstantTensor() local
1095 new_tensor->type = type; in AddNewInputConstantTensor()
1096 new_tensor->allocation_type = kTfLiteDynamic; in AddNewInputConstantTensor()
1097 new_tensor->params = quant_params; in AddNewInputConstantTensor()
1104 context_, new_tensor, in AddNewInputConstantTensor()
1108 memcpy(new_tensor->data.raw, in AddNewInputConstantTensor()
1131 nn_model_, ann_tensor_index, new_tensor->data.raw, in AddNewInputConstantTensor()
1132 new_tensor->bytes), in AddNewInputConstantTensor()
1417 TfLiteTensor* new_tensor = &context_->tensors[new_tensor_index]; in AddTensor() local
1418 new_tensor->type = kTfLiteUInt8; in AddTensor()
[all …]