- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 16 for static_cast (0.06 sec)
-
tensorflow/c/c_api_experimental.cc
namespace { typedef std::unique_ptr<TF_Function, decltype(&TF_DeleteFunction)> UniqueFuncPtr; } // struct TF_Operation { tensorflow::Node node; }; static TF_Operation* ToTF_Operation(Node* node) { return static_cast<TF_Operation*>(static_cast<void*>(node)); } void TF_EnableXLACompilation(TF_SessionOptions* options, unsigned char enable) { tensorflow::ConfigProto& config = options->options.config; auto* optimizer_options =
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_experimental.cc
delete counter; } TFE_MonitoringCounterCell* TFE_MonitoringGetCellCounter0( TFE_MonitoringCounter0* counter) { return static_cast<TFE_MonitoringCounterCell*>( static_cast<void*>(counter->counter->GetCell())); } TFE_MonitoringCounter1* TFE_MonitoringNewCounter1(const char* name, TF_Status* status,
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 35.9K bytes - Viewed (0) -
tensorflow/c/eager/c_api.cc
for (int i = 0; i < num_dims; ++i) { dimvec[i] = static_cast<int64_t>(dims[i]); } // TODO(apassos) do we need to wrap the deallocator here to make sure to sync // the device? TF_ManagedBuffer* buf = new TF_ManagedBuffer(data, len, deallocator, deallocator_arg, /*owns_memory=*/false); tensorflow::Tensor t(static_cast<tensorflow::DataType>(dtype),
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 43.9K bytes - Viewed (0) -
tensorflow/c/eager/dlpack.cc
dlm_tensor->dl_tensor.byte_offset = 0; // TF doesn't handle the strides and byte_offsets here return static_cast<void*>(dlm_tensor); } TFE_TensorHandle* TFE_HandleFromDLPack(void* dlm, TF_Status* status, TFE_Context* ctx) { DLManagedTensor* dlmt = static_cast<DLManagedTensor*>(dlm); DLTensor* dl_tensor = &dlmt->dl_tensor; absl::optional<std::string> device_name =
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 12.9K bytes - Viewed (0) -
tensorflow/c/eager/c_api_unified_experimental_graph.cc
for (int i = 0; i < num_values; ++i) { op_->colocation_constraints.emplace(static_cast<const char*>(values[i]), lengths[i]); } } else { std::vector<tensorflow::StringPiece> v; v.reserve(num_values); for (int i = 0; i < num_values; ++i) { v.emplace_back(static_cast<const char*>(values[i]), lengths[i]); }
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 15.7K bytes - Viewed (0) -
tensorflow/c/eager/c_api_cluster_test.cc
.ok()); ASSERT_TRUE(worker_server->Start().ok()); TF_Status* status = TF_NewStatus(); TFE_ContextOptions* opts = TFE_NewContextOptions(); TFE_ContextOptionsSetAsync(opts, static_cast<unsigned char>(async)); TFE_ContextOptionsSetDevicePlacementPolicy(opts, TFE_DEVICE_PLACEMENT_SILENT); TFE_Context* ctx = TFE_NewContext(opts, status); EXPECT_EQ(TF_OK, TF_GetCode(status)) << TF_Message(status);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 19.2K bytes - Viewed (0) -
tensorflow/c/c_test_util.cc
delete[] static_cast<bool*>(data); } static void Int32Deallocator(void* data, size_t, void* arg) { delete[] static_cast<int32_t*>(data); } static void DoubleDeallocator(void* data, size_t, void* arg) { delete[] static_cast<double*>(data); } static void FloatDeallocator(void* data, size_t, void* arg) { delete[] static_cast<float*>(data); } TF_Tensor* BoolTensor(bool v) {
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Fri Oct 15 03:16:52 UTC 2021 - 17.8K bytes - Viewed (0) -
tensorflow/c/eager/c_api_experimental_test.cc
auto* cell2 = TFE_MonitoringGetCellStringGauge2(gauge2, "foo", "bar"); TFE_MonitoringStringGaugeCellSet(cell2, "str"); auto* buf = new TF_Buffer; TFE_MonitoringStringGaugeCellValue(cell2, buf); string data(static_cast<const char*>(buf->data), buf->length); TF_DeleteBuffer(buf); EXPECT_EQ(data, "str"); TFE_MonitoringDeleteStringGauge2(gauge2); TF_DeleteStatus(status); } TEST(CAPI, MonitoringSampler0) {
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Thu Aug 03 03:14:26 UTC 2023 - 31.5K bytes - Viewed (0) -
tensorflow/c/eager/gradients.cc
// TODO(b/172558015): Using the pointer address as the identifier for the tensor // may lead to collisions. Introduce another way to get a unique id for this // tensor. int64_t ToId(const AbstractTensorHandle* t) { return static_cast<int64_t>(reinterpret_cast<uintptr_t>(t)); } absl::Status ZerosLike(AbstractContext* ctx, AbstractTensorHandle* t, AbstractTensorHandle** result) { AbstractOperationPtr op(ctx->CreateOperation());
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 19.7K bytes - Viewed (0) -
tensorflow/c/eager/parallel_device/parallel_device_lib_test.cc
{"condition", "x"}, {{"T", std::vector<DataType>{DT_FLOAT}}}}, {{"y"}, "CollectiveReduce", {"x"}, {{"T", DT_FLOAT}, {"group_size", static_cast<int>(devices.size())}, {"group_key", 0}, {"instance_key", 0}, {"merge_op", "Add"}, {"final_op", "Id"}, {"subdiv_offsets", std::vector<int>()}},
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Mon Oct 21 04:14:14 UTC 2024 - 15.6K bytes - Viewed (0)