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

Function GetHash

tensorflow/lite/delegates/nnapi/nnapi_delegate.cc:348–355  ·  view source on GitHub ↗

Compute the hash of a TfLiteIntArray.

Source from the content-addressed store, hash-verified

346
347// Compute the hash of a TfLiteIntArray.
348uint64_t GetHash(const TfLiteIntArray* int_array) {
349 constexpr auto kHashConst = 0x9e3779b97f4a7800ULL;
350 uint64_t result = 0;
351 for (auto i : TfLiteIntArrayView(int_array)) {
352 result = result ^ (i + kHashConst + (result << 10) + (result >> 4));
353 }
354 return result;
355}
356
357bool HasZeroes(TfLiteIntArrayView array) {
358 for (auto value : array) {

Callers 1

InitMethod · 0.85

Calls 1

TfLiteIntArrayViewClass · 0.50

Tested by

no test coverage detected