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

Method num_elements

tensorflow/compiler/xla/array.h:416–419  ·  view source on GitHub ↗

Returns the total number of elements in the array.

Source from the content-addressed store, hash-verified

414
415 // Returns the total number of elements in the array.
416 int64 num_elements() const {
417 return std::accumulate(sizes_.begin(), sizes_.end(), 1LL,
418 std::multiplies<int64>());
419 }
420
421 const T* begin() const { return &values_[0]; }
422 T* begin() { return &values_[0]; }

Callers 15

ValidateNodeFunction · 0.45
CalculateFlopsFunction · 0.45
MainFunction · 0.45
TestQuantizeMulMethod · 0.45
TestQuantizeAddMethod · 0.45
SetNodeTensorAttrFunction · 0.45
process_desired_shapeFunction · 0.45
sequence_input_layerFunction · 0.45
_sample_nMethod · 0.45
_sample_nMethod · 0.45
_sample_nMethod · 0.45

Calls 2

beginMethod · 0.45
endMethod · 0.45

Tested by 15

TestQuantizeMulMethod · 0.36
TestQuantizeAddMethod · 0.36
testAveragesMethod · 0.36
testFlatten4DMethod · 0.36
testFlatten3DMethod · 0.36
testFlattenBatchSizeMethod · 0.36
testUnknownDimsMethod · 0.36
TEST_FFunction · 0.36
TEST_FFunction · 0.36
TESTFunction · 0.36
TESTFunction · 0.36
TESTFunction · 0.36