Package org.tensorflow.framework
Enum Class DataType
- All Implemented Interfaces:
com.google.protobuf.Internal.EnumLite,com.google.protobuf.ProtocolMessageEnum,Serializable,Comparable<DataType>,Constable
(== suppress_warning documentation-presence ==) LINT.IfChangeProtobuf enum
tensorflow.DataType-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionFloat32 truncated to 16 bits.DT_BFLOAT16_REF = 114;DT_BOOL = 10;DT_BOOL_REF = 110;Double-precision complexDT_COMPLEX128_REF = 118;Single-precision complexDT_COMPLEX64_REF = 108;DT_DOUBLE = 2;DT_DOUBLE_REF = 102;Data types that all computation devices are expected to be capable to support.Do not use!4 exponent bits, 3 mantissa bits, finite-only, withDT_FLOAT8_E4M3FN_REF = 125;5 exponent bits, 2 mantissa bits.DT_FLOAT8_E5M2_REF = 124;DT_HALF = 19;DT_HALF_REF = 119;DT_INT16 = 5;DT_INT16_REF = 105;DT_INT32 = 3;DT_INT32_REF = 103;2 NaNs (0bS1111111).TODO - b/299182407: Leaving room for remaining float8 types.DT_INT64 = 9;DT_INT64_REF = 109;DT_INT8 = 6;DT_INT8_REF = 106;Not a legal value for DataType.Quantized int16DT_QINT16_REF = 115;Quantized int32DT_QINT32_REF = 113;Quantized int8DT_QINT8_REF = 111;Quantized uint16DT_QUINT16_REF = 116;Quantized uint8DT_QUINT8_REF = 112;DT_RESOURCE = 20;DT_RESOURCE_REF = 120;DT_STRING = 7;DT_STRING_REF = 107;DT_UINT16 = 17;DT_UINT16_REF = 117;DT_UINT32 = 22;DT_UINT32_REF = 122;DT_UINT4 = 30;DT_UINT4_REF = 130;DT_UINT64 = 23;DT_UINT64_REF = 123;DT_UINT8 = 4;DT_UINT8_REF = 104;Arbitrary C++ data typesDT_VARIANT_REF = 121; -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intDT_BFLOAT16_REF = 114;static final intFloat32 truncated to 16 bits.static final intDT_BOOL_REF = 110;static final intDT_BOOL = 10;static final intDT_COMPLEX128_REF = 118;static final intDouble-precision complexstatic final intDT_COMPLEX64_REF = 108;static final intSingle-precision complexstatic final intDT_DOUBLE_REF = 102;static final intDT_DOUBLE = 2;static final intDo not use!static final intData types that all computation devices are expected to be capable to support.static final intDT_FLOAT8_E4M3FN_REF = 125;static final int4 exponent bits, 3 mantissa bits, finite-only, withstatic final intDT_FLOAT8_E5M2_REF = 124;static final int5 exponent bits, 2 mantissa bits.static final intDT_HALF_REF = 119;static final intDT_HALF = 19;static final intDT_INT16_REF = 105;static final intDT_INT16 = 5;static final intDT_INT32_REF = 103;static final intDT_INT32 = 3;static final intTODO - b/299182407: Leaving room for remaining float8 types.static final int2 NaNs (0bS1111111).static final intDT_INT64_REF = 109;static final intDT_INT64 = 9;static final intDT_INT8_REF = 106;static final intDT_INT8 = 6;static final intNot a legal value for DataType.static final intDT_QINT16_REF = 115;static final intQuantized int16static final intDT_QINT32_REF = 113;static final intQuantized int32static final intDT_QINT8_REF = 111;static final intQuantized int8static final intDT_QUINT16_REF = 116;static final intQuantized uint16static final intDT_QUINT8_REF = 112;static final intQuantized uint8static final intDT_RESOURCE_REF = 120;static final intDT_RESOURCE = 20;static final intDT_STRING_REF = 107;static final intDT_STRING = 7;static final intDT_UINT16_REF = 117;static final intDT_UINT16 = 17;static final intDT_UINT32_REF = 122;static final intDT_UINT32 = 22;static final intDT_UINT4_REF = 130;static final intDT_UINT4 = 30;static final intDT_UINT64_REF = 123;static final intDT_UINT64 = 23;static final intDT_UINT8_REF = 104;static final intDT_UINT8 = 4;static final intDT_VARIANT_REF = 121;static final intArbitrary C++ data types -
Method Summary
Modifier and TypeMethodDescriptionstatic DataTypeforNumber(int value) static final com.google.protobuf.Descriptors.EnumDescriptorfinal com.google.protobuf.Descriptors.EnumDescriptorfinal intfinal com.google.protobuf.Descriptors.EnumValueDescriptorstatic com.google.protobuf.Internal.EnumLiteMap<DataType> static DataTypevalueOf(int value) Deprecated.static DataTypevalueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) Returns the enum constant of this class with the specified name.static DataTypeReturns the enum constant of this class with the specified name.static DataType[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
DT_INVALID
Not a legal value for DataType. Used to indicate a DataType field has not been set.
DT_INVALID = 0; -
DT_FLOAT
Data types that all computation devices are expected to be capable to support.
DT_FLOAT = 1; -
DT_DOUBLE
DT_DOUBLE = 2; -
DT_INT32
DT_INT32 = 3; -
DT_UINT8
DT_UINT8 = 4; -
DT_INT16
DT_INT16 = 5; -
DT_INT8
DT_INT8 = 6; -
DT_STRING
DT_STRING = 7; -
DT_COMPLEX64
Single-precision complex
DT_COMPLEX64 = 8; -
DT_INT64
DT_INT64 = 9; -
DT_BOOL
DT_BOOL = 10; -
DT_QINT8
Quantized int8
DT_QINT8 = 11; -
DT_QUINT8
Quantized uint8
DT_QUINT8 = 12; -
DT_QINT32
Quantized int32
DT_QINT32 = 13; -
DT_BFLOAT16
Float32 truncated to 16 bits.
DT_BFLOAT16 = 14; -
DT_QINT16
Quantized int16
DT_QINT16 = 15; -
DT_QUINT16
Quantized uint16
DT_QUINT16 = 16; -
DT_UINT16
DT_UINT16 = 17; -
DT_COMPLEX128
Double-precision complex
DT_COMPLEX128 = 18; -
DT_HALF
DT_HALF = 19; -
DT_RESOURCE
DT_RESOURCE = 20; -
DT_VARIANT
Arbitrary C++ data types
DT_VARIANT = 21; -
DT_UINT32
DT_UINT32 = 22; -
DT_UINT64
DT_UINT64 = 23; -
DT_FLOAT8_E5M2
5 exponent bits, 2 mantissa bits.
DT_FLOAT8_E5M2 = 24; -
DT_FLOAT8_E4M3FN
4 exponent bits, 3 mantissa bits, finite-only, with
DT_FLOAT8_E4M3FN = 25; -
DT_INT4
2 NaNs (0bS1111111). TODO - b/299182407: Leaving room for remaining float8 types. DT_FLOAT8_E4M3FNUZ = 26; DT_FLOAT8_E4M3B11FNUZ = 27; DT_FLOAT8_E5M2FNUZ = 28;
DT_INT4 = 29; -
DT_UINT4
DT_UINT4 = 30; -
DT_FLOAT_REF
Do not use! These are only for TF1's obsolete reference Variables. Every enum above should have a corresponding value below (verified by types_test).
DT_FLOAT_REF = 101; -
DT_DOUBLE_REF
DT_DOUBLE_REF = 102; -
DT_INT32_REF
DT_INT32_REF = 103; -
DT_UINT8_REF
DT_UINT8_REF = 104; -
DT_INT16_REF
DT_INT16_REF = 105; -
DT_INT8_REF
DT_INT8_REF = 106; -
DT_STRING_REF
DT_STRING_REF = 107; -
DT_COMPLEX64_REF
DT_COMPLEX64_REF = 108; -
DT_INT64_REF
DT_INT64_REF = 109; -
DT_BOOL_REF
DT_BOOL_REF = 110; -
DT_QINT8_REF
DT_QINT8_REF = 111; -
DT_QUINT8_REF
DT_QUINT8_REF = 112; -
DT_QINT32_REF
DT_QINT32_REF = 113; -
DT_BFLOAT16_REF
DT_BFLOAT16_REF = 114; -
DT_QINT16_REF
DT_QINT16_REF = 115; -
DT_QUINT16_REF
DT_QUINT16_REF = 116; -
DT_UINT16_REF
DT_UINT16_REF = 117; -
DT_COMPLEX128_REF
DT_COMPLEX128_REF = 118; -
DT_HALF_REF
DT_HALF_REF = 119; -
DT_RESOURCE_REF
DT_RESOURCE_REF = 120; -
DT_VARIANT_REF
DT_VARIANT_REF = 121; -
DT_UINT32_REF
DT_UINT32_REF = 122; -
DT_UINT64_REF
DT_UINT64_REF = 123; -
DT_FLOAT8_E5M2_REF
DT_FLOAT8_E5M2_REF = 124; -
DT_FLOAT8_E4M3FN_REF
DT_FLOAT8_E4M3FN_REF = 125; -
DT_INT4_REF
TODO - b/299182407: Leaving room for remaining float8 types. DT_FLOAT8_E4M3FNUZ_REF = 126; DT_FLOAT8_E4M3B11FNUZ_REF = 127; DT_FLOAT8_E5M2FNUZ_REF = 128;
DT_INT4_REF = 129; -
DT_UINT4_REF
DT_UINT4_REF = 130; -
UNRECOGNIZED
-
-
Field Details
-
DT_INVALID_VALUE
public static final int DT_INVALID_VALUENot a legal value for DataType. Used to indicate a DataType field has not been set.
DT_INVALID = 0;- See Also:
-
DT_FLOAT_VALUE
public static final int DT_FLOAT_VALUEData types that all computation devices are expected to be capable to support.
DT_FLOAT = 1;- See Also:
-
DT_DOUBLE_VALUE
public static final int DT_DOUBLE_VALUEDT_DOUBLE = 2;- See Also:
-
DT_INT32_VALUE
public static final int DT_INT32_VALUEDT_INT32 = 3;- See Also:
-
DT_UINT8_VALUE
public static final int DT_UINT8_VALUEDT_UINT8 = 4;- See Also:
-
DT_INT16_VALUE
public static final int DT_INT16_VALUEDT_INT16 = 5;- See Also:
-
DT_INT8_VALUE
public static final int DT_INT8_VALUEDT_INT8 = 6;- See Also:
-
DT_STRING_VALUE
public static final int DT_STRING_VALUEDT_STRING = 7;- See Also:
-
DT_COMPLEX64_VALUE
public static final int DT_COMPLEX64_VALUESingle-precision complex
DT_COMPLEX64 = 8;- See Also:
-
DT_INT64_VALUE
public static final int DT_INT64_VALUEDT_INT64 = 9;- See Also:
-
DT_BOOL_VALUE
public static final int DT_BOOL_VALUEDT_BOOL = 10;- See Also:
-
DT_QINT8_VALUE
public static final int DT_QINT8_VALUEQuantized int8
DT_QINT8 = 11;- See Also:
-
DT_QUINT8_VALUE
public static final int DT_QUINT8_VALUEQuantized uint8
DT_QUINT8 = 12;- See Also:
-
DT_QINT32_VALUE
public static final int DT_QINT32_VALUEQuantized int32
DT_QINT32 = 13;- See Also:
-
DT_BFLOAT16_VALUE
public static final int DT_BFLOAT16_VALUEFloat32 truncated to 16 bits.
DT_BFLOAT16 = 14;- See Also:
-
DT_QINT16_VALUE
public static final int DT_QINT16_VALUEQuantized int16
DT_QINT16 = 15;- See Also:
-
DT_QUINT16_VALUE
public static final int DT_QUINT16_VALUEQuantized uint16
DT_QUINT16 = 16;- See Also:
-
DT_UINT16_VALUE
public static final int DT_UINT16_VALUEDT_UINT16 = 17;- See Also:
-
DT_COMPLEX128_VALUE
public static final int DT_COMPLEX128_VALUEDouble-precision complex
DT_COMPLEX128 = 18;- See Also:
-
DT_HALF_VALUE
public static final int DT_HALF_VALUEDT_HALF = 19;- See Also:
-
DT_RESOURCE_VALUE
public static final int DT_RESOURCE_VALUEDT_RESOURCE = 20;- See Also:
-
DT_VARIANT_VALUE
public static final int DT_VARIANT_VALUEArbitrary C++ data types
DT_VARIANT = 21;- See Also:
-
DT_UINT32_VALUE
public static final int DT_UINT32_VALUEDT_UINT32 = 22;- See Also:
-
DT_UINT64_VALUE
public static final int DT_UINT64_VALUEDT_UINT64 = 23;- See Also:
-
DT_FLOAT8_E5M2_VALUE
public static final int DT_FLOAT8_E5M2_VALUE5 exponent bits, 2 mantissa bits.
DT_FLOAT8_E5M2 = 24;- See Also:
-
DT_FLOAT8_E4M3FN_VALUE
public static final int DT_FLOAT8_E4M3FN_VALUE4 exponent bits, 3 mantissa bits, finite-only, with
DT_FLOAT8_E4M3FN = 25;- See Also:
-
DT_INT4_VALUE
public static final int DT_INT4_VALUE2 NaNs (0bS1111111). TODO - b/299182407: Leaving room for remaining float8 types. DT_FLOAT8_E4M3FNUZ = 26; DT_FLOAT8_E4M3B11FNUZ = 27; DT_FLOAT8_E5M2FNUZ = 28;
DT_INT4 = 29;- See Also:
-
DT_UINT4_VALUE
public static final int DT_UINT4_VALUEDT_UINT4 = 30;- See Also:
-
DT_FLOAT_REF_VALUE
public static final int DT_FLOAT_REF_VALUEDo not use! These are only for TF1's obsolete reference Variables. Every enum above should have a corresponding value below (verified by types_test).
DT_FLOAT_REF = 101;- See Also:
-
DT_DOUBLE_REF_VALUE
public static final int DT_DOUBLE_REF_VALUEDT_DOUBLE_REF = 102;- See Also:
-
DT_INT32_REF_VALUE
public static final int DT_INT32_REF_VALUEDT_INT32_REF = 103;- See Also:
-
DT_UINT8_REF_VALUE
public static final int DT_UINT8_REF_VALUEDT_UINT8_REF = 104;- See Also:
-
DT_INT16_REF_VALUE
public static final int DT_INT16_REF_VALUEDT_INT16_REF = 105;- See Also:
-
DT_INT8_REF_VALUE
public static final int DT_INT8_REF_VALUEDT_INT8_REF = 106;- See Also:
-
DT_STRING_REF_VALUE
public static final int DT_STRING_REF_VALUEDT_STRING_REF = 107;- See Also:
-
DT_COMPLEX64_REF_VALUE
public static final int DT_COMPLEX64_REF_VALUEDT_COMPLEX64_REF = 108;- See Also:
-
DT_INT64_REF_VALUE
public static final int DT_INT64_REF_VALUEDT_INT64_REF = 109;- See Also:
-
DT_BOOL_REF_VALUE
public static final int DT_BOOL_REF_VALUEDT_BOOL_REF = 110;- See Also:
-
DT_QINT8_REF_VALUE
public static final int DT_QINT8_REF_VALUEDT_QINT8_REF = 111;- See Also:
-
DT_QUINT8_REF_VALUE
public static final int DT_QUINT8_REF_VALUEDT_QUINT8_REF = 112;- See Also:
-
DT_QINT32_REF_VALUE
public static final int DT_QINT32_REF_VALUEDT_QINT32_REF = 113;- See Also:
-
DT_BFLOAT16_REF_VALUE
public static final int DT_BFLOAT16_REF_VALUEDT_BFLOAT16_REF = 114;- See Also:
-
DT_QINT16_REF_VALUE
public static final int DT_QINT16_REF_VALUEDT_QINT16_REF = 115;- See Also:
-
DT_QUINT16_REF_VALUE
public static final int DT_QUINT16_REF_VALUEDT_QUINT16_REF = 116;- See Also:
-
DT_UINT16_REF_VALUE
public static final int DT_UINT16_REF_VALUEDT_UINT16_REF = 117;- See Also:
-
DT_COMPLEX128_REF_VALUE
public static final int DT_COMPLEX128_REF_VALUEDT_COMPLEX128_REF = 118;- See Also:
-
DT_HALF_REF_VALUE
public static final int DT_HALF_REF_VALUEDT_HALF_REF = 119;- See Also:
-
DT_RESOURCE_REF_VALUE
public static final int DT_RESOURCE_REF_VALUEDT_RESOURCE_REF = 120;- See Also:
-
DT_VARIANT_REF_VALUE
public static final int DT_VARIANT_REF_VALUEDT_VARIANT_REF = 121;- See Also:
-
DT_UINT32_REF_VALUE
public static final int DT_UINT32_REF_VALUEDT_UINT32_REF = 122;- See Also:
-
DT_UINT64_REF_VALUE
public static final int DT_UINT64_REF_VALUEDT_UINT64_REF = 123;- See Also:
-
DT_FLOAT8_E5M2_REF_VALUE
public static final int DT_FLOAT8_E5M2_REF_VALUEDT_FLOAT8_E5M2_REF = 124;- See Also:
-
DT_FLOAT8_E4M3FN_REF_VALUE
public static final int DT_FLOAT8_E4M3FN_REF_VALUEDT_FLOAT8_E4M3FN_REF = 125;- See Also:
-
DT_INT4_REF_VALUE
public static final int DT_INT4_REF_VALUETODO - b/299182407: Leaving room for remaining float8 types. DT_FLOAT8_E4M3FNUZ_REF = 126; DT_FLOAT8_E4M3B11FNUZ_REF = 127; DT_FLOAT8_E5M2FNUZ_REF = 128;
DT_INT4_REF = 129;- See Also:
-
DT_UINT4_REF_VALUE
public static final int DT_UINT4_REF_VALUEDT_UINT4_REF = 130;- See Also:
-
-
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
-
getNumber
public final int getNumber()- Specified by:
getNumberin interfacecom.google.protobuf.Internal.EnumLite- Specified by:
getNumberin interfacecom.google.protobuf.ProtocolMessageEnum
-
valueOf
Deprecated.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:
value- 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
-
forNumber
- Parameters:
value- The numeric wire value of the corresponding enum entry.- Returns:
- The enum associated with the given numeric wire value.
-
internalGetValueMap
-
getValueDescriptor
public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor()- Specified by:
getValueDescriptorin interfacecom.google.protobuf.ProtocolMessageEnum
-
getDescriptorForType
public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.ProtocolMessageEnum
-
getDescriptor
public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() -
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:
desc- 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
-