// // Generated by the protocol buffer compiler. DO NOT EDIT! // source: tensorflow/core/framework/function.proto // #pragma warning disable 1591, 0612, 3021, 8981 #region Designer generated code using pb = global::Google.Protobuf; using pbc = global::Google.Protobuf.Collections; using pbr = global::Google.Protobuf.Reflection; using scg = global::System.Collections.Generic; namespace Tensorflow { /// Holder for reflection information generated from tensorflow/core/framework/function.proto public static partial class FunctionReflection { #region Descriptor /// File descriptor for tensorflow/core/framework/function.proto public static pbr::FileDescriptor Descriptor { get { return descriptor; } } private static pbr::FileDescriptor descriptor; static FunctionReflection() { byte[] descriptorData = global::System.Convert.FromBase64String( string.Concat( "Cih0ZW5zb3JmbG93L2NvcmUvZnJhbWV3b3JrL2Z1bmN0aW9uLnByb3RvEgp0", "ZW5zb3JmbG93Gip0ZW5zb3JmbG93L2NvcmUvZnJhbWV3b3JrL2F0dHJfdmFs", "dWUucHJvdG8aKHRlbnNvcmZsb3cvY29yZS9mcmFtZXdvcmsvbm9kZV9kZWYu", "cHJvdG8aJnRlbnNvcmZsb3cvY29yZS9mcmFtZXdvcmsvb3BfZGVmLnByb3Rv", "IqgBChJGdW5jdGlvbkRlZkxpYnJhcnkSKQoIZnVuY3Rpb24YASADKAsyFy50", "ZW5zb3JmbG93LkZ1bmN0aW9uRGVmEikKCGdyYWRpZW50GAIgAygLMhcudGVu", "c29yZmxvdy5HcmFkaWVudERlZhI8ChRyZWdpc3RlcmVkX2dyYWRpZW50cxgD", "IAMoCzIeLnRlbnNvcmZsb3cuUmVnaXN0ZXJlZEdyYWRpZW50IsQGCgtGdW5j", "dGlvbkRlZhIkCglzaWduYXR1cmUYASABKAsyES50ZW5zb3JmbG93Lk9wRGVm", "Ei8KBGF0dHIYBSADKAsyIS50ZW5zb3JmbG93LkZ1bmN0aW9uRGVmLkF0dHJF", "bnRyeRI2CghhcmdfYXR0chgHIAMoCzIkLnRlbnNvcmZsb3cuRnVuY3Rpb25E", "ZWYuQXJnQXR0ckVudHJ5ElAKFnJlc291cmNlX2FyZ191bmlxdWVfaWQYCCAD", "KAsyMC50ZW5zb3JmbG93LkZ1bmN0aW9uRGVmLlJlc291cmNlQXJnVW5pcXVl", "SWRFbnRyeRIlCghub2RlX2RlZhgDIAMoCzITLnRlbnNvcmZsb3cuTm9kZURl", "ZhItCgNyZXQYBCADKAsyIC50ZW5zb3JmbG93LkZ1bmN0aW9uRGVmLlJldEVu", "dHJ5EjwKC2NvbnRyb2xfcmV0GAYgAygLMicudGVuc29yZmxvdy5GdW5jdGlv", "bkRlZi5Db250cm9sUmV0RW50cnkaQgoJQXR0ckVudHJ5EgsKA2tleRgBIAEo", "CRIkCgV2YWx1ZRgCIAEoCzIVLnRlbnNvcmZsb3cuQXR0clZhbHVlOgI4ARqI", "AQoIQXJnQXR0cnMSOAoEYXR0chgBIAMoCzIqLnRlbnNvcmZsb3cuRnVuY3Rp", "b25EZWYuQXJnQXR0cnMuQXR0ckVudHJ5GkIKCUF0dHJFbnRyeRILCgNrZXkY", "ASABKAkSJAoFdmFsdWUYAiABKAsyFS50ZW5zb3JmbG93LkF0dHJWYWx1ZToC", "OAEaUAoMQXJnQXR0ckVudHJ5EgsKA2tleRgBIAEoDRIvCgV2YWx1ZRgCIAEo", "CzIgLnRlbnNvcmZsb3cuRnVuY3Rpb25EZWYuQXJnQXR0cnM6AjgBGjoKGFJl", "c291cmNlQXJnVW5pcXVlSWRFbnRyeRILCgNrZXkYASABKA0SDQoFdmFsdWUY", "AiABKA06AjgBGioKCFJldEVudHJ5EgsKA2tleRgBIAEoCRINCgV2YWx1ZRgC", "IAEoCToCOAEaMQoPQ29udHJvbFJldEVudHJ5EgsKA2tleRgBIAEoCRINCgV2", "YWx1ZRgCIAEoCToCOAFKBAgCEAMiOwoLR3JhZGllbnREZWYSFQoNZnVuY3Rp", "b25fbmFtZRgBIAEoCRIVCg1ncmFkaWVudF9mdW5jGAIgASgJIkcKElJlZ2lz", "dGVyZWRHcmFkaWVudBIVCg1ncmFkaWVudF9mdW5jGAEgASgJEhoKEnJlZ2lz", "dGVyZWRfb3BfdHlwZRgCIAEoCUKAAQoYb3JnLnRlbnNvcmZsb3cuZnJhbWV3", "b3JrQg5GdW5jdGlvblByb3Rvc1ABWk9naXRodWIuY29tL3RlbnNvcmZsb3cv", "dGVuc29yZmxvdy90ZW5zb3JmbG93L2dvL2NvcmUvZnJhbWV3b3JrL2Z1bmN0", "aW9uX2dvX3Byb3Rv+AEBYgZwcm90bzM=")); descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, new pbr::FileDescriptor[] { global::Tensorflow.AttrValueReflection.Descriptor, global::Tensorflow.NodeDefReflection.Descriptor, global::Tensorflow.OpDefReflection.Descriptor, }, new pbr::GeneratedClrTypeInfo(null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Tensorflow.FunctionDefLibrary), global::Tensorflow.FunctionDefLibrary.Parser, new[]{ "Function", "Gradient", "RegisteredGradients" }, null, null, null, null), new pbr::GeneratedClrTypeInfo(typeof(global::Tensorflow.FunctionDef), global::Tensorflow.FunctionDef.Parser, new[]{ "Signature", "Attr", "ArgAttr", "ResourceArgUniqueId", "NodeDef", "Ret", "ControlRet" }, null, null, null, new pbr::GeneratedClrTypeInfo[] { null, new pbr::GeneratedClrTypeInfo(typeof(global::Tensorflow.FunctionDef.Types.ArgAttrs), global::Tensorflow.FunctionDef.Types.ArgAttrs.Parser, new[]{ "Attr" }, null, null, null, new pbr::GeneratedClrTypeInfo[] { null, }), null, null, null, null, }), new pbr::GeneratedClrTypeInfo(typeof(global::Tensorflow.GradientDef), global::Tensorflow.GradientDef.Parser, new[]{ "FunctionName", "GradientFunc" }, null, null, null, null), new pbr::GeneratedClrTypeInfo(typeof(global::Tensorflow.RegisteredGradient), global::Tensorflow.RegisteredGradient.Parser, new[]{ "GradientFunc", "RegisteredOpType" }, null, null, null, null) })); } #endregion } #region Messages /// /// A library is a set of named functions. /// public sealed partial class FunctionDefLibrary : pb::IMessage #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE , pb::IBufferMessage #endif { private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FunctionDefLibrary()); private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static pb::MessageParser Parser { get { return _parser; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static pbr::MessageDescriptor Descriptor { get { return global::Tensorflow.FunctionReflection.Descriptor.MessageTypes[0]; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] pbr::MessageDescriptor pb::IMessage.Descriptor { get { return Descriptor; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public FunctionDefLibrary() { OnConstruction(); } partial void OnConstruction(); [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public FunctionDefLibrary(FunctionDefLibrary other) : this() { function_ = other.function_.Clone(); gradient_ = other.gradient_.Clone(); registeredGradients_ = other.registeredGradients_.Clone(); _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public FunctionDefLibrary Clone() { return new FunctionDefLibrary(this); } /// Field number for the "function" field. public const int FunctionFieldNumber = 1; private static readonly pb::FieldCodec _repeated_function_codec = pb::FieldCodec.ForMessage(10, global::Tensorflow.FunctionDef.Parser); private readonly pbc::RepeatedField function_ = new pbc::RepeatedField(); [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public pbc::RepeatedField Function { get { return function_; } } /// Field number for the "gradient" field. public const int GradientFieldNumber = 2; private static readonly pb::FieldCodec _repeated_gradient_codec = pb::FieldCodec.ForMessage(18, global::Tensorflow.GradientDef.Parser); private readonly pbc::RepeatedField gradient_ = new pbc::RepeatedField(); [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public pbc::RepeatedField Gradient { get { return gradient_; } } /// Field number for the "registered_gradients" field. public const int RegisteredGradientsFieldNumber = 3; private static readonly pb::FieldCodec _repeated_registeredGradients_codec = pb::FieldCodec.ForMessage(26, global::Tensorflow.RegisteredGradient.Parser); private readonly pbc::RepeatedField registeredGradients_ = new pbc::RepeatedField(); [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public pbc::RepeatedField RegisteredGradients { get { return registeredGradients_; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override bool Equals(object other) { return Equals(other as FunctionDefLibrary); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public bool Equals(FunctionDefLibrary other) { if (ReferenceEquals(other, null)) { return false; } if (ReferenceEquals(other, this)) { return true; } if(!function_.Equals(other.function_)) return false; if(!gradient_.Equals(other.gradient_)) return false; if(!registeredGradients_.Equals(other.registeredGradients_)) return false; return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override int GetHashCode() { int hash = 1; hash ^= function_.GetHashCode(); hash ^= gradient_.GetHashCode(); hash ^= registeredGradients_.GetHashCode(); if (_unknownFields != null) { hash ^= _unknownFields.GetHashCode(); } return hash; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override string ToString() { return pb::JsonFormatter.ToDiagnosticString(this); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void WriteTo(pb::CodedOutputStream output) { #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE output.WriteRawMessage(this); #else function_.WriteTo(output, _repeated_function_codec); gradient_.WriteTo(output, _repeated_gradient_codec); registeredGradients_.WriteTo(output, _repeated_registeredGradients_codec); if (_unknownFields != null) { _unknownFields.WriteTo(output); } #endif } #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { function_.WriteTo(ref output, _repeated_function_codec); gradient_.WriteTo(ref output, _repeated_gradient_codec); registeredGradients_.WriteTo(ref output, _repeated_registeredGradients_codec); if (_unknownFields != null) { _unknownFields.WriteTo(ref output); } } #endif [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public int CalculateSize() { int size = 0; size += function_.CalculateSize(_repeated_function_codec); size += gradient_.CalculateSize(_repeated_gradient_codec); size += registeredGradients_.CalculateSize(_repeated_registeredGradients_codec); if (_unknownFields != null) { size += _unknownFields.CalculateSize(); } return size; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void MergeFrom(FunctionDefLibrary other) { if (other == null) { return; } function_.Add(other.function_); gradient_.Add(other.gradient_); registeredGradients_.Add(other.registeredGradients_); _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void MergeFrom(pb::CodedInputStream input) { #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE input.ReadRawMessage(this); #else uint tag; while ((tag = input.ReadTag()) != 0) { switch(tag) { default: _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { function_.AddEntriesFrom(input, _repeated_function_codec); break; } case 18: { gradient_.AddEntriesFrom(input, _repeated_gradient_codec); break; } case 26: { registeredGradients_.AddEntriesFrom(input, _repeated_registeredGradients_codec); break; } } } #endif } #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { uint tag; while ((tag = input.ReadTag()) != 0) { switch(tag) { default: _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); break; case 10: { function_.AddEntriesFrom(ref input, _repeated_function_codec); break; } case 18: { gradient_.AddEntriesFrom(ref input, _repeated_gradient_codec); break; } case 26: { registeredGradients_.AddEntriesFrom(ref input, _repeated_registeredGradients_codec); break; } } } } #endif } /// /// A function can be instantiated when the runtime can bind every attr /// with a value. When a GraphDef has a call to a function, it must /// have binding for every attr defined in the signature. /// /// TODO(zhifengc): /// * device spec, etc. /// public sealed partial class FunctionDef : pb::IMessage #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE , pb::IBufferMessage #endif { private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FunctionDef()); private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static pb::MessageParser Parser { get { return _parser; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static pbr::MessageDescriptor Descriptor { get { return global::Tensorflow.FunctionReflection.Descriptor.MessageTypes[1]; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] pbr::MessageDescriptor pb::IMessage.Descriptor { get { return Descriptor; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public FunctionDef() { OnConstruction(); } partial void OnConstruction(); [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public FunctionDef(FunctionDef other) : this() { signature_ = other.signature_ != null ? other.signature_.Clone() : null; attr_ = other.attr_.Clone(); argAttr_ = other.argAttr_.Clone(); resourceArgUniqueId_ = other.resourceArgUniqueId_.Clone(); nodeDef_ = other.nodeDef_.Clone(); ret_ = other.ret_.Clone(); controlRet_ = other.controlRet_.Clone(); _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public FunctionDef Clone() { return new FunctionDef(this); } /// Field number for the "signature" field. public const int SignatureFieldNumber = 1; private global::Tensorflow.OpDef signature_; /// /// The definition of the function's name, arguments, return values, /// attrs etc. /// [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public global::Tensorflow.OpDef Signature { get { return signature_; } set { signature_ = value; } } /// Field number for the "attr" field. public const int AttrFieldNumber = 5; private static readonly pbc::MapField.Codec _map_attr_codec = new pbc::MapField.Codec(pb::FieldCodec.ForString(10, ""), pb::FieldCodec.ForMessage(18, global::Tensorflow.AttrValue.Parser), 42); private readonly pbc::MapField attr_ = new pbc::MapField(); /// /// Attributes specific to this function definition. /// [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public pbc::MapField Attr { get { return attr_; } } /// Field number for the "arg_attr" field. public const int ArgAttrFieldNumber = 7; private static readonly pbc::MapField.Codec _map_argAttr_codec = new pbc::MapField.Codec(pb::FieldCodec.ForUInt32(8, 0), pb::FieldCodec.ForMessage(18, global::Tensorflow.FunctionDef.Types.ArgAttrs.Parser), 58); private readonly pbc::MapField argAttr_ = new pbc::MapField(); [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public pbc::MapField ArgAttr { get { return argAttr_; } } /// Field number for the "resource_arg_unique_id" field. public const int ResourceArgUniqueIdFieldNumber = 8; private static readonly pbc::MapField.Codec _map_resourceArgUniqueId_codec = new pbc::MapField.Codec(pb::FieldCodec.ForUInt32(8, 0), pb::FieldCodec.ForUInt32(16, 0), 66); private readonly pbc::MapField resourceArgUniqueId_ = new pbc::MapField(); /// /// Unique IDs for each resource argument, used to track aliasing resources. If /// Argument A and Argument B alias each other, then /// resource_arg_unique_ids[A.index] == resource_arg_unique_ids[B.index]. /// /// If this field is empty, none of the arguments could alias; otherwise, every /// resource argument should have an entry in this field. /// /// When instantiated, the unique IDs will be attached to the _Arg nodes' /// "_resource_arg_unique_id" attribute. /// [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public pbc::MapField ResourceArgUniqueId { get { return resourceArgUniqueId_; } } /// Field number for the "node_def" field. public const int NodeDefFieldNumber = 3; private static readonly pb::FieldCodec _repeated_nodeDef_codec = pb::FieldCodec.ForMessage(26, global::Tensorflow.NodeDef.Parser); private readonly pbc::RepeatedField nodeDef_ = new pbc::RepeatedField(); /// /// By convention, "op" in node_def is resolved by consulting with a /// user-defined library first. If not resolved, "func" is assumed to /// be a builtin op. /// [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public pbc::RepeatedField NodeDef { get { return nodeDef_; } } /// Field number for the "ret" field. public const int RetFieldNumber = 4; private static readonly pbc::MapField.Codec _map_ret_codec = new pbc::MapField.Codec(pb::FieldCodec.ForString(10, ""), pb::FieldCodec.ForString(18, ""), 34); private readonly pbc::MapField ret_ = new pbc::MapField(); /// /// A mapping from the output arg names from `signature` to the /// outputs from `node_def` that should be returned by the function. /// [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public pbc::MapField Ret { get { return ret_; } } /// Field number for the "control_ret" field. public const int ControlRetFieldNumber = 6; private static readonly pbc::MapField.Codec _map_controlRet_codec = new pbc::MapField.Codec(pb::FieldCodec.ForString(10, ""), pb::FieldCodec.ForString(18, ""), 50); private readonly pbc::MapField controlRet_ = new pbc::MapField(); /// /// A mapping from control output names from `signature` to node names in /// `node_def` which should be control outputs of this function. /// [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public pbc::MapField ControlRet { get { return controlRet_; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override bool Equals(object other) { return Equals(other as FunctionDef); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public bool Equals(FunctionDef other) { if (ReferenceEquals(other, null)) { return false; } if (ReferenceEquals(other, this)) { return true; } if (!object.Equals(Signature, other.Signature)) return false; if (!Attr.Equals(other.Attr)) return false; if (!ArgAttr.Equals(other.ArgAttr)) return false; if (!ResourceArgUniqueId.Equals(other.ResourceArgUniqueId)) return false; if(!nodeDef_.Equals(other.nodeDef_)) return false; if (!Ret.Equals(other.Ret)) return false; if (!ControlRet.Equals(other.ControlRet)) return false; return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override int GetHashCode() { int hash = 1; if (signature_ != null) hash ^= Signature.GetHashCode(); hash ^= Attr.GetHashCode(); hash ^= ArgAttr.GetHashCode(); hash ^= ResourceArgUniqueId.GetHashCode(); hash ^= nodeDef_.GetHashCode(); hash ^= Ret.GetHashCode(); hash ^= ControlRet.GetHashCode(); if (_unknownFields != null) { hash ^= _unknownFields.GetHashCode(); } return hash; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override string ToString() { return pb::JsonFormatter.ToDiagnosticString(this); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void WriteTo(pb::CodedOutputStream output) { #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE output.WriteRawMessage(this); #else if (signature_ != null) { output.WriteRawTag(10); output.WriteMessage(Signature); } nodeDef_.WriteTo(output, _repeated_nodeDef_codec); ret_.WriteTo(output, _map_ret_codec); attr_.WriteTo(output, _map_attr_codec); controlRet_.WriteTo(output, _map_controlRet_codec); argAttr_.WriteTo(output, _map_argAttr_codec); resourceArgUniqueId_.WriteTo(output, _map_resourceArgUniqueId_codec); if (_unknownFields != null) { _unknownFields.WriteTo(output); } #endif } #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { if (signature_ != null) { output.WriteRawTag(10); output.WriteMessage(Signature); } nodeDef_.WriteTo(ref output, _repeated_nodeDef_codec); ret_.WriteTo(ref output, _map_ret_codec); attr_.WriteTo(ref output, _map_attr_codec); controlRet_.WriteTo(ref output, _map_controlRet_codec); argAttr_.WriteTo(ref output, _map_argAttr_codec); resourceArgUniqueId_.WriteTo(ref output, _map_resourceArgUniqueId_codec); if (_unknownFields != null) { _unknownFields.WriteTo(ref output); } } #endif [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public int CalculateSize() { int size = 0; if (signature_ != null) { size += 1 + pb::CodedOutputStream.ComputeMessageSize(Signature); } size += attr_.CalculateSize(_map_attr_codec); size += argAttr_.CalculateSize(_map_argAttr_codec); size += resourceArgUniqueId_.CalculateSize(_map_resourceArgUniqueId_codec); size += nodeDef_.CalculateSize(_repeated_nodeDef_codec); size += ret_.CalculateSize(_map_ret_codec); size += controlRet_.CalculateSize(_map_controlRet_codec); if (_unknownFields != null) { size += _unknownFields.CalculateSize(); } return size; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void MergeFrom(FunctionDef other) { if (other == null) { return; } if (other.signature_ != null) { if (signature_ == null) { Signature = new global::Tensorflow.OpDef(); } Signature.MergeFrom(other.Signature); } attr_.MergeFrom(other.attr_); argAttr_.MergeFrom(other.argAttr_); resourceArgUniqueId_.MergeFrom(other.resourceArgUniqueId_); nodeDef_.Add(other.nodeDef_); ret_.MergeFrom(other.ret_); controlRet_.MergeFrom(other.controlRet_); _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void MergeFrom(pb::CodedInputStream input) { #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE input.ReadRawMessage(this); #else uint tag; while ((tag = input.ReadTag()) != 0) { switch(tag) { default: _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { if (signature_ == null) { Signature = new global::Tensorflow.OpDef(); } input.ReadMessage(Signature); break; } case 26: { nodeDef_.AddEntriesFrom(input, _repeated_nodeDef_codec); break; } case 34: { ret_.AddEntriesFrom(input, _map_ret_codec); break; } case 42: { attr_.AddEntriesFrom(input, _map_attr_codec); break; } case 50: { controlRet_.AddEntriesFrom(input, _map_controlRet_codec); break; } case 58: { argAttr_.AddEntriesFrom(input, _map_argAttr_codec); break; } case 66: { resourceArgUniqueId_.AddEntriesFrom(input, _map_resourceArgUniqueId_codec); break; } } } #endif } #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { uint tag; while ((tag = input.ReadTag()) != 0) { switch(tag) { default: _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); break; case 10: { if (signature_ == null) { Signature = new global::Tensorflow.OpDef(); } input.ReadMessage(Signature); break; } case 26: { nodeDef_.AddEntriesFrom(ref input, _repeated_nodeDef_codec); break; } case 34: { ret_.AddEntriesFrom(ref input, _map_ret_codec); break; } case 42: { attr_.AddEntriesFrom(ref input, _map_attr_codec); break; } case 50: { controlRet_.AddEntriesFrom(ref input, _map_controlRet_codec); break; } case 58: { argAttr_.AddEntriesFrom(ref input, _map_argAttr_codec); break; } case 66: { resourceArgUniqueId_.AddEntriesFrom(ref input, _map_resourceArgUniqueId_codec); break; } } } } #endif #region Nested types /// Container for nested types declared in the FunctionDef message type. [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static partial class Types { /// /// Attributes for function arguments. These attributes are the same set of /// valid attributes as to _Arg nodes. /// public sealed partial class ArgAttrs : pb::IMessage #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE , pb::IBufferMessage #endif { private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ArgAttrs()); private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static pb::MessageParser Parser { get { return _parser; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static pbr::MessageDescriptor Descriptor { get { return global::Tensorflow.FunctionDef.Descriptor.NestedTypes[1]; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] pbr::MessageDescriptor pb::IMessage.Descriptor { get { return Descriptor; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public ArgAttrs() { OnConstruction(); } partial void OnConstruction(); [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public ArgAttrs(ArgAttrs other) : this() { attr_ = other.attr_.Clone(); _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public ArgAttrs Clone() { return new ArgAttrs(this); } /// Field number for the "attr" field. public const int AttrFieldNumber = 1; private static readonly pbc::MapField.Codec _map_attr_codec = new pbc::MapField.Codec(pb::FieldCodec.ForString(10, ""), pb::FieldCodec.ForMessage(18, global::Tensorflow.AttrValue.Parser), 10); private readonly pbc::MapField attr_ = new pbc::MapField(); [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public pbc::MapField Attr { get { return attr_; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override bool Equals(object other) { return Equals(other as ArgAttrs); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public bool Equals(ArgAttrs other) { if (ReferenceEquals(other, null)) { return false; } if (ReferenceEquals(other, this)) { return true; } if (!Attr.Equals(other.Attr)) return false; return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override int GetHashCode() { int hash = 1; hash ^= Attr.GetHashCode(); if (_unknownFields != null) { hash ^= _unknownFields.GetHashCode(); } return hash; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override string ToString() { return pb::JsonFormatter.ToDiagnosticString(this); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void WriteTo(pb::CodedOutputStream output) { #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE output.WriteRawMessage(this); #else attr_.WriteTo(output, _map_attr_codec); if (_unknownFields != null) { _unknownFields.WriteTo(output); } #endif } #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { attr_.WriteTo(ref output, _map_attr_codec); if (_unknownFields != null) { _unknownFields.WriteTo(ref output); } } #endif [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public int CalculateSize() { int size = 0; size += attr_.CalculateSize(_map_attr_codec); if (_unknownFields != null) { size += _unknownFields.CalculateSize(); } return size; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void MergeFrom(ArgAttrs other) { if (other == null) { return; } attr_.MergeFrom(other.attr_); _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void MergeFrom(pb::CodedInputStream input) { #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE input.ReadRawMessage(this); #else uint tag; while ((tag = input.ReadTag()) != 0) { switch(tag) { default: _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { attr_.AddEntriesFrom(input, _map_attr_codec); break; } } } #endif } #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { uint tag; while ((tag = input.ReadTag()) != 0) { switch(tag) { default: _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); break; case 10: { attr_.AddEntriesFrom(ref input, _map_attr_codec); break; } } } } #endif } } #endregion } /// /// GradientDef defines the gradient function of a function defined in /// a function library. /// /// A gradient function g (specified by gradient_func) for a function f /// (specified by function_name) must follow the following: /// /// The function 'f' must be a numerical function which takes N inputs /// and produces M outputs. Its gradient function 'g', which is a /// function taking N + M inputs and produces N outputs. /// /// I.e. if we have /// (y1, y2, ..., y_M) = f(x1, x2, ..., x_N), /// then, g is /// (dL/dx1, dL/dx2, ..., dL/dx_N) = g(x1, x2, ..., x_N, /// dL/dy1, dL/dy2, ..., dL/dy_M), /// where L is a scalar-value function of (x1, x2, ..., xN) (e.g., the /// loss function). dL/dx_i is the partial derivative of L with respect /// to x_i. /// public sealed partial class GradientDef : pb::IMessage #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE , pb::IBufferMessage #endif { private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GradientDef()); private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static pb::MessageParser Parser { get { return _parser; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static pbr::MessageDescriptor Descriptor { get { return global::Tensorflow.FunctionReflection.Descriptor.MessageTypes[2]; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] pbr::MessageDescriptor pb::IMessage.Descriptor { get { return Descriptor; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public GradientDef() { OnConstruction(); } partial void OnConstruction(); [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public GradientDef(GradientDef other) : this() { functionName_ = other.functionName_; gradientFunc_ = other.gradientFunc_; _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public GradientDef Clone() { return new GradientDef(this); } /// Field number for the "function_name" field. public const int FunctionNameFieldNumber = 1; private string functionName_ = ""; /// /// The function name. /// [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public string FunctionName { get { return functionName_; } set { functionName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); } } /// Field number for the "gradient_func" field. public const int GradientFuncFieldNumber = 2; private string gradientFunc_ = ""; /// /// The gradient function's name. /// [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public string GradientFunc { get { return gradientFunc_; } set { gradientFunc_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override bool Equals(object other) { return Equals(other as GradientDef); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public bool Equals(GradientDef other) { if (ReferenceEquals(other, null)) { return false; } if (ReferenceEquals(other, this)) { return true; } if (FunctionName != other.FunctionName) return false; if (GradientFunc != other.GradientFunc) return false; return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override int GetHashCode() { int hash = 1; if (FunctionName.Length != 0) hash ^= FunctionName.GetHashCode(); if (GradientFunc.Length != 0) hash ^= GradientFunc.GetHashCode(); if (_unknownFields != null) { hash ^= _unknownFields.GetHashCode(); } return hash; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override string ToString() { return pb::JsonFormatter.ToDiagnosticString(this); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void WriteTo(pb::CodedOutputStream output) { #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE output.WriteRawMessage(this); #else if (FunctionName.Length != 0) { output.WriteRawTag(10); output.WriteString(FunctionName); } if (GradientFunc.Length != 0) { output.WriteRawTag(18); output.WriteString(GradientFunc); } if (_unknownFields != null) { _unknownFields.WriteTo(output); } #endif } #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { if (FunctionName.Length != 0) { output.WriteRawTag(10); output.WriteString(FunctionName); } if (GradientFunc.Length != 0) { output.WriteRawTag(18); output.WriteString(GradientFunc); } if (_unknownFields != null) { _unknownFields.WriteTo(ref output); } } #endif [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public int CalculateSize() { int size = 0; if (FunctionName.Length != 0) { size += 1 + pb::CodedOutputStream.ComputeStringSize(FunctionName); } if (GradientFunc.Length != 0) { size += 1 + pb::CodedOutputStream.ComputeStringSize(GradientFunc); } if (_unknownFields != null) { size += _unknownFields.CalculateSize(); } return size; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void MergeFrom(GradientDef other) { if (other == null) { return; } if (other.FunctionName.Length != 0) { FunctionName = other.FunctionName; } if (other.GradientFunc.Length != 0) { GradientFunc = other.GradientFunc; } _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void MergeFrom(pb::CodedInputStream input) { #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE input.ReadRawMessage(this); #else uint tag; while ((tag = input.ReadTag()) != 0) { switch(tag) { default: _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { FunctionName = input.ReadString(); break; } case 18: { GradientFunc = input.ReadString(); break; } } } #endif } #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { uint tag; while ((tag = input.ReadTag()) != 0) { switch(tag) { default: _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); break; case 10: { FunctionName = input.ReadString(); break; } case 18: { GradientFunc = input.ReadString(); break; } } } } #endif } /// /// RegisteredGradient stores a gradient function that is registered in the /// gradients library and used in the ops of a function in the function library. /// Unlike GradientDef, these gradients are identified by op type, and not /// directly linked to any function. /// public sealed partial class RegisteredGradient : pb::IMessage #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE , pb::IBufferMessage #endif { private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new RegisteredGradient()); private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static pb::MessageParser Parser { get { return _parser; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static pbr::MessageDescriptor Descriptor { get { return global::Tensorflow.FunctionReflection.Descriptor.MessageTypes[3]; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] pbr::MessageDescriptor pb::IMessage.Descriptor { get { return Descriptor; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public RegisteredGradient() { OnConstruction(); } partial void OnConstruction(); [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public RegisteredGradient(RegisteredGradient other) : this() { gradientFunc_ = other.gradientFunc_; registeredOpType_ = other.registeredOpType_; _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public RegisteredGradient Clone() { return new RegisteredGradient(this); } /// Field number for the "gradient_func" field. public const int GradientFuncFieldNumber = 1; private string gradientFunc_ = ""; /// /// The gradient function's name. /// [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public string GradientFunc { get { return gradientFunc_; } set { gradientFunc_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); } } /// Field number for the "registered_op_type" field. public const int RegisteredOpTypeFieldNumber = 2; private string registeredOpType_ = ""; /// /// The gradient function's registered op type. /// [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public string RegisteredOpType { get { return registeredOpType_; } set { registeredOpType_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override bool Equals(object other) { return Equals(other as RegisteredGradient); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public bool Equals(RegisteredGradient other) { if (ReferenceEquals(other, null)) { return false; } if (ReferenceEquals(other, this)) { return true; } if (GradientFunc != other.GradientFunc) return false; if (RegisteredOpType != other.RegisteredOpType) return false; return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override int GetHashCode() { int hash = 1; if (GradientFunc.Length != 0) hash ^= GradientFunc.GetHashCode(); if (RegisteredOpType.Length != 0) hash ^= RegisteredOpType.GetHashCode(); if (_unknownFields != null) { hash ^= _unknownFields.GetHashCode(); } return hash; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override string ToString() { return pb::JsonFormatter.ToDiagnosticString(this); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void WriteTo(pb::CodedOutputStream output) { #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE output.WriteRawMessage(this); #else if (GradientFunc.Length != 0) { output.WriteRawTag(10); output.WriteString(GradientFunc); } if (RegisteredOpType.Length != 0) { output.WriteRawTag(18); output.WriteString(RegisteredOpType); } if (_unknownFields != null) { _unknownFields.WriteTo(output); } #endif } #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { if (GradientFunc.Length != 0) { output.WriteRawTag(10); output.WriteString(GradientFunc); } if (RegisteredOpType.Length != 0) { output.WriteRawTag(18); output.WriteString(RegisteredOpType); } if (_unknownFields != null) { _unknownFields.WriteTo(ref output); } } #endif [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public int CalculateSize() { int size = 0; if (GradientFunc.Length != 0) { size += 1 + pb::CodedOutputStream.ComputeStringSize(GradientFunc); } if (RegisteredOpType.Length != 0) { size += 1 + pb::CodedOutputStream.ComputeStringSize(RegisteredOpType); } if (_unknownFields != null) { size += _unknownFields.CalculateSize(); } return size; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void MergeFrom(RegisteredGradient other) { if (other == null) { return; } if (other.GradientFunc.Length != 0) { GradientFunc = other.GradientFunc; } if (other.RegisteredOpType.Length != 0) { RegisteredOpType = other.RegisteredOpType; } _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public void MergeFrom(pb::CodedInputStream input) { #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE input.ReadRawMessage(this); #else uint tag; while ((tag = input.ReadTag()) != 0) { switch(tag) { default: _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { GradientFunc = input.ReadString(); break; } case 18: { RegisteredOpType = input.ReadString(); break; } } } #endif } #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { uint tag; while ((tag = input.ReadTag()) != 0) { switch(tag) { default: _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); break; case 10: { GradientFunc = input.ReadString(); break; } case 18: { RegisteredOpType = input.ReadString(); break; } } } } #endif } #endregion } #endregion Designer generated code