25 #ifndef TVM_RELAY_ATTRS_BITSERIAL_H_ 26 #define TVM_RELAY_ATTRS_BITSERIAL_H_ 45 TVM_ATTR_FIELD(bits).set_default(1).describe(
"Number of bits to quantize with.");
47 "Axis that should be compressed, typically channels.");
48 TVM_ATTR_FIELD(bit_axis).set_default(-1).describe(
"New axis for packed bits.");
51 .describe(
"Type of int to pack bits into.");
52 TVM_ATTR_FIELD(name).set_default(
"BitPack").describe(
"Name of operation.");
73 .describe(
"Specifies the strides of the convolution.");
77 "If padding is non-zero the input is implicitly zero-padded" 78 "on both sides for padding number of points.");
81 .describe(
"Specifies the dimensions of the convolution window.");
83 .set_default(NullValue<IndexExpr>())
84 .describe(
"Number of output channels, needed for shape inference.");
87 .describe(
"Number of bits activation should be packed with.");
90 .describe(
"Number of bits kernel should be packed with.");
93 .describe(
"Dimension ordering of input data, can be 'NCHW' or NHWC'.");
96 .describe(
"Dimension ordering of kernel data, can be 'OIHW' or HWIO'.");
99 .describe(
"Datatype to pack bits into.");
102 "Whether to use unipolar or bipolar quantization.");
116 TVM_ATTR_FIELD(units).describe(
"Number of hidden units of the dense transformation.");
118 "Number of bits to pack for incoming tensor.");
121 .describe(
"Number of bits to pack for weight tensor.");
124 .describe(
"Datatype to pack bits into before computation.");
127 "Whether to use unipolar or bipolar quantization for inputs.");
133 #endif // TVM_RELAY_ATTRS_BITSERIAL_H_ DataType pack_dtype
Definition: bitserial.h:111
DataType out_dtype
Definition: bitserial.h:112
bool unipolar
Definition: bitserial.h:113
Array< IndexExpr > padding
Definition: bitserial.h:59
std::string kernel_layout
Definition: bitserial.h:65
runtime implementation for LibTorch/TorchScript.
Definition: analyzer.h:36
IndexExpr units
Definition: bitserial.h:108
Array< IndexExpr > kernel_size
Definition: bitserial.h:61
DataType pack_dtype
Definition: bitserial.h:66
IndexExpr channels
Definition: bitserial.h:60
int activation_bits
Definition: bitserial.h:62
std::string data_layout
Definition: bitserial.h:64
Helpers for attribute objects.
int bits
Definition: bitserial.h:38
Runtime primitive data type.
Definition: data_type.h:41
DataType pack_type
Definition: bitserial.h:41
Definition: bitserial.h:107
Array, container representing a contiguous sequence of ObjectRefs.
Definition: array.h:289
Attributes used in bitpack operators.
Definition: bitserial.h:37
std::string name
Definition: bitserial.h:42
#define TVM_ATTR_FIELD(FieldName)
Declare an attribute field.
Definition: attrs.h:76
int pack_axis
Definition: bitserial.h:39
TVM_DECLARE_ATTRS(BinaryDenseAttrs, "relay.attrs.BinaryDenseAttrs")
Definition: bitserial.h:115
DataType NullValue< DataType >()
Definition: attrs.h:90
int weight_bits
Definition: bitserial.h:63
The base class of the all the Use "curiously recurring template pattern".
Definition: attrs.h:834
TVM_DECLARE_ATTRS(BitPackAttrs, "relay.attrs.BitPackAttrs")
Definition: bitserial.h:44
int weight_bits
Definition: bitserial.h:110
Base classes for the Relay IR.
int data_bits
Definition: bitserial.h:109
Reference to PrimExprNode.
Definition: expr.h:114
TVM_DECLARE_ATTRS(BinaryConv2DAttrs, "relay.attrs.BinaryConv2DAttrs")
Definition: bitserial.h:70
DataType out_dtype
Definition: bitserial.h:67
bool unipolar
Definition: bitserial.h:68
Array< IndexExpr > strides
Definition: bitserial.h:58
Attribues used in bitserial convolution operators.
Definition: bitserial.h:57
int bit_axis
Definition: bitserial.h:40