MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / TFE_TensorHandleNumElements

Function TFE_TensorHandleNumElements

tensorflow/c/eager/c_api.cc:494–503  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

492}
493
494int64_t TFE_TensorHandleNumElements(TFE_TensorHandle* h, TF_Status* status) {
495 if (h == nullptr || h->handle == nullptr) {
496 status->status = tensorflow::errors::InvalidArgument(
497 "The passed in handle is a nullptr");
498 return -1;
499 }
500 tensorflow::int64 result;
501 status->status = h->handle->NumElements(&result);
502 return result;
503}
504
505int64_t TFE_TensorHandleDim(TFE_TensorHandle* h, int dim_index,
506 TF_Status* status) {

Callers 2

EagerTensor_num_elementsFunction · 0.85

Calls 2

InvalidArgumentFunction · 0.85
NumElementsMethod · 0.45

Tested by

no test coverage detected