- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 295 for memcpy (0.05 sec)
-
tensorflow/c/eager/gradient_checker.cc
TF_RETURN_IF_ERROR(GetValue(theta, &theta_tensor)); // Get number of elements and fill data. int num_elems = TF_TensorElementCount(theta_tensor); vector<float> theta_data(num_elems); memcpy(theta_data.data(), TF_TensorData(theta_tensor), TF_TensorByteSize(theta_tensor)); // Initialize space for the numerical gradient. vector<float> dtheta_approx(num_elems);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 7.3K bytes - Viewed (0) -
tensorflow/c/eager/c_api_test_util.cc
TFE_TensorHandle* TestScalarTensorHandle(TFE_Context* ctx, float value) { float data[] = {value}; TF_Status* status = TF_NewStatus(); TF_Tensor* t = TFE_AllocateHostTensor(ctx, TF_FLOAT, nullptr, 0, status); memcpy(TF_TensorData(t), &data[0], TF_TensorByteSize(t)); TFE_TensorHandle* th = TFE_NewTensorHandleFromTensor(ctx, t, status); CHECK_EQ(TF_OK, TF_GetCode(status)) << TF_Message(status); TF_DeleteTensor(t);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Wed Feb 21 22:37:46 UTC 2024 - 23.5K bytes - Viewed (0) -
ci/official/containers/linux_arm64/builder.devtoolset/stringop_trunc.patch
- ? (__string2_1bptr_p (src) && strlen (src) + 1 <= 8 \ - ? __strcpy_small (dest, __strcpy_args (src), \ - strlen (src) + 1) \ - : (char *) memcpy (dest, src, strlen (src) + 1)) \ - : strcpy (dest, src))) -# endif - +#if defined _FORCE_INLINES # if _STRING_ARCH_unaligned -# ifndef _FORCE_INLINES -# define __strcpy_args(src) \
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Mon Sep 18 14:52:45 UTC 2023 - 42.9K bytes - Viewed (0) -
tensorflow/c/c_api_experimental.cc
*len = debug_str.size(); char* ret = static_cast<char*>(malloc(*len + 1)); memcpy(ret, debug_str.c_str(), *len + 1); return ret; } char* TF_FunctionDebugString(TF_Function* func, size_t* len) { const auto& debug_str = DebugString(func->record->fdef()); *len = debug_str.size(); char* ret = static_cast<char*>(malloc(*len + 1)); memcpy(ret, debug_str.c_str(), *len + 1); return ret; }
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 16:27:48 UTC 2024 - 29.5K bytes - Viewed (0) -
tensorflow/c/eager/c_api_test.cc
EXPECT_EQ(TF_FLOAT, TFE_TensorHandleDataType(h)); TF_Tensor* t = TFE_TensorHandleResolve(h, status.get()); ASSERT_EQ(16, TF_TensorByteSize(t)); float data[4] = {0}; memcpy(&data[0], TF_TensorData(t), TF_TensorByteSize(t)); EXPECT_EQ(1.0, data[0]); EXPECT_EQ(2.0, data[1]); EXPECT_EQ(3.0, data[2]); EXPECT_EQ(4.0, data[3]); TF_DeleteTensor(t); TFE_DeleteTensorHandle(h);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Thu Aug 03 20:50:20 UTC 2023 - 94.6K bytes - Viewed (0) -
tensorflow/c/eager/c_api_unified_experimental_test.cc
ASSERT_EQ(TF_OK, TF_GetCode(s)) << TF_Message(s); memcpy(&result_data[0], TF_TensorData(f_t), TF_TensorByteSize(f_t)); // Verify results for each output for (int j = 0; j < 4; j++) { ASSERT_EQ(result_data[j], expected_outputs[idx][j]); } TF_DeleteTensor(f_t); } // Free memory associated with add and MatMul outputs for (int idx = 0; idx < 3; ++idx) {
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 39.1K bytes - Viewed (0) -
tensorflow/c/eager/c_api_test_util.h
const int64_t* dims, int num_dims) { TF_Status* status = TF_NewStatus(); TF_Tensor* t = TFE_AllocateHostTensor(ctx, datatype, dims, num_dims, status); memcpy(TF_TensorData(t), data, TF_TensorByteSize(t)); TFE_TensorHandle* th = TFE_NewTensorHandleFromTensor(ctx, t, status); CHECK_EQ(TF_OK, TF_GetCode(status)) << TF_Message(status); TF_DeleteTensor(t); TF_DeleteStatus(status);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Mon Jul 17 23:43:59 UTC 2023 - 7.7K bytes - Viewed (0) -
tensorflow/c/eager/c_api_distributed_test.cc
ASSERT_EQ(TF_GetCode(status), TF_OK) << TF_Message(status); TFE_DeleteTensorHandle(retvals[0]); float sum = 0; EXPECT_EQ(sizeof(sum), TF_TensorByteSize(t)); memcpy(&sum, TF_TensorData(t), TF_TensorByteSize(t)); TF_DeleteTensor(t); EXPECT_EQ(sum, 6.0); TFE_DeleteTensorHandle(h0); TFE_DeleteTensorHandle(h1); TFE_DeleteTensorHandle(h2);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 23.4K bytes - Viewed (0) -
tensorflow/c/eager/gradient_checker_test.cc
ASSERT_EQ(errors::OK, s.code()) << s.message(); auto num_elem_numerical = TF_TensorElementCount(numerical_tensor); ASSERT_EQ(num_elem_numerical, num_grad); float* dnumerical = new float[num_elem_numerical]{0}; memcpy(&dnumerical[0], TF_TensorData(numerical_tensor), TF_TensorByteSize(numerical_tensor)); for (int j = 0; j < num_grad; j++) { ASSERT_NEAR(dnumerical[j], expected_grad[j], abs_error); }
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 6.5K bytes - Viewed (0) -
tensorflow/c/eager/c_api_experimental_test.cc
TFE_DeleteExecutor(old_executor); TFE_DeleteContext(ctx); ASSERT_EQ(TF_OK, TF_GetCode(status)) << TF_Message(status); float product[4] = {0}; EXPECT_EQ(sizeof(product), TF_TensorByteSize(t)); memcpy(&product[0], TF_TensorData(t), TF_TensorByteSize(t)); TF_DeleteTensor(t); EXPECT_EQ(7, product[0]); EXPECT_EQ(10, product[1]); EXPECT_EQ(15, product[2]); EXPECT_EQ(22, product[3]);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Thu Aug 03 03:14:26 UTC 2023 - 31.5K bytes - Viewed (0)