- Sort Score
- Result 10 results
- Languages All
Results 1 - 3 of 3 for TF_NewTensor (0.06 sec)
-
tensorflow/c/eager/parallel_device/parallel_device_lib.h
++device_index) { auto device_value = absl::make_unique<DataType>(); *device_value = values[device_index]; std::unique_ptr<TF_Tensor, decltype(&TF_DeleteTensor)> tensor( TF_NewTensor( datatype_enum, /*dims=*/nullptr, /*num_dims=*/0, device_value.release(), sizeof(DataType), [](void* data, size_t, void* arg) { delete reinterpret_cast<DataType*>(data);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Mon Oct 21 04:14:14 UTC 2024 - 13.1K bytes - Viewed (0) -
tensorflow/c/c_api_test.cc
reinterpret_cast<float*>(tensorflow::cpu_allocator()->AllocateRaw( TF_TensorDefaultAlignment(), num_bytes)); int64_t dims[] = {2, 3}; bool deallocator_called = false; TF_Tensor* t = TF_NewTensor(TF_FLOAT, dims, 2, values, num_bytes, &Deallocator, &deallocator_called); EXPECT_FALSE(deallocator_called); EXPECT_EQ(TF_FLOAT, TF_TensorType(t)); EXPECT_EQ(2, TF_NumDims(t));
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 16:27:48 UTC 2024 - 97K bytes - Viewed (0) -
tensorflow/c/c_api.cc
dims.reserve(shape.dims()); for (int i = 0; i < shape.dims(); ++i) { dims.push_back(shape.dim_size(i)); nelems *= shape.dim_size(i); } CHECK_EQ(nelems, 0); return TF_NewTensor( dtype, reinterpret_cast<const int64_t*>(dims.data()), shape.dims(), reinterpret_cast<void*>(&empty), 0, [](void*, size_t, void*) {}, nullptr); } static void TF_Run_Helper(
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 16:27:48 UTC 2024 - 102.3K bytes - Viewed (0)