Package ai.onnxruntime
Enum Class OnnxSparseTensor.SparseTensorType
- All Implemented Interfaces:
Serializable,Comparable<OnnxSparseTensor.SparseTensorType>,Constable
- Enclosing class:
- OnnxSparseTensor
public static enum OnnxSparseTensor.SparseTensorType
extends Enum<OnnxSparseTensor.SparseTensorType>
The type of the sparse tensor.
Should be synchronized with OrtSparseFormat in the C API.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionBlock sparse tensor.COO sparse tensor.CSR or CSC sparse tensor.Undefined sparse tensor. -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionmapFromInt(int value) Maps from an int in native land into a SparseTensorType instance.Returns the enum constant of this class with the specified name.static OnnxSparseTensor.SparseTensorType[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
UNDEFINED
Undefined sparse tensor. -
COO
COO sparse tensor. -
CSRC
CSR or CSC sparse tensor. -
BLOCK_SPARSE
Block sparse tensor.
-
-
Field Details
-
value
public final int valueThe int value mirroring OrtSparseFormat.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
mapFromInt
Maps from an int in native land into a SparseTensorType instance.- Parameters:
value- The value to lookup.- Returns:
- The enum instance.
-