Package ai.onnx.proto

Class OnnxMl.TensorAnnotation.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderType>
com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder>
ai.onnx.proto.OnnxMl.TensorAnnotation.Builder
All Implemented Interfaces:
OnnxMl.TensorAnnotationOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
OnnxMl.TensorAnnotation

public static final class OnnxMl.TensorAnnotation.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder> implements OnnxMl.TensorAnnotationOrBuilder
Protobuf type onnx.TensorAnnotation
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder>
    • clear

      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder>
    • getDefaultInstanceForType

      public OnnxMl.TensorAnnotation getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public OnnxMl.TensorAnnotation build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public OnnxMl.TensorAnnotation buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • clone

      Specified by:
      clone in interface com.google.protobuf.Message.Builder
      Specified by:
      clone in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clone in class com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder>
    • setField

      public OnnxMl.TensorAnnotation.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
      Specified by:
      setField in interface com.google.protobuf.Message.Builder
      Overrides:
      setField in class com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder>
    • clearField

      public OnnxMl.TensorAnnotation.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
      Specified by:
      clearField in interface com.google.protobuf.Message.Builder
      Overrides:
      clearField in class com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder>
    • clearOneof

      public OnnxMl.TensorAnnotation.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
      Specified by:
      clearOneof in interface com.google.protobuf.Message.Builder
      Overrides:
      clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder>
    • setRepeatedField

      public OnnxMl.TensorAnnotation.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
      Specified by:
      setRepeatedField in interface com.google.protobuf.Message.Builder
      Overrides:
      setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder>
    • addRepeatedField

      public OnnxMl.TensorAnnotation.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
      Specified by:
      addRepeatedField in interface com.google.protobuf.Message.Builder
      Overrides:
      addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder>
    • mergeFrom

      public OnnxMl.TensorAnnotation.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<OnnxMl.TensorAnnotation.Builder>
    • mergeFrom

    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder>
    • mergeFrom

      public OnnxMl.TensorAnnotation.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<OnnxMl.TensorAnnotation.Builder>
      Throws:
      IOException
    • hasTensorName

      public boolean hasTensorName()
      optional string tensor_name = 1;
      Specified by:
      hasTensorName in interface OnnxMl.TensorAnnotationOrBuilder
      Returns:
      Whether the tensorName field is set.
    • getTensorName

      public String getTensorName()
      optional string tensor_name = 1;
      Specified by:
      getTensorName in interface OnnxMl.TensorAnnotationOrBuilder
      Returns:
      The tensorName.
    • getTensorNameBytes

      public com.google.protobuf.ByteString getTensorNameBytes()
      optional string tensor_name = 1;
      Specified by:
      getTensorNameBytes in interface OnnxMl.TensorAnnotationOrBuilder
      Returns:
      The bytes for tensorName.
    • setTensorName

      public OnnxMl.TensorAnnotation.Builder setTensorName(String value)
      optional string tensor_name = 1;
      Parameters:
      value - The tensorName to set.
      Returns:
      This builder for chaining.
    • clearTensorName

      public OnnxMl.TensorAnnotation.Builder clearTensorName()
      optional string tensor_name = 1;
      Returns:
      This builder for chaining.
    • setTensorNameBytes

      public OnnxMl.TensorAnnotation.Builder setTensorNameBytes(com.google.protobuf.ByteString value)
      optional string tensor_name = 1;
      Parameters:
      value - The bytes for tensorName to set.
      Returns:
      This builder for chaining.
    • getQuantParameterTensorNamesList

      public List<OnnxMl.StringStringEntryProto> getQuantParameterTensorNamesList()
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
      Specified by:
      getQuantParameterTensorNamesList in interface OnnxMl.TensorAnnotationOrBuilder
    • getQuantParameterTensorNamesCount

      public int getQuantParameterTensorNamesCount()
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
      Specified by:
      getQuantParameterTensorNamesCount in interface OnnxMl.TensorAnnotationOrBuilder
    • getQuantParameterTensorNames

      public OnnxMl.StringStringEntryProto getQuantParameterTensorNames(int index)
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
      Specified by:
      getQuantParameterTensorNames in interface OnnxMl.TensorAnnotationOrBuilder
    • setQuantParameterTensorNames

      public OnnxMl.TensorAnnotation.Builder setQuantParameterTensorNames(int index, OnnxMl.StringStringEntryProto value)
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
    • setQuantParameterTensorNames

      public OnnxMl.TensorAnnotation.Builder setQuantParameterTensorNames(int index, OnnxMl.StringStringEntryProto.Builder builderForValue)
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
    • addQuantParameterTensorNames

      public OnnxMl.TensorAnnotation.Builder addQuantParameterTensorNames(OnnxMl.StringStringEntryProto value)
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
    • addQuantParameterTensorNames

      public OnnxMl.TensorAnnotation.Builder addQuantParameterTensorNames(int index, OnnxMl.StringStringEntryProto value)
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
    • addQuantParameterTensorNames

      public OnnxMl.TensorAnnotation.Builder addQuantParameterTensorNames(OnnxMl.StringStringEntryProto.Builder builderForValue)
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
    • addQuantParameterTensorNames

      public OnnxMl.TensorAnnotation.Builder addQuantParameterTensorNames(int index, OnnxMl.StringStringEntryProto.Builder builderForValue)
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
    • addAllQuantParameterTensorNames

      public OnnxMl.TensorAnnotation.Builder addAllQuantParameterTensorNames(Iterable<? extends OnnxMl.StringStringEntryProto> values)
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
    • clearQuantParameterTensorNames

      public OnnxMl.TensorAnnotation.Builder clearQuantParameterTensorNames()
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
    • removeQuantParameterTensorNames

      public OnnxMl.TensorAnnotation.Builder removeQuantParameterTensorNames(int index)
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
    • getQuantParameterTensorNamesBuilder

      public OnnxMl.StringStringEntryProto.Builder getQuantParameterTensorNamesBuilder(int index)
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
    • getQuantParameterTensorNamesOrBuilder

      public OnnxMl.StringStringEntryProtoOrBuilder getQuantParameterTensorNamesOrBuilder(int index)
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
      Specified by:
      getQuantParameterTensorNamesOrBuilder in interface OnnxMl.TensorAnnotationOrBuilder
    • getQuantParameterTensorNamesOrBuilderList

      public List<? extends OnnxMl.StringStringEntryProtoOrBuilder> getQuantParameterTensorNamesOrBuilderList()
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
      Specified by:
      getQuantParameterTensorNamesOrBuilderList in interface OnnxMl.TensorAnnotationOrBuilder
    • addQuantParameterTensorNamesBuilder

      public OnnxMl.StringStringEntryProto.Builder addQuantParameterTensorNamesBuilder()
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
    • addQuantParameterTensorNamesBuilder

      public OnnxMl.StringStringEntryProto.Builder addQuantParameterTensorNamesBuilder(int index)
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
    • getQuantParameterTensorNamesBuilderList

      public List<OnnxMl.StringStringEntryProto.Builder> getQuantParameterTensorNamesBuilderList()
       <key, value> pairs to annotate tensor specified by <tensor_name> above.
       The keys used in the mapping below must be pre-defined in ONNX spec.
       For example, for 8-bit linear quantization case, 'SCALE_TENSOR', 'ZERO_POINT_TENSOR' will be pre-defined as
       quantization parameter keys.
       
      repeated .onnx.StringStringEntryProto quant_parameter_tensor_names = 2;
    • setUnknownFields

      public final OnnxMl.TensorAnnotation.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      setUnknownFields in interface com.google.protobuf.Message.Builder
      Overrides:
      setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder>
    • mergeUnknownFields

      public final OnnxMl.TensorAnnotation.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      mergeUnknownFields in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<OnnxMl.TensorAnnotation.Builder>