- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 182 for Deallocator (0.24 sec)
-
tensorflow/c/tf_tensor.h
// // The data will be deallocated by a subsequent call to TF_DeleteTensor via: // (*deallocator)(data, len, deallocator_arg) // Clients must provide a custom deallocator function so they can pass in // memory managed by something like numpy. // // May return NULL (and invoke the deallocator) if the provided data buffer // (data, len) is inconsistent with a tensor of the given TF_DataType
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Mar 06 16:40:30 UTC 2024 - 6.3K bytes - Viewed (0) -
tensorflow/c/tf_tensor_internal.h
} }; // Allocates tensor data buffer using specified allocator. // `operation` is a name for this operation. void* allocate_tensor(const char* operation, size_t len, Allocator* allocator); // Deallocates tensor data buffer. // Defaults to deallocating using CPU allocator. You can pass pointer to // a different Allocator as `arg`. void deallocate_buffer(void* data, size_t len, void* arg);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Aug 24 20:38:55 UTC 2023 - 4.6K bytes - Viewed (0) -
tensorflow/c/tf_tensor.cc
Allocator* allocator = nullptr; if (arg == nullptr) { allocator = cpu_allocator(); } else { allocator = reinterpret_cast<Allocator*>(arg); } if (LogMemory::IsEnabled() && data != nullptr) { LogMemory::RecordRawDeallocation( "TensorFlow C Api", LogMemory::EXTERNAL_TENSOR_ALLOCATION_STEP_ID, data, allocator, false); } allocator->DeallocateRaw(data);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Sun Apr 14 21:57:32 UTC 2024 - 11.5K bytes - Viewed (0) -
tensorflow/c/tf_buffer.h
typedef struct TF_Buffer { const void* data; size_t length; void (*data_deallocator)(void* data, size_t length); } TF_Buffer; // Makes a copy of the input and sets an appropriate deallocator. Useful for // passing in read-only, input protobufs. TF_CAPI_EXPORT extern TF_Buffer* TF_NewBufferFromString(const void* proto, size_t proto_len);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 27 21:07:00 UTC 2023 - 2K bytes - Viewed (0) -
tensorflow/c/eager/c_api.cc
void (*deallocator)(void* data, size_t len, void* arg), void* deallocator_arg, TF_Status* status) { tensorflow::Device* device = nullptr; tensorflow::EagerContext* context = tensorflow::ContextFromInterface(tensorflow::unwrap(ctx)); status->status = context->FindDeviceFromName(device_name, &device); if (!status->status.ok()) { deallocator(data, len, deallocator_arg);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu May 09 08:11:23 UTC 2024 - 44K bytes - Viewed (0) -
tensorflow/c/eager/custom_device_testutil.cc
auto dtype = TFE_TensorHandleDataType(t->tensor); TFE_CustomDeviceTensorHandleMethods handle_methods; handle_methods.num_dims = &LoggedTensorNumDims; handle_methods.dim = &LoggedTensorDim; handle_methods.deallocator = &LoggedTensorDeallocator; return TFE_NewCustomDeviceTensorHandle(context, logging_device_name.c_str(), dtype, t.release(), handle_methods,
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Mar 03 20:47:31 UTC 2021 - 8.3K bytes - Viewed (0) -
tensorflow/c/eager/c_api_experimental.h
TF_CAPI_EXPORT extern TFE_TensorHandle* TFE_NewTensorHandleFromDeviceMemory( TFE_Context* ctx, const char* device_name, TF_DataType, const int64_t* dims, int num_dims, void* data, size_t len, void (*deallocator)(void* data, size_t len, void* arg), void* deallocator_arg, TF_Status* status); // Retrieves the address space (i.e. job, replia, task) of the local host and // saves it in the buffer.
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Feb 21 22:37:46 UTC 2024 - 39.5K bytes - Viewed (0) -
tensorflow/c/c_api_test.cc
TF_TString_Init(&tstr[0]); TF_TString_Copy(&tstr[0], test_string, sizeof(test_string) - 1); auto deallocator = [](void* data, size_t len, void* arg) {}; unique_tensor_ptr t_in(TF_NewTensor(TF_STRING, nullptr, 0, &tstr[0], sizeof(tstr), deallocator, nullptr), TF_DeleteTensor); // Create a TF_Operation with the attribute t_in
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Mon Apr 15 03:35:10 UTC 2024 - 96.9K bytes - Viewed (0) -
tensorflow/c/eager/parallel_device/parallel_device.cc
ParallelTensor* t_released = t.release(); TFE_CustomDeviceTensorHandleMethods handle_methods; handle_methods.num_dims = &ParallelTensorNumDims; handle_methods.dim = &ParallelTensorDim; handle_methods.deallocator = &ParallelTensorDeallocator; handle_methods.summarize = &ParallelTensorSummarize; return TensorHandlePtr(TFE_NewCustomDeviceTensorHandle( context, parallel_device_name.c_str(), t_released->dtype(), t_released,
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Mar 29 22:05:31 UTC 2023 - 18.3K bytes - Viewed (0) -
pkg/registry/core/service/ipallocator/ipallocator.go
return len(ips) } // for testing, it assumes this is the allocator is unique for the ipFamily func (a *Allocator) Free() int { return int(a.size) - a.Used() } // Destroy func (a *Allocator) Destroy() { } // DryRun func (a *Allocator) DryRun() Interface { return dryRunAllocator{a} } // EnableMetrics func (a *Allocator) EnableMetrics() { registerMetrics()
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Oct 31 21:05:04 UTC 2023 - 17K bytes - Viewed (0)