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

Function AttrDefHash

tensorflow/core/framework/op_def_util.cc:786–795  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

784}
785
786uint64 AttrDefHash(const OpDef::AttrDef& a) {
787 uint64 h = Hash64(a.name());
788 h = Hash64(a.type().data(), a.type().size(), h);
789 h = Hash64Combine(AttrValueHash(a.default_value()), h);
790 h = Hash64(a.description().data(), a.description().size(), h);
791 h = Hash64Combine(static_cast<uint64>(a.has_minimum()), h);
792 h = Hash64Combine(static_cast<uint64>(a.minimum()), h);
793 h = Hash64Combine(AttrValueHash(a.allowed_values()), h);
794 return h;
795}
796
797bool RepeatedAttrDefEqual(
798 const protobuf::RepeatedPtrField<OpDef::AttrDef>& a1,

Callers 3

RepeatedAttrDefHashFunction · 0.85
ExpectDifferentFunction · 0.85
TESTFunction · 0.85

Calls 10

Hash64CombineFunction · 0.85
AttrValueHashFunction · 0.85
descriptionMethod · 0.80
minimumMethod · 0.80
nameMethod · 0.65
typeMethod · 0.65
Hash64Function · 0.50
dataMethod · 0.45
sizeMethod · 0.45
default_valueMethod · 0.45

Tested by 2

ExpectDifferentFunction · 0.68
TESTFunction · 0.68