Package ai.onnx.proto

Interface OnnxMl.SparseTensorProtoOrBuilder

All Superinterfaces:
com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder
All Known Implementing Classes:
OnnxMl.SparseTensorProto, OnnxMl.SparseTensorProto.Builder
Enclosing class:
OnnxMl

public static interface OnnxMl.SparseTensorProtoOrBuilder extends com.google.protobuf.MessageOrBuilder
  • Method Summary

    Modifier and Type
    Method
    Description
    long
    getDims(int index)
    The shape of the underlying dense-tensor: [dim_1, dim_2, ...
    int
    The shape of the underlying dense-tensor: [dim_1, dim_2, ...
    The shape of the underlying dense-tensor: [dim_1, dim_2, ...
    The indices of the non-default values, which may be stored in one of two formats.
    The indices of the non-default values, which may be stored in one of two formats.
    The sequence of non-default values are encoded as a tensor of shape [NNZ].
    The sequence of non-default values are encoded as a tensor of shape [NNZ].
    boolean
    The indices of the non-default values, which may be stored in one of two formats.
    boolean
    The sequence of non-default values are encoded as a tensor of shape [NNZ].

    Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder

    isInitialized

    Methods inherited from interface com.google.protobuf.MessageOrBuilder

    findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
  • Method Details

    • hasValues

      boolean hasValues()
       The sequence of non-default values are encoded as a tensor of shape [NNZ].
       The default-value is zero for numeric tensors, and empty-string for string tensors.
       values must have a non-empty name present which serves as a name for SparseTensorProto
       when used in sparse_initializer list.
       
      optional .onnx.TensorProto values = 1;
      Returns:
      Whether the values field is set.
    • getValues

      OnnxMl.TensorProto getValues()
       The sequence of non-default values are encoded as a tensor of shape [NNZ].
       The default-value is zero for numeric tensors, and empty-string for string tensors.
       values must have a non-empty name present which serves as a name for SparseTensorProto
       when used in sparse_initializer list.
       
      optional .onnx.TensorProto values = 1;
      Returns:
      The values.
    • getValuesOrBuilder

      OnnxMl.TensorProtoOrBuilder getValuesOrBuilder()
       The sequence of non-default values are encoded as a tensor of shape [NNZ].
       The default-value is zero for numeric tensors, and empty-string for string tensors.
       values must have a non-empty name present which serves as a name for SparseTensorProto
       when used in sparse_initializer list.
       
      optional .onnx.TensorProto values = 1;
    • hasIndices

      boolean hasIndices()
       The indices of the non-default values, which may be stored in one of two formats.
       (a) Indices can be a tensor of shape [NNZ, rank] with the [i,j]-th value
       corresponding to the j-th index of the i-th value (in the values tensor).
       (b) Indices can be a tensor of shape [NNZ], in which case the i-th value
       must be the linearized-index of the i-th value (in the values tensor).
       The linearized-index can be converted into an index tuple (k_1,...,k_rank)
       using the shape provided below.
       The indices must appear in ascending order without duplication.
       In the first format, the ordering is lexicographic-ordering:
       e.g., index-value [1,4] must appear before [2,1]
       
      optional .onnx.TensorProto indices = 2;
      Returns:
      Whether the indices field is set.
    • getIndices

      OnnxMl.TensorProto getIndices()
       The indices of the non-default values, which may be stored in one of two formats.
       (a) Indices can be a tensor of shape [NNZ, rank] with the [i,j]-th value
       corresponding to the j-th index of the i-th value (in the values tensor).
       (b) Indices can be a tensor of shape [NNZ], in which case the i-th value
       must be the linearized-index of the i-th value (in the values tensor).
       The linearized-index can be converted into an index tuple (k_1,...,k_rank)
       using the shape provided below.
       The indices must appear in ascending order without duplication.
       In the first format, the ordering is lexicographic-ordering:
       e.g., index-value [1,4] must appear before [2,1]
       
      optional .onnx.TensorProto indices = 2;
      Returns:
      The indices.
    • getIndicesOrBuilder

      OnnxMl.TensorProtoOrBuilder getIndicesOrBuilder()
       The indices of the non-default values, which may be stored in one of two formats.
       (a) Indices can be a tensor of shape [NNZ, rank] with the [i,j]-th value
       corresponding to the j-th index of the i-th value (in the values tensor).
       (b) Indices can be a tensor of shape [NNZ], in which case the i-th value
       must be the linearized-index of the i-th value (in the values tensor).
       The linearized-index can be converted into an index tuple (k_1,...,k_rank)
       using the shape provided below.
       The indices must appear in ascending order without duplication.
       In the first format, the ordering is lexicographic-ordering:
       e.g., index-value [1,4] must appear before [2,1]
       
      optional .onnx.TensorProto indices = 2;
    • getDimsList

      List<Long> getDimsList()
       The shape of the underlying dense-tensor: [dim_1, dim_2, ... dim_rank]
       
      repeated int64 dims = 3;
      Returns:
      A list containing the dims.
    • getDimsCount

      int getDimsCount()
       The shape of the underlying dense-tensor: [dim_1, dim_2, ... dim_rank]
       
      repeated int64 dims = 3;
      Returns:
      The count of dims.
    • getDims

      long getDims(int index)
       The shape of the underlying dense-tensor: [dim_1, dim_2, ... dim_rank]
       
      repeated int64 dims = 3;
      Parameters:
      index - The index of the element to return.
      Returns:
      The dims at the given index.