cavis/.old/contrib/codegen-tools/onnx-def-gen/onnx.pbtxt

6005 lines
208 KiB
Plaintext
Raw Normal View History

input: "X"
output: "Y"
name: "Abs"
op_type: "Abs"
attribute {
name: "X-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nAbsolute takes one input data (Tensor<T>) and produces one output data\n(Tensor<T>) where the absolute is, y = abs(x), is applied to\nthe tensor elementwise.\n"
----f
input: "input"
output: "output"
name: "Acos"
op_type: "Acos"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the arccosine (inverse of cosine) of the given input tensor, element-wise.\n"
----f
input: "input"
output: "output"
name: "Acosh"
op_type: "Acosh"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the hyperbolic arccosine of the given input tensor element-wise.\n"
----f
input: "R"
input: "T"
input: "inputs"
output: "outputs"
name: "Adagrad"
op_type: "Adagrad"
attribute {
name: "decay_factor"
f: 0.0
type: FLOAT
}
attribute {
name: "epsilon"
f: 1e-06
type: FLOAT
}
attribute {
name: "norm_coefficient"
f: 0.0
type: FLOAT
}
attribute {
name: "R-types"
strings: "float"
strings: "double"
type: STRINGS
}
attribute {
name: "T-types"
strings: "int64"
type: STRINGS
}
attribute {
name: "inputs-types"
strings: "float"
strings: "double"
type: STRINGS
}
doc_string: "\n Compute one iteration of ADAGRAD, a stochastic gradient based optimization\n algorithm. This operator can conduct the optimization of multiple tensor variables.\n\n Let\'s define the behavior of this operator. As you can imagine, ADAGRAD requires\n some parameters:\n \n - The initial learning-rate \"R\".\n - The update count \"T\". That is, the number of training iterations conducted.\n - A L2-norm regularization coefficient \"norm_coefficient\".\n - A learning-rate decay factor \"decay_factor\".\n - A small constant \"epsilon\" to avoid dividing-by-zero. \n\n At each ADAGRAD iteration, the optimized tensors are moved along a direction\n computed based on their estimated gradient and accumulated squared gradient. Assume\n that only a single tensor \"X\" is updated by this operator. We need the value of \"X\",\n its gradient \"G\", and its accumulated squared gradient \"H\". Therefore, variables in\n this operator\'s input list are sequentially \"R\", \"T\", \"X\", \"G\", and \"H\". Other\n parameters are given as attributes because they are usually constants. Also, the\n corresponding output tensors are the new value of \"X\" (called \"X_new\"), and then\n the new accumulated squared gradient (called \"H_new\"). Those outputs are computed\n from the given inputs following the pseudo code below.\n\n Let \"+\", \"-\", \"*\", and \"/\" are all element-wise arithmetic operations with\n numpy-style broadcasting support. The pseudo code to compute those outputs is:\n\n // Compute a scalar learning-rate factor. At the first update of X, T is generally\n // 0 (0-based update index) or 1 (1-based update index).\n r = R / (1 + T * decay_factor);\n\n // Add gradient of 0.5 * norm_coefficient * ||X||_2^2, where ||X||_2 is the 2-norm.\n G_regularized = norm_coefficient * X + G;\n\n // Compute new accumulated squared gradient.\n H_new = H + G_regularized * G_regularized;\n\n // Compute the adaptive part of per-coordinate learning rate. Note that Sqrt(...)\n // computes element-wise square-root.\n H_adaptive = Sqrt(H_new) + epsilon\n\n // Compute the new value of \"X\".\n X_new = X - r * G_regularized / H_adaptive;\n\n If one assign this operators to optimize multiple inputs, for example, \"X_1\" and \"X_2\", the same\n pseudo code may be extended to handle all tensors jointly. More specifically, we can view \"X\" as a\n concatenation of \"X_1\" and \"X_2\" (of course, their gradient and accumulate gradient should\n be concatenated too) and then just reuse the entire pseudo code.\n\n Note that ADAGRAD was first proposed in http://jmlr.org/papers/volume12/duchi11a/duchi11a.pdf.\n In that reference paper, this operator is a special case of the Figure 1\'s composite mirror\n descent update.\n"
----f
input: "R"
input: "T"
input: "inputs"
output: "outputs"
name: "Adam"
op_type: "Adam"
attribute {
name: "alpha"
f: 0.9
type: FLOAT
}
attribute {
name: "beta"
f: 0.999
type: FLOAT
}
attribute {
name: "epsilon"
f: 1e-06
type: FLOAT
}
attribute {
name: "norm_coefficient"
f: 0.0
type: FLOAT
}
attribute {
name: "norm_coefficient_post"
f: 0.0
type: FLOAT
}
attribute {
name: "R-types"
strings: "float"
strings: "double"
type: STRINGS
}
attribute {
name: "T-types"
strings: "int64"
type: STRINGS
}
attribute {
name: "inputs-types"
strings: "float"
strings: "double"
type: STRINGS
}
doc_string: "\n Compute one iteration of Adam, a stochastic gradient based optimization\n algorithm. This operator can conduct the optimization of multiple tensor variables.\n\n Let\'s define the behavior of this operator. First of all, Adam requires\n some parameters:\n \n - The learning-rate \"R\".\n - The update count \"T\". That is, the number of training iterations conducted.\n - A L2-norm regularization coefficient \"norm_coefficient\".\n - A small constant \"epsilon\" to avoid dividing-by-zero. \n - Two coefficients, \"alpha\" and \"beta\".\n\n At each Adam iteration, the optimized tensors are moved along a direction\n computed based on their exponentially-averaged historical gradient and\n exponentially-averaged historical squared gradient. Assume that only a tensor\n \"X\" is being optimized. The rest of required information is\n \n - the value of \"X\",\n - \"X\"\'s gradient (denoted by \"G\"),\n - \"X\"\'s exponentially-averaged historical gradient (denoted by \"V\"), and\n - \"X\"\'s exponentially-averaged historical squared gradient (denoted by \"H\").\n\n Some of those parameters are passed into this operator as input tensors and others\n are stored as this operator\'s attributes. Specifically, this operator\'s input tensor\n list is [\"R\", \"T\", \"X\", \"G\", \"V\", \"H\"]. That is, \"R\" is the first input, \"T\" is\n the second input, and so on. Other parameters are given as attributes because they\n are constants. Moreover, the corresponding output tensors are \n \n - the new value of \"X\" (called \"X_new\"),\n - the new exponentially-averaged historical gradient (denoted by \"V_new\"), and\n - the new exponentially-averaged historical squared gradient (denoted by \"H_new\").\n\n Those outputs are computed following the pseudo code below.\n\n Let \"+\", \"-\", \"*\", and \"/\" are all element-wise arithmetic operations with\n numpy-style broadcasting support. The pseudo code to compute those outputs is:\n\n // Add gradient of 0.5 * norm_coefficient * ||X||_2^2, where ||X||_2 is the 2-norm.\n G_regularized = norm_coefficient * X + G\n\n // Update exponentially-averaged historical gradient.\n V_new = alpha * V + (1 - alpha) * G_regularized\n\n // Update exponentially-averaged historical squared gradient.\n H_new = beta * H + (1 - beta) * G_regularized * G_regularized\n\n // Compute the element-wise square-root of H_new. V_new will be element-wisely\n // divided by H_sqrt for a better update direction.\n H_sqrt = Sqrt(H_new) + epsilon\n\n // Compute learning-rate. Note that \"alpha**T\"/\"beta**T\" is alpha\'s/beta\'s T-th power.\n R_adjusted = T > 0 ? R * Sqrt(1 - beta**T) / (1 - alpha**T) : R\n\n // Compute new value of \"X\".\n X_new = X - R_adjusted * V_new / H_sqrt\n\n // Post-update regularization.\n X_final = (1 - norm_coefficient_post) * X_new \n\n If there are multiple inputs to be optimized, the pseudo code will be applied\n independently to each of them.\n"
----f
input: "A"
input: "B"
output: "C"
name: "Add"
op_type: "Add"
attribute {
name: "A-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
attribute {
name: "B-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nPerforms element-wise binary addition (with Numpy-style broadcasting support).\n\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "A"
input: "B"
output: "C"
name: "And"
op_type: "And"
attribute {
name: "A-types"
strings: "bool"
type: STRINGS
}
attribute {
name: "B-types"
strings: "bool"
type: STRINGS
}
doc_string: "\nReturns the tensor resulted from performing the `and` logical operation\nelementwise on the input tensors `A` and `B` (with Numpy-style broadcasting support).\n\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "data"
output: "reduced"
name: "ArgMax"
op_type: "ArgMax"
attribute {
name: "axis"
i: 0
type: INT
}
attribute {
name: "keepdims"
i: 1
type: INT
}
attribute {
name: "select_last_index"
i: 0
type: INT
}
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nComputes the indices of the max elements of the input tensor\'s element along the \nprovided axis. The resulting tensor has the same rank as the input if keepdims equal 1. \nIf keepdims equal 0, then the resulting tensor have the reduced dimension pruned. \nIf select_last_index is True (default False), the index of the last occurrence of the max \nis selected if the max appears more than once in the input. Otherwise the index of the \nfirst occurrence is selected.\nThe type of the output tensor is integer."
----f
input: "data"
output: "reduced"
name: "ArgMin"
op_type: "ArgMin"
attribute {
name: "axis"
i: 0
type: INT
}
attribute {
name: "keepdims"
i: 1
type: INT
}
attribute {
name: "select_last_index"
i: 0
type: INT
}
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nComputes the indices of the min elements of the input tensor\'s element along the \nprovided axis. The resulting tensor has the same rank as the input if keepdims equal 1. \nIf keepdims equal 0, then the resulting tensor have the reduced dimension pruned. \nIf select_last_index is True (default False), the index of the last occurrence of the min \nis selected if the min appears more than once in the input. Otherwise the index of the \nfirst occurrence is selected.\nThe type of the output tensor is integer."
----f
input: "X"
input: "Y"
output: "Z"
name: "ArrayFeatureExtractor"
op_type: "ArrayFeatureExtractor"
attribute {
name: "X-types"
strings: "int32"
strings: "string"
strings: "double"
strings: "int64"
strings: "float"
type: STRINGS
}
attribute {
name: "Y-types"
strings: "int64"
type: STRINGS
}
doc_string: "\n Select elements of the input tensor based on the indices passed.<br>\n The indices are applied to the last axes of the tensor.\n"
----f
input: "input"
output: "output"
name: "Asin"
op_type: "Asin"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the arcsine (inverse of sine) of the given input tensor, element-wise.\n"
----f
input: "input"
output: "output"
name: "Asinh"
op_type: "Asinh"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the hyperbolic arcsine of the given input tensor element-wise.\n"
----f
input: "input"
output: "output"
name: "Atan"
op_type: "Atan"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the arctangent (inverse of tangent) of the given input tensor, element-wise.\n"
----f
input: "input"
output: "output"
name: "Atanh"
op_type: "Atanh"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the hyperbolic arctangent of the given input tensor element-wise.\n"
----f
input: "X"
output: "Y"
name: "AveragePool"
op_type: "AveragePool"
attribute {
name: "auto_pad"
s: "NOTSET"
type: STRING
}
attribute {
name: "ceil_mode"
i: 0
type: INT
}
attribute {
name: "count_include_pad"
i: 0
type: INT
}
attribute {
name: "kernel_shape"
s: ""
type: INTS
}
attribute {
name: "pads"
s: ""
type: INTS
}
attribute {
name: "strides"
s: ""
type: INTS
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\n AveragePool consumes an input tensor X and applies average pooling across\n the tensor according to kernel sizes, stride sizes, and pad lengths.\n average pooling consisting of computing the average on all values of a\n subset of the input tensor according to the kernel size and downsampling the\n data into the output tensor Y for further processing. The output spatial shape will be following:\n ```\n output_spatial_shape[i] = floor((input_spatial_shape[i] + pad_shape[i] - kernel_spatial_shape[i]) / strides_spatial_shape[i] + 1)\n ```\n or\n ```\n output_spatial_shape[i] = ceil((input_spatial_shape[i] + pad_shape[i] - kernel_spatial_shape[i]) / strides_spatial_shape[i] + 1)\n ```\n if ceil_mode is enabled\n\n ```\n * pad_shape[i] is sum of pads along axis i\n ```\n\n `auto_pad` is a DEPRECATED attribute. If you are using them currently, the output spatial shape will be following:\n ```\n VALID: output_spatial_shape[i] = ceil((input_spatial_shape[i] - kernel_spatial_shape[i] + 1) / strides_spatial_shape[i])\n SAME_UPPER or SAME_LOWER: output_spatial_shape[i] = ceil(input_spatial_shape[i] / strides_spatial_shape[i])\n ```\n And pad shape will be following if `SAME_UPPER` or `SAME_LOWER`:\n ```\n pad_shape[i] = (output_spatial_shape[i] - 1) * strides_spatial_shape[i] + kernel_spatial_shape[i] - input_spatial_shape[i]\n ```\n The output of each pooling window is divided by the number of elements (exclude pad when attribute count_include_pad is zero).\n "
----f
input: "X"
input: "scale"
input: "B"
input: "mean"
input: "var"
output: "Y"
output: "mean"
output: "var"
output: "saved_mean"
output: "saved_var"
name: "BatchNormalization"
op_type: "BatchNormalization"
attribute {
name: "epsilon"
f: 1e-05
type: FLOAT
}
attribute {
name: "momentum"
f: 0.9
type: FLOAT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "scale-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "B-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "mean-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "var-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCarries out batch normalization as described in the paper\nhttps://arxiv.org/abs/1502.03167. Depending on the mode it is being run,\nthere are multiple cases for the number of outputs, which we list below:\n\nOutput case #1: Y, mean, var, saved_mean, saved_var (training mode)\nOutput case #2: Y (test mode)\n\nFor previous (depreciated) non-spatial cases, implementors are suggested\nto flatten the input shape to (N x C*D1*D2 ..*Dn) before a BatchNormalization Op.\nThis operator has **optional** inputs/outputs. See [the doc](IR.md) for more details about the representation of optional arguments. An empty string may be used in the place of an actual argument\'s name to indicate a missing argument. Trailing optional arguments (those not followed by an argument that is present) may also be simply omitted.\n"
----f
input: "X"
output: "Y"
name: "Binarizer"
op_type: "Binarizer"
attribute {
name: "threshold"
f: 0.0
type: FLOAT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\n Maps the values of the input tensor to either 0 or 1, element-wise, based on the outcome of a comparison against a threshold value.\n"
----f
input: "X"
input: "Y"
output: "Z"
name: "BitShift"
op_type: "BitShift"
attribute {
name: "direction"
s: ""
type: STRING
}
attribute {
name: "X-types"
strings: "uint32"
strings: "uint16"
strings: "uint8"
strings: "uint64"
type: STRINGS
}
attribute {
name: "Y-types"
strings: "uint32"
strings: "uint16"
strings: "uint8"
strings: "uint64"
type: STRINGS
}
doc_string: "\nBitwise shift operator performs element-wise operation. For each input element, if the\n attribute \"direction\" is \"RIGHT\", this operator moves its binary representation toward\n the right side so that the input value is effectively decreased. If the attribute \"direction\"\n is \"LEFT\", bits of binary representation moves toward the left side, which results the\n increase of its actual value. The input X is the tensor to be shifted and another input\n Y specifies the amounts of shifting. For example, if \"direction\" is \"Right\", X is [1, 4],\n and S is [1, 1], the corresponding output Z would be [0, 2]. If \"direction\" is \"LEFT\" with\n X=[1, 2] and S=[1, 2], the corresponding output Y would be [2, 8].\n \n Because this operator supports Numpy-style broadcasting, X\'s and Y\'s shapes are\n not necessarily identical.\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md)."
----f
input: "input"
output: "output"
name: "Cast"
op_type: "Cast"
attribute {
name: "to"
s: ""
type: INT
}
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "float16"
strings: "int32"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nThe operator casts the elements of a given input tensor to a data type\nspecified by the \'to\' argument and returns an output tensor of the same size in\nthe converted type. The \'to\' argument must be one of the data types specified\nin the \'DataType\' enum field in the TensorProto message.\n\nCasting from string tensor in plain (e.g., \"3.14\" and \"1000\") and scientific numeric representations\n(e.g., \"1e-5\" and \"1E8\") to float types is supported. For example, converting string \"100.5\" to an integer may\nresult 100. There are some string literals reserved for special floating-point values;\n\"+INF\" (and \"INF\"), \"-INF\", and \"NaN\" are positive infinity, negative infinity, and not-a-number, respectively.\nAny string which can exactly match \"+INF\" in a case-insensitive way would be mapped to positive infinite. Similarly,\nthis case-insensitive rule is applied to \"INF\" and \"NaN\". When casting from numeric tensors\nto string tensors, plain floating-point representation (such as \"314.15926\") would be used. \nConverting non-numerical-literal string such as \"Hello World!\" is an undefined behavior. Cases \nof converting string representing floating-point arithmetic value, such as \"2.718\", to INT is an undefined behavior.\n\nConversion from a numerical type to any numerical type is always allowed.\nUser must be aware of precision loss and value change caused by range difference between two types.\nFor example, a 64-bit float 3.1415926459 may be round to a 32-bit float 3.141592. Similarly, converting\nan integer 36 to Boolean may produce 1 because we truncate bits which can\'t be stored in the targeted type.\n"
----f
input: "X"
output: "Y"
name: "CastMap"
op_type: "CastMap"
attribute {
name: "cast_to"
s: "TO_FLOAT"
type: STRING
}
attribute {
name: "map_form"
s: "DENSE"
type: STRING
}
attribute {
name: "max_map"
i: 1
type: INT
}
attribute {
name: "X-types"
strings: "map(int64,string"
strings: "map(int64,float"
type: STRINGS
}
doc_string: "\n Converts a map to a tensor.<br>The map key must be an int64 and the values will be ordered\n in ascending order based on this key.<br>The operator supports dense packing or sparse packing.\n If using sparse packing, the key cannot exceed the max_map-1 value.\n"
----f
input: "X"
output: "Y"
name: "CategoryMapper"
op_type: "CategoryMapper"
attribute {
name: "cats_int64s"
s: ""
type: INTS
}
attribute {
name: "cats_strings"
s: ""
type: STRINGS
}
attribute {
name: "default_int64"
i: -1
type: INT
}
attribute {
name: "default_string"
s: "_Unused"
type: STRING
}
attribute {
name: "X-types"
strings: "string"
strings: "int64"
type: STRINGS
}
doc_string: "\n Converts strings to integers and vice versa.<br>\n Two sequences of equal length are used to map between integers and strings,\n with strings and integers at the same index detailing the mapping.<br>\n Each operator converts either integers to strings or strings to integers, depending \n on which default value attribute is provided. Only one default value attribute\n should be defined.<br>\n If the string default value is set, it will convert integers to strings.\n If the int default value is set, it will convert strings to integers.\n"
----f
input: "X"
output: "Y"
name: "Ceil"
op_type: "Ceil"
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCeil takes one input data (Tensor<T>) and produces one output data\n(Tensor<T>) where the ceil is, y = ceil(x), is applied to\nthe tensor elementwise.\n"
----f
input: "X"
output: "Y"
name: "Celu"
op_type: "Celu"
attribute {
name: "alpha"
f: 1.0
type: FLOAT
}
attribute {
name: "X-types"
strings: "float"
type: STRINGS
}
doc_string: "\nContinuously Differentiable Exponential Linear Units:\nPerform the linear unit element-wise on the input tensor X\nusing formula: \n\n```\nmax(0,x) + min(0,alpha*(exp(x/alpha)-1))\n```\n"
----f
input: "input"
input: "min"
input: "max"
output: "output"
name: "Clip"
op_type: "Clip"
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "min-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "max-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nClip operator limits the given input within an interval. The interval is\nspecified by the inputs \'min\' and \'max\'. They default to\nnumeric_limits::lowest() and numeric_limits::max(), respectively.\n"
----f
input: "input"
input: "condition"
output: "output"
name: "Compress"
op_type: "Compress"
attribute {
name: "axis"
s: ""
type: INT
}
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "condition-types"
strings: "bool"
type: STRINGS
}
doc_string: "\n Selects slices from an input tensor along a given axis where condition evaluates to True for each axis index.\n In case axis is not provided, input is flattened before elements are selected.\n Compress behaves like numpy.compress: https://docs.scipy.org/doc/numpy/reference/generated/numpy.compress.html\n "
----f
input: "inputs"
output: "concat_result"
name: "Concat"
op_type: "Concat"
attribute {
name: "axis"
s: ""
type: INT
}
attribute {
name: "inputs-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "Concatenate a list of tensors into a single tensor. All input tensors must have the same shape, except for the dimension size of the axis to concatenate on."
----f
input: "input_sequence"
output: "concat_result"
name: "ConcatFromSequence"
op_type: "ConcatFromSequence"
attribute {
name: "axis"
s: ""
type: INT
}
attribute {
name: "new_axis"
i: 0
type: INT
}
attribute {
name: "input_sequence-types"
strings: "seq(bool"
strings: "seq(complex128"
strings: "seq(string"
strings: "seq(float16"
strings: "seq(int64"
strings: "seq(float"
strings: "seq(int32"
strings: "seq(uint32"
strings: "seq(uint16"
strings: "seq(int8"
strings: "seq(int16"
strings: "seq(complex64"
strings: "seq(uint64"
strings: "seq(double"
strings: "seq(uint8"
type: STRINGS
}
doc_string: "\nConcatenate a sequence of tensors into a single tensor.\nAll input tensors must have the same shape, except for the dimension size of the axis to concatenate on.\nBy default \'new_axis\' is 0, the behavior is similar to numpy.concatenate.\nWhen \'new_axis\' is 1, the behavior is similar to numpy.stack.\n"
----f
output: "output"
name: "Constant"
op_type: "Constant"
attribute {
name: "sparse_value"
s: ""
type: SPARSE_TENSOR
}
attribute {
name: "value"
s: ""
type: TENSOR
}
attribute {
name: "value_float"
s: ""
type: FLOAT
}
attribute {
name: "value_floats"
s: ""
type: FLOATS
}
attribute {
name: "value_int"
s: ""
type: INT
}
attribute {
name: "value_ints"
s: ""
type: INTS
}
attribute {
name: "value_string"
s: ""
type: STRING
}
attribute {
name: "value_strings"
s: ""
type: STRINGS
}
doc_string: "\nThis operator produces a constant tensor. Exactly one of the provided attributes, either value, sparse_value,\nor value_* must be specified.\n"
----f
input: "input"
output: "output"
name: "ConstantOfShape"
op_type: "ConstantOfShape"
attribute {
name: "value"
s: ""
type: TENSOR
}
attribute {
name: "input-types"
strings: "int64"
type: STRINGS
}
doc_string: "\nGenerate a tensor with given value and shape.\n"
----f
input: "X"
input: "W"
input: "B"
output: "Y"
name: "Conv"
op_type: "Conv"
attribute {
name: "auto_pad"
s: "NOTSET"
type: STRING
}
attribute {
name: "dilations"
s: ""
type: INTS
}
attribute {
name: "group"
i: 1
type: INT
}
attribute {
name: "kernel_shape"
s: ""
type: INTS
}
attribute {
name: "pads"
s: ""
type: INTS
}
attribute {
name: "strides"
s: ""
type: INTS
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "W-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "B-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nThe convolution operator consumes an input tensor and a filter, and\ncomputes the output."
----f
input: "x"
input: "w"
input: "x_zero_point"
input: "w_zero_point"
output: "y"
name: "ConvInteger"
op_type: "ConvInteger"
attribute {
name: "auto_pad"
s: "NOTSET"
type: STRING
}
attribute {
name: "dilations"
s: ""
type: INTS
}
attribute {
name: "group"
i: 1
type: INT
}
attribute {
name: "kernel_shape"
s: ""
type: INTS
}
attribute {
name: "pads"
s: ""
type: INTS
}
attribute {
name: "strides"
s: ""
type: INTS
}
attribute {
name: "x-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "w-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "x_zero_point-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "w_zero_point-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
doc_string: "\nThe integer convolution operator consumes an input tensor, its zero-point, a filter, and its zero-point,\nand computes the output. The production MUST never overflow. The accumulation may overflow if and only if in 32 bits.\n"
----f
input: "X"
input: "W"
input: "B"
output: "Y"
name: "ConvTranspose"
op_type: "ConvTranspose"
attribute {
name: "auto_pad"
s: "NOTSET"
type: STRING
}
attribute {
name: "dilations"
s: ""
type: INTS
}
attribute {
name: "group"
i: 1
type: INT
}
attribute {
name: "kernel_shape"
s: ""
type: INTS
}
attribute {
name: "output_padding"
s: ""
type: INTS
}
attribute {
name: "output_shape"
s: ""
type: INTS
}
attribute {
name: "pads"
s: ""
type: INTS
}
attribute {
name: "strides"
s: ""
type: INTS
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "W-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "B-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nThe convolution transpose operator consumes an input tensor and a filter,\nand computes the output.\n\nIf the pads parameter is provided the shape of the output is calculated via the following equation:\n\n output_shape[i] = stride[i] * (input_size[i] - 1) + output_padding[i] + ((kernel_shape[i] - 1) * dilations[i] + 1) - pads[start_i] - pads[end_i]\n\noutput_shape can also be explicitly specified in which case pads values are auto generated using these equations:\n\n total_padding[i] = stride[i] * (input_size[i] - 1) + output_padding[i] + ((kernel_shape[i] - 1) * dilations[i] + 1) - output_shape[i]\n If (auto_pads != SAME_UPPER): pads[start_i] = total_padding[i]/2; pads[end_i] = total_padding[i] - (total_padding[i]/2)\n Else: pads[start_i] = total_padding[i] - (total_padding[i]/2); pads[end_i] = (total_padding[i]/2).\n\n "
----f
input: "input"
output: "output"
name: "Cos"
op_type: "Cos"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the cosine of the given input tensor, element-wise.\n"
----f
input: "input"
output: "output"
name: "Cosh"
op_type: "Cosh"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the hyperbolic cosine of the given input tensor element-wise.\n"
----f
input: "x"
input: "axis"
output: "y"
name: "CumSum"
op_type: "CumSum"
attribute {
name: "exclusive"
i: 0
type: INT
}
attribute {
name: "reverse"
i: 0
type: INT
}
attribute {
name: "x-types"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
attribute {
name: "axis-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\nPerforms cumulative sum of the input elements along the given axis.\nBy default, it will do the sum inclusively meaning the first element is copied as is.\nThrough an `exclusive` attribute, this behavior can change to exclude the first element.\nIt can also perform summation in the opposite direction of the axis. For that, set `reverse` attribute to 1.\n\nExample:\n```\ninput_x = [1, 2, 3]\naxis=0\noutput = [1, 3, 6]\nexclusive=1\noutput = [0, 1, 3]\nexclusive=0\nreverse=1\noutput = [6, 5, 3]\nexclusive=1\nreverse=1\noutput = [5, 3, 0]\n```\n "
----f
input: "input"
output: "output"
name: "DepthToSpace"
op_type: "DepthToSpace"
attribute {
name: "blocksize"
s: ""
type: INT
}
attribute {
name: "mode"
s: "DCR"
type: STRING
}
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "DepthToSpace rearranges (permutes) data from depth into blocks of spatial data.\nThis is the reverse transformation of SpaceToDepth. More specifically, this op outputs a copy of\nthe input tensor where values from the depth dimension are moved in spatial blocks to the height\nand width dimensions. By default, `mode` = `DCR`.\nIn the DCR mode, elements along the depth dimension from the input tensor are rearranged in the\nfollowing order: depth, column, and then row. The output y is computed from the input x as below:\n\nb, c, h, w = x.shape\n\ntmp = np.reshape(x, [b, blocksize, blocksize, c // (blocksize**2), h, w])\n\ntmp = np.transpose(tmp, [0, 3, 4, 1, 5, 2])\n\ny = np.reshape(tmp, [b, c // (blocksize**2), h * blocksize, w * blocksize])\n\n\nIn the CRD mode, elements along the depth dimension from the input tensor are rearranged in the\nfollowing order: column, row, and the depth. The output y is computed from the input x as below:\n\nb, c, h, w = x.shape\n\ntmp = np.reshape(x, [b, c // (blocksize ** 2), blocksize, blocksize, h, w])\n\ntmp = np.transpose(tmp, [0, 1, 4, 2, 5, 3])\n\ny = np.reshape(tmp, [b, c // (blocksize ** 2), h * blocksize, w * blocksize])\n\n"
----f
input: "x"
input: "x_scale"
input: "x_zero_point"
output: "y"
name: "DequantizeLinear"
op_type: "DequantizeLinear"
attribute {
name: "x-types"
strings: "int32"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "x_scale-types"
strings: "float"
type: STRINGS
}
attribute {
name: "x_zero_point-types"
strings: "int32"
strings: "int8"
strings: "uint8"
type: STRINGS
}
doc_string: "\nThe linear dequantization operator. It consumes a quantized tensor, a scale, a zero point to compute the full precision tensor.\nThe dequantization formula is y = (x - x_zero_point) * x_scale. \'x_scale\' and \'x_zero_point\' must have same shape.\n\'x_zero_point\' and \'x\' must have same type. \'x\' and \'y\' must have same shape. In the case of dequantizing int32,\nthere\'s no zero point (zero point is supposed to be 0).\n"
----f
input: "X"
output: "Y"
name: "Det"
op_type: "Det"
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nDet calculates determinant of a square matrix or batches of square matrices.\nDet takes one input tensor of shape `[*, M, M]`, where `*` is zero or more batch dimensions,\nand the inner-most 2 dimensions form square matrices.\nThe output is a tensor of shape `[*]`, containing the determinants of all input submatrices.\ne.g., When the input is 2-D, the output is a scalar(shape is empty: `[]`).\n"
----f
input: "X"
output: "Y"
name: "DictVectorizer"
op_type: "DictVectorizer"
attribute {
name: "int64_vocabulary"
s: ""
type: INTS
}
attribute {
name: "string_vocabulary"
s: ""
type: STRINGS
}
attribute {
name: "X-types"
strings: "map(int64,float"
strings: "map(int64,string"
strings: "map(string,int64"
strings: "map(string,float"
strings: "map(string,double"
strings: "map(int64,double"
type: STRINGS
}
doc_string: "\n Uses an index mapping to convert a dictionary to an array.<br>\n Given a dictionary, each key is looked up in the vocabulary attribute corresponding to\n the key type. The index into the vocabulary array at which the key is found is then\n used to index the output 1-D tensor \'Y\' and insert into it the value found in the dictionary \'X\'.<br>\n The key type of the input map must correspond to the element type of the defined vocabulary attribute.\n Therefore, the output array will be equal in length to the index mapping vector parameter.\n All keys in the input dictionary must be present in the index mapping vector.\n For each item in the input dictionary, insert its value in the output array.\n Any keys not present in the input dictionary, will be zero in the output array.<br>\n For example: if the ``string_vocabulary`` parameter is set to ``[\"a\", \"c\", \"b\", \"z\"]``,\n then an input of ``{\"a\": 4, \"c\": 8}`` will produce an output of ``[4, 8, 0, 0]``.\n "
----f
input: "A"
input: "B"
output: "C"
name: "Div"
op_type: "Div"
attribute {
name: "A-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
attribute {
name: "B-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nPerforms element-wise binary division (with Numpy-style broadcasting support).\n\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "data"
input: "ratio"
input: "training_mode"
output: "output"
output: "mask"
name: "Dropout"
op_type: "Dropout"
attribute {
name: "seed"
s: ""
type: INT
}
attribute {
name: "data-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "ratio-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "training_mode-types"
strings: "bool"
type: STRINGS
}
doc_string: "\nDropout takes an input floating-point tensor, an optional input ratio (floating-point scalar) and an optional input training_mode (boolean scalar). It produces two tensor outputs,\noutput (floating-point tensor) and mask (optional `Tensor<bool>`). If `training_mode` is true then the output Y will be a random dropout;\nNote that this Dropout scales the masked input data by the following equation, so to convert the trained model into inference mode,\nthe user can simply not pass `training_mode` input or set it to false.\n```\noutput = scale * data * mask,\n```\nwhere\n```\nscale = 1. / (1. - ratio).\n```\nThis operator has **optional** inputs/outputs. See [the doc](IR.md) for more details about the representation of optional arguments. An empty string may be used in the place of an actual argument\'s name to indicate a missing argument. Trailing optional arguments (those not followed by an argument that is present) may also be simply omitted.\n"
----f
input: "x"
output: "y"
output: "y_scale"
output: "y_zero_point"
name: "DynamicQuantizeLinear"
op_type: "DynamicQuantizeLinear"
attribute {
name: "x-types"
strings: "float"
type: STRINGS
}
doc_string: "\nA Function to fuse calculation for Scale, Zero Point and FP32->8Bit convertion of FP32 Input data.\nOutputs Scale, ZeroPoint and Quantized Input for a given FP32 Input.\nScale is calculated as:\n```\n y_scale = (max(x) - min(x))/(qmax - qmin)\n * where qmax and qmin are max and min values for quantization range .i.e [0, 255] in case of uint8\n * data range is adjusted to include 0.\n```\nZero point is calculated as:\n```\nintermediate_zero_point = qmin - min(x)/y_scale\ny_zero_point = cast(round(saturate(itermediate_zero_point)))\n* where qmax and qmin are max and min values for quantization range .i.e [0, 255] in case of uint8\n* for saturation, it saturates to [0, 255] if it\'s uint8, or [-127, 127] if it\'s int8. Right now only uint8 is supported.\n* rounding to nearest ties to even.\n```\nData quantization formula is:\n```\ny = saturate (round (x / y_scale) + y_zero_point)\n* for saturation, it saturates to [0, 255] if it\'s uint8, or [-127, 127] if it\'s int8. Right now only uint8 is supported.\n* rounding to nearest ties to even.\n```\n"
----f
input: "Inputs"
output: "Output"
name: "Einsum"
op_type: "Einsum"
attribute {
name: "equation"
s: ""
type: STRING
}
attribute {
name: "Inputs-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nAn einsum of the form ```term1, term2 -> output-term``` produces an output tensor using the following equation\n\n```output[output-term] = reduce-sum( input1[term1] * input2[term] )```\n\nwhere the reduce-sum performs a summation over all the indices occurring in in the input terms (term1, term2)\nthat do not occur in the output-term.\n\nThe Einsum operator evaluates algebraic tensor operations on a sequence of tensors, using the Einstein summation\nconvention. The equation string contains a comma-separated sequence of lower case letters. Each term corresponds to\nan operand tensor, and the characters within the terms correspond to operands dimensions.\n\nThis sequence may be followed by \"->\" to separate the left and right hand side of the equation.\nIf the equation contains \"->\" followed by the right-hand side, the explicit (not classical) form of the Einstein\nsummation is performed, and the right-hand side indices indicate output tensor dimensions. In other cases,\noutput indices are (implicitly) set to the alphabetically sorted sequence of indices appearing exactly once in the\nequation.\n\nWhen a dimension character is repeated in the left-hand side, it represents summation along the dimension.\n\nThe equation may contain ellipsis (\"...\") to enable broadcasting. Ellipsis must indicate a fixed number of dimensions.\nSpecifically, every occurrence of ellipsis in the equation must represent the same number of dimensions.\nThe right-hand side may contain exactly one ellipsis. In implicit mode, the ellipsis dimensions are set to the\nbeginning of the output. The equation string may contain space (U+0020) character.\n"
----f
input: "X"
output: "Y"
name: "Elu"
op_type: "Elu"
attribute {
name: "alpha"
f: 1.0
type: FLOAT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nElu takes one input data (Tensor<T>) and produces one output data\n(Tensor<T>) where the function `f(x) = alpha * (exp(x) - 1.) for x <\n0`, `f(x) = x for x >= 0`., is applied to the tensor elementwise.\n\n"
----f
input: "A"
input: "B"
output: "C"
name: "Equal"
op_type: "Equal"
attribute {
name: "A-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "B-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nReturns the tensor resulted from performing the `equal` logical operation\nelementwise on the input tensors `A` and `B` (with Numpy-style broadcasting support).\n\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "input"
output: "output"
name: "Erf"
op_type: "Erf"
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nComputes the error function of the given input tensor element-wise.\n"
----f
input: "input"
output: "output"
name: "Exp"
op_type: "Exp"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the exponential of the given input tensor, element-wise.\n"
----f
input: "input"
input: "shape"
output: "output"
name: "Expand"
op_type: "Expand"
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "shape-types"
strings: "int64"
type: STRINGS
}
doc_string: "\nBroadcast the input tensor following the given shape and the broadcast rule.\nThe broadcast rule is similar to numpy.array(input) * numpy.ones(shape):\nDimensions are right alignment;\nTwo corresponding dimension must have the same value, or one of them is equal to 1.\nAlso, this operator is similar to numpy.broadcast_to(input, shape),\nbut the major difference is numpy.broadcast_to() does not allow shape to be smaller than input.size().\nIt is possible that the output.shape is not equal to shape, when some dimensions in shape is equal to 1,\nor the shape.ndim < input.shape.ndim.\n"
----f
input: "input"
output: "output"
name: "EyeLike"
op_type: "EyeLike"
attribute {
name: "dtype"
s: ""
type: INT
}
attribute {
name: "k"
i: 0
type: INT
}
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "float16"
strings: "int32"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nGenerate a 2D tensor (matrix) with ones on the diagonal and zeros everywhere else. Only 2D\ntensors are supported, i.e. input T1 must be of rank 2. The shape of the output tensor is the\nsame as the input tensor. The data type can be specified by the \'dtype\' argument. If\n\'dtype\' is not specified, then the type of input tensor is used. By default, the main diagonal\nis populated with ones, but attribute \'k\' can be used to populate upper or lower diagonals.\nThe \'dtype\' argument must be one of the data types specified in the \'DataType\' enum field in the\nTensorProto message and be valid as an output type.\n"
----f
input: "X"
output: "Y"
name: "FeatureVectorizer"
op_type: "FeatureVectorizer"
attribute {
name: "inputdimensions"
s: ""
type: INTS
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\n Concatenates input tensors into one continuous output.<br>\n All input shapes are 2-D and are concatenated along the second dimention. 1-D tensors are treated as [1,C].\n Inputs are copied to the output maintaining the order of the input arguments.<br>\n All inputs must be integers or floats, while the output will be all floating point values.\n"
----f
input: "input"
output: "output"
name: "Flatten"
op_type: "Flatten"
attribute {
name: "axis"
i: 1
type: INT
}
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nFlattens the input tensor into a 2D matrix. If input tensor has shape\n(d_0, d_1, ... d_n) then the output will have shape\n(d_0 X d_1 ... d_(axis-1), d_axis X d_(axis+1) ... X dn).\n"
----f
input: "X"
output: "Y"
name: "Floor"
op_type: "Floor"
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nFloor takes one input data (Tensor<T>) and produces one output data\n(Tensor<T>) where the floor is, y = floor(x), is applied to\nthe tensor elementwise.\n"
----f
input: "X"
input: "W"
input: "R"
input: "B"
input: "sequence_lens"
input: "initial_h"
output: "Y"
output: "Y_h"
name: "GRU"
op_type: "GRU"
attribute {
name: "activation_alpha"
s: ""
type: FLOATS
}
attribute {
name: "activation_beta"
s: ""
type: FLOATS
}
attribute {
name: "activations"
s: ""
type: STRINGS
}
attribute {
name: "clip"
s: ""
type: FLOAT
}
attribute {
name: "direction"
s: "forward"
type: STRING
}
attribute {
name: "hidden_size"
s: ""
type: INT
}
attribute {
name: "linear_before_reset"
i: 0
type: INT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "W-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "R-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "B-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "sequence_lens-types"
strings: "int32"
type: STRINGS
}
attribute {
name: "initial_h-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nComputes an one-layer GRU. This operator is usually supported via some custom\nimplementation such as CuDNN.\n\nNotations:\n\n`X` - input tensor\n\n`z` - update gate\n\n`r` - reset gate\n\n`h` - hidden gate\n\n`t` - time step (t-1 means previous time step)\n\n`W[zrh]` - W parameter weight matrix for update, reset, and hidden gates\n\n`R[zrh]` - R recurrence weight matrix for update, reset, and hidden gates\n\n`Wb[zrh]` - W bias vectors for update, reset, and hidden gates\n\n`Rb[zrh]` - R bias vectors for update, reset, and hidden gates\n\n`WB[zrh]` - W parameter weight matrix for backward update, reset, and hidden gates\n\n`RB[zrh]` - R recurrence weight matrix for backward update, reset, and hidden gates\n\n`WBb[zrh]` - W bias vectors for backward update, reset, and hidden gates\n\n`RBb[zrh]` - R bias vectors for backward update, reset, and hidden gates\n\n`H` - Hidden state\n\n`num_directions` - 2 if direction == bidirectional else 1\n\nActivation functions:\n\n Relu(x) - max(0, x)\n\n Tanh(x) - (1 - e^{-2x})/(1 + e^{-2x})\n\n Sigmoid(x) - 1/(1 + e^{-x})\n\n (NOTE: Below are optional)\n\n Affine(x) - alpha*x + beta\n\n LeakyRelu(x) - x if x >= 0 else alpha * x\n\n ThresholdedRelu(x) - x if x >= alpha else 0\n\n ScaledTanh(x) - alpha*Tanh(beta*x)\n\n HardSigmoid(x) - min(max(alpha*x + beta, 0), 1)\n\n Elu(x) - x if x >= 0 else alpha*(e^x - 1)\n\n Softsign(x) - x/(1 + |x|)\n\n Softplus(x) - log(1 + e^x)\n\nEquations (Default: f=Sigmoid, g=Tanh):\n\n - zt = f(Xt*(Wz^T) + Ht-1*(Rz^T) + Wbz + Rbz)\n\n - rt = f(Xt*(Wr^T) + Ht-1*(Rr^T) + Wbr + Rbr)\n\n - ht = g(Xt*(Wh^T) + (rt (.) Ht-1)*(Rh^T) + Rbh + Wbh) # default, when linear_before_reset = 0\n\n - ht = g(Xt*(Wh^T) + (rt (.) (Ht-1*(Rh^T) + Rbh)) + Wbh) # when linear_before_reset != 0\n\n - Ht = (1 - zt) (.) ht + zt (.) Ht-1\nThis operator has **optional** inputs/outputs. See [the doc](IR.md) for more details about the representation of optional arguments. An empty string may be used in the place of an actual argument\'s name to indicate a missing argument. Trailing optional arguments (those not followed by an argument that is present) may also be simply omitted.\n"
----f
input: "data"
input: "indices"
output: "output"
name: "Gather"
op_type: "Gather"
attribute {
name: "axis"
i: 0
type: INT
}
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "indices-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\nGiven `data` tensor of rank r >= 1, and `indices` tensor of rank q, gather\nentries of the axis dimension of `data` (by default outer-most one as axis=0) indexed by `indices`, and concatenates\nthem in an output tensor of rank q + (r - 1).\n\naxis = 0 :\n\nLet\nk = indices[i_{0}, ..., i_{q-1}]\nThen\noutput[i_{0}, ..., i_{q-1}, j_{0}, ..., j_{r-2}] = input[k , j_{0}, ..., j_{r-2}]\n\n```\n data = [\n [1.0, 1.2],\n [2.3, 3.4],\n [4.5, 5.7],\n ]\n indices = [\n [0, 1],\n [1, 2],\n ]\n output = [\n [\n [1.0, 1.2],\n [2.3, 3.4],\n ],\n [\n [2.3, 3.4],\n [4.5, 5.7],\n ],\n ]\n```\naxis = 1 :\n\nLet\nk = indices[i_{0}, ..., i_{q-1}]\nThen\noutput[i_{0}, ..., i_{q-1}, j_{0}, ..., j_{r-2}] = input[j_{0}, k, j_{1}, ..., j_{r-2}]\n\n```\n data = [\n [1.0, 1.2, 1.9],\n [2.3, 3.4, 3.9],\n [4.5, 5.7, 5.9],\n ]\n indices = [\n [0, 2],\n ]\n axis = 1,\n output = [\n [\n [1.0, 1.9],\n [2.3, 3.9],\n [4.5, 5.9],\n ],\n ]\n```\n"
----f
input: "data"
input: "indices"
output: "output"
name: "GatherElements"
op_type: "GatherElements"
attribute {
name: "axis"
i: 0
type: INT
}
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "indices-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\n\nGatherElements takes two inputs `data` and `indices` of the same rank r >= 1\nand an optional attribute `axis` that identifies an axis of `data`\n(by default, the outer-most axis, that is axis 0). It is an indexing operation\nthat produces its output by indexing into the input data tensor at index\npositions determined by elements of the `indices` tensor.\nIts output shape is the same as the shape of `indices` and consists of one value\n(gathered from the `data`) for each element in `indices`.\n\nFor instance, in the 3-D case (r = 3), the output produced is determined\nby the following equations: \n```\n out[i][j][k] = input[index[i][j][k]][j][k] if axis = 0,\n out[i][j][k] = input[i][index[i][j][k]][k] if axis = 1,\n out[i][j][k] = input[i][j][index[i][j][k]] if axis = 2,\n```\n\nThis operator is also the inverse of ScatterElements. It is similar to Torch\'s gather operation.\n\nExample 1:\n```\n data = [\n [1, 2],\n [3, 4],\n ]\n indices = [\n [0, 0],\n [1, 0],\n ]\n axis = 1\n output = [\n [\n [1, 1],\n [4, 3],\n ],\n ]\n```\nExample 2:\n```\n data = [\n [1, 2, 3],\n [4, 5, 6],\n [7, 8, 9],\n ]\n indices = [\n [1, 2, 0],\n [2, 0, 0],\n ]\n axis = 0\n output = [\n [\n [4, 8, 3],\n [7, 2, 3],\n ],\n ]\n```\n"
----f
input: "data"
input: "indices"
output: "output"
name: "GatherND"
op_type: "GatherND"
attribute {
name: "batch_dims"
i: 0
type: INT
}
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "indices-types"
strings: "int64"
type: STRINGS
}
doc_string: "\nGiven `data` tensor of rank `r` >= 1, `indices` tensor of rank `q` >= 1, and `batch_dims` integer `b`, this operator gathers \nslices of `data` into an output tensor of rank `q + r - indices_shape[-1] - 1 - b`.\n\n`indices` is an q-dimensional integer tensor, best thought of as a `(q-1)`-dimensional tensor of index-tuples into `data`, \nwhere each element defines a slice of `data`\n\n`batch_dims` (denoted as `b`) is an integer indicating the number of batch dimensions, i.e the leading `b` number of dimensions of \n`data` tensor and `indices` are representing the batches, and the gather starts from the `b+1` dimension. \n\nSome salient points about the inputs\' rank and shape:\n \n1) r >= 1 and q >= 1 are to be honored. There is no dependency condition to be met between ranks `r` and `q`\n\n2) The first `b` dimensions of the shape of `indices` tensor and `data` tensor must be equal.\n\n3) b < min(q, r) is to be honored.\n\n4) The `indices_shape[-1]` should have a value between 1 (inclusive) and rank `r-b` (inclusive) \n\n5) All values in `indices` are expected to be within bounds [-s, s-1] along axis of size `s` (i.e.) `-data_shape[i] <= indices[...,i] <= data_shape[i] - 1`.\n It is an error if any of the index values are out of bounds.\n\nThe output is computed as follows:\n\nThe output tensor is obtained by mapping each index-tuple in the `indices` tensor to the corresponding slice of the input `data`.\n \n1) If `indices_shape[-1] > r-b` => error condition\n\n2) If `indices_shape[-1] == r-b`, since the rank of `indices` is `q`, `indices` can be thought of as `N` `(q-b-1)`-dimensional tensors\n containing 1-D tensors of dimension `r-b`, where `N` is an integer equals to the product of 1 and all the elements in the batch dimensions \n of the indices_shape. Let us think of each such `r-b` ranked tensor as `indices_slice`. Each *scalar value* corresponding to `data[0:b-1,indices_slice]` \n is filled into the corresponding location of the `(q-b-1)`-dimensional tensor to form the `output` tensor (Example 1 below)\n\n3) If `indices_shape[-1] < r-b`, since the rank of `indices` is `q`, `indices` can be thought of as `N` `(q-b-1)`-dimensional tensor\n containing 1-D tensors of dimension `< r-b`. Let us think of each such tensors as `indices_slice`. Each *tensor slice* corresponding \n to `data[0:b-1, indices_slice , :]` is filled into the corresponding location of the `(q-b-1)`-dimensional tensor \n to form the `output` tensor (Examples 2, 3, 4 and 5 below)\n\nThis operator is the inverse of `ScatterND`.\n\n`Example 1`\n\n batch_dims = 0\n\n data = [[0,1],[2,3]] # data_shape = [2, 2]\n\n indices = [[0,0],[1,1]] # indices_shape = [2, 2]\n\n output = [0,3] # output_shape = [2]\n\n`Example 2`\n\n batch_dims = 0\n\n data = [[0,1],[2,3]] # data_shape = [2, 2]\n\n indices = [[1],[0]] # indices_shape = [2, 1]\n\n output = [[2,3],[0,1]] # output_shape = [2, 2]\n\n`Example 3`\n\n batch_dims = 0\n\n data = [[[0,1],[2,3]],[[4,5],[6,7]]] # data_shape = [2, 2, 2]\n\n indices = [[0,1],[1,0]] # indices_shape = [2, 2]\n\n output = [[2,3],[4,5]] # output_shape = [2, 2] \n\n`Example 4`\n\n batch_dims = 0\n\n data = [[[0,1],[2,3]],[[4,5],[6,7]]] # data_shape = [2, 2, 2]\n\n indices = [[[0,1]],[[1,0]]] # indices_shape = [2, 1, 2]\n\n output = [[[2,3]],[[4,5]]] # output_shape = [2, 1, 2] \n\n`Example 5`\n\n batch_dims = 1\n\n data = [[[0,1],[2,3]],[[4,5],[6,7]]] # data_shape = [2, 2, 2]\n\n indices = [[1],[0]] # indices_shape = [2, 1]\n\n output = [[2,3],[4,5]] # output_shape = [2, 2] \n\n\n"
----f
input: "A"
input: "B"
input: "C"
output: "Y"
name: "Gemm"
op_type: "Gemm"
attribute {
name: "alpha"
f: 1.0
type: FLOAT
}
attribute {
name: "beta"
f: 1.0
type: FLOAT
}
attribute {
name: "transA"
i: 0
type: INT
}
attribute {
name: "transB"
i: 0
type: INT
}
attribute {
name: "A-types"
strings: "int32"
strings: "float16"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
attribute {
name: "B-types"
strings: "int32"
strings: "float16"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
attribute {
name: "C-types"
strings: "int32"
strings: "float16"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "General Matrix multiplication:\nhttps://en.wikipedia.org/wiki/Basic_Linear_Algebra_Subprograms#Level_3\n\nA\' = transpose(A) if transA else A\n\nB\' = transpose(B) if transB else B\n\nCompute Y = alpha * A\' * B\' + beta * C, where input tensor A has shape (M, K) or (K, M),\ninput tensor B has shape (K, N) or (N, K), input tensor C is broadcastable to shape (M, N),\nand output tensor Y has shape (M, N). A will be transposed before doing the\ncomputation if attribute transA is non-zero, same for B and transB.\nThis operator supports **unidirectional broadcasting** (tensor C should be unidirectional broadcastable to tensor A * B); for more details please check [the doc](Broadcasting.md).\nThis operator has **optional** inputs/outputs. See [the doc](IR.md) for more details about the representation of optional arguments. An empty string may be used in the place of an actual argument\'s name to indicate a missing argument. Trailing optional arguments (those not followed by an argument that is present) may also be simply omitted.\n"
----f
input: "X"
output: "Y"
name: "GlobalAveragePool"
op_type: "GlobalAveragePool"
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\n GlobalAveragePool consumes an input tensor X and applies average pooling across\n the values in the same channel. This is equivalent to AveragePool with kernel size\n equal to the spatial dimension of input tensor."
----f
input: "X"
output: "Y"
name: "GlobalLpPool"
op_type: "GlobalLpPool"
attribute {
name: "p"
i: 2
type: INT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\n GlobalLpPool consumes an input tensor X and applies lp pool pooling across\n the values in the same channel. This is equivalent to LpPool with kernel size\n equal to the spatial dimension of input tensor."
----f
input: "X"
output: "Y"
name: "GlobalMaxPool"
op_type: "GlobalMaxPool"
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\n GlobalMaxPool consumes an input tensor X and applies max pooling across\n the values in the same channel. This is equivalent to MaxPool with kernel size\n equal to the spatial dimension of input tensor."
----f
input: "Inputs"
output: "Outputs"
name: "Gradient"
op_type: "Gradient"
attribute {
name: "xs"
s: ""
type: STRINGS
}
attribute {
name: "y"
s: ""
type: STRING
}
attribute {
name: "zs"
s: ""
type: STRINGS
}
attribute {
name: "Inputs-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nGradient operator computes the partial derivatives of a specific tensor w.r.t.\nsome other tensors. This operator is widely used in gradient-based training\nalgorithms. To illustrate its use, let\'s consider a computation graph,\n\n```\nX -----.\n |\n v\nW --> Conv --> H --> Gemm --> Y\n ^\n |\n Z\n```\n\n, where W and Z are trainable tensors. Note that operators\' attributes are\nomitted for the sake of simplicity. Let dY/dW (dY/dZ) be the gradient of\nY with respect to W (Z). The user can compute gradient by inserting Gradient\noperator to form another graph shown below.\n\n```\nW --> Conv --> H --> Gemm --> Y\n| ^ ^\n| | |\n| X Z\n| | |\n| | .----------\'\n| | | (W/Z/X is the 1st/2nd/3rd input of Gradient as shown in\n| | | \"xs\" followed by \"zs\")\n| v v\n\'---> Gradient(xs=[\"W\", \"Z\"], zs=[\"X\"], y=\"Y\")\n | |\n | \'-----------------------------------> dY/dW (1st output of Gradient)\n |\n \'---------------------------------------> dY/dZ (2nd output of Gradient)\n```\n\nBy definition, the tensor \"y\" is a function of independent variables in \"xs\"\nand \"zs\". Since we only compute the gradient of \"y\" w.r.t. the differentiable\nvariables in \"xs\", this Gradient only outputs dY/dW and dY/dZ. Note that \"H\"\ncannot appear in \"xs\" and \"zs\". The reason is that \"H\" can be determined by\ntensors \"W\" and \"X\" and therefore \"H\" is not an independent variable.\n\nAll outputs are optional. If needed, for example, user can assign an empty\nstring to the 1st output name of that Gradient to skip the generation of dY/dW.\nNote that the concept of optional outputs can also be found in ONNX\'s RNN, GRU,\nand LSTM.\n\nGradient operator can compute derivative against intermediate tensors. For\nexample, the gradient of Y with respect to H can be done via\n\n```\nW --> Conv --> H --> Gemm --> Y\n ^ | ^\n | | |\n X | Z\n .-------\' |\n | .----------\'\n | | (H/Z is the 1st/2nd input of Gradient as shown in \"xs\")\n v v\n Gradient(xs=[\"H\", \"Z\"], y=\"Y\")\n | |\n | \'-----------------------------------> dY/dH (1st output of Gradient)\n |\n \'---------------------------------------> dY/dZ (2nd output of Gradient)\n```\n\nIt is possible to represent high-order differentiation using Gradient operators.\nFor example, given the following linear model:\n\n```\nW --> Gemm --> Y --> Loss --> O\n ^ ^\n | |\n X L\n```\n\nTo compute the 2nd order derivative of O with respect to W (denoted by\nd^2O/dW^2), one can do\n\n```\nW --> Gemm --> Y --> Loss --> O\n| ^ ^\n| | |\n| X .------------L\n| | | |\n| | | v\n+------+-+> Gradient(xs=[\"X\", \"W\"], zs=[\"L\"], y=\"O\") ---> dO/dX (1st output of Gradient)\n| | | |\n| | | \'---> dO/dW (2nd output of Gradient)\n| v v\n\'---> Gradient(xs=[\"X\", \"W\"], zs=[\"L\"], y=\"dO/dW\") ---> d(dO/dW)dX (1st output of\n | Gradient)\n |\n |\n \'---> d^2O/dW^2 (2nd output of Gradient)\n```\n\nThe tensors named in attributes \"xs\", \"zs\", and \"y\" define the differentiated\ncomputation graph, and the inputs to Gradient node define the values at\nwhich the gradient is computed. We can feed different tensors to the identified\ngraph. For example, one can compute the gradient of Y with respect to H at \na specific value of H, H_1, by providing that value as an input to the Gradient\nnode.\n\n```\nW --> Conv --> H --> Gemm --> Y\n ^ ^\n | |\n X Z\n\n Z_1 (2nd input of Gradient)\n |\n v\nH_1 --> Gradient(xs=[\"H\", \"Z\"], y=\"Y\") ---> dY/dH when H = H_1
----f
input: "Inputs"
output: "Outputs"
name: "GraphCall"
op_type: "GraphCall"
attribute {
name: "graph_name"
s: ""
type: STRING
}
attribute {
name: "Inputs-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nThe GraphCall operator invokes a graph inside TrainingInfoProto\'s\nalgorithm field. The GraphCall inputs and outputs are bound to those of\ninvoked graph by position. If a graph input has an initializer, that input\nis considered optional. All graph outputs are optional.\n\nBelow Python syntax is used for describing dictionary and list.\n\nAssume that ModelProto\'s graph field has\n- name: \"MyInferenceGraph\"\n- input: [\"X\", \"W\", \"Z\"]\n- initializer: [W]\n- output: [\"Y\"]\n\nas visualized below for inference.\n\n```\nX -----.\n |\n v\nW --> Conv --> H --> Gemm --> Y\n ^\n |\n Z\n```\n\nAssume that the training algorithm contains\n\n- inputs: [\"X_1\", \"Z_1\", \"C\"]\n- initializer: [T]\n- outputs: [\"W_new\"]\n\nwith a dictionary\n\n- update_binding: {\"W\": \"W_new\", \"T\": \"T_new\"}\n\nInside the training algorithm graph, one can invoke the inference\ngraph via adding a GraphCall node with\n\n- inputs: [\"X_1\", \"W\", Z_1\"]\n- outputs: [\"Y_1\"]\n- an attribute graph_name=\"MyInferenceGraph\",\n\nThe initializers, \"W\" and \"T\" in this case, in update_binding\nare considered globally-visible and mutable variables, which\ncan be used as inputs of operators in the training graph.\n\nAn example training algorithm graph may look like\n\n```\n.-------- W (a global and mutable variable from\n| | the inference graph)\n| |\n| .-----\'-----------.\n| | |\n| | v\n| | .-- X_1 --> GraphCall(graph_name=\"MyInferenceGraph\")\n| | | | |\n| | | | |\n| | | Z_1 -----\' |\n| | | | V\n| | | | Y_1 ---> Loss ---> O\n| | | | ^\n| | | | |\n| | `--. | C\n| | | | |\n| | | | .----------------\'\n| | | | |\n| | v v v\n| `--> Gradient(xs=[\"W\"], zs=[\"X_1\", \"Z_1\", \"C\"], y=\"O\")\n| |\n| v\n| dO_dW (gradient of W) 1 (a scalar one)\n| | |\n| V v\n| Div <--- T ------------> Add ---> T_new\n| | (T is the number of training iterations.\n| | T is also globally visible and mutable.)\n| v\n`-----> Sub ----> W_new\n```\n\nwhere Loss is a dummy node which computes the minimized objective function.\n\nThe variable \"W\" is an optional input in the called graph.\nIf the user omits it, the input list of GraphCall becomes [\"X_1\", \"\", \"Z_1\"].\nIn this case, from the view of computation graph, the Conv operator invoked by\nGraphCall\'s may be still connected the global \"W\" variable and therefore the\nstructure of the computation graph is unchanged.\n"
----f
input: "A"
input: "B"
output: "C"
name: "Greater"
op_type: "Greater"
attribute {
name: "A-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "B-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nReturns the tensor resulted from performing the `greater` logical operation\nelementwise on the input tensors `A` and `B` (with Numpy-style broadcasting support).\n\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "A"
input: "B"
output: "C"
name: "GreaterOrEqual"
op_type: "GreaterOrEqual"
attribute {
name: "A-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "B-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nReturns the tensor resulted from performing the `greater_equal` logical operation\nelementwise on the input tensors `A` and `B` (with Numpy-style broadcasting support).\n\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "X"
output: "Y"
name: "HardSigmoid"
op_type: "HardSigmoid"
attribute {
name: "alpha"
f: 0.2
type: FLOAT
}
attribute {
name: "beta"
f: 0.5
type: FLOAT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nHardSigmoid takes one input data (Tensor<T>) and produces one output data\n(Tensor<T>) where the HardSigmoid function, y = max(0, min(1, alpha * x + beta)),\nis applied to the tensor elementwise.\n"
----f
input: "input"
output: "output"
name: "Hardmax"
op_type: "Hardmax"
attribute {
name: "axis"
i: 1
type: INT
}
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nThe operator computes the hardmax (1 for the first maximum value, and 0 for all others) values for each layer in the batch\n of the given input.\n\nThe input does not need to explicitly be a 2D vector; rather, it will be\ncoerced into one. For an arbitrary n-dimensional tensor\ninput \\in [a_0, a_1, ..., a_{k-1}, a_k, ..., a_{n-1}] and k is\nthe axis provided, then input will be coerced into a 2-dimensional tensor with\ndimensions [a_0 * ... * a_{k-1}, a_k * ... * a_{n-1}]. For the default\ncase where axis=1, this means the input tensor will be coerced into a 2D tensor\nof dimensions [a_0, a_1 * ... * a_{n-1}], where a_0 is often the batch size.\nIn this situation, we must have a_0 = N and a_1 * ... * a_{n-1} = D.\nEach of these dimensions must be matched correctly, or else the operator\nwill throw errors. The output tensor has the same shape\nand contains the hardmax values of the corresponding input.\n"
----f
input: "input"
output: "output"
name: "Identity"
op_type: "Identity"
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "Identity operator"
----f
input: "cond"
output: "outputs"
name: "If"
op_type: "If"
attribute {
name: "else_branch"
s: ""
type: GRAPH
}
attribute {
name: "then_branch"
s: ""
type: GRAPH
}
attribute {
name: "cond-types"
strings: "bool"
type: STRINGS
}
doc_string: "If conditional"
----f
input: "X"
output: "Y"
name: "Imputer"
op_type: "Imputer"
attribute {
name: "imputed_value_floats"
s: ""
type: FLOATS
}
attribute {
name: "imputed_value_int64s"
s: ""
type: INTS
}
attribute {
name: "replaced_value_float"
f: 0.0
type: FLOAT
}
attribute {
name: "replaced_value_int64"
i: 0
type: INT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\n Replaces inputs that equal one value with another, leaving all other elements alone.<br>\n This operator is typically used to replace missing values in situations where they have a canonical\n representation, such as -1, 0, NaN, or some extreme value.<br>\n One and only one of imputed_value_floats or imputed_value_int64s should be defined -- floats if the input tensor\n holds floats, integers if the input tensor holds integers. The imputed values must all fit within the\n width of the tensor element type. One and only one of the replaced_value_float or replaced_value_int64 should be defined,\n which one depends on whether floats or integers are being processed.<br>\n The imputed_value attribute length can be 1 element, or it can have one element per input feature.<br>In other words, if the input tensor has the shape [*,F], then the length of the attribute array may be 1 or F. If it is 1, then it is broadcast along the last dimension and applied to each feature.\n"
----f
input: "input"
input: "scale"
input: "B"
output: "output"
name: "InstanceNormalization"
op_type: "InstanceNormalization"
attribute {
name: "epsilon"
f: 1e-05
type: FLOAT
}
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "scale-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "B-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCarries out instance normalization as described in the paper\nhttps://arxiv.org/abs/1607.08022.\n\ny = scale * (x - mean) / sqrt(variance + epsilon) + B,\nwhere mean and variance are computed per instance per channel.\n\n"
----f
input: "X"
output: "Y"
name: "IsInf"
op_type: "IsInf"
attribute {
name: "detect_negative"
i: 1
type: INT
}
attribute {
name: "detect_positive"
i: 1
type: INT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
type: STRINGS
}
doc_string: "Map infinity to true and other values to false."
----f
input: "X"
output: "Y"
name: "IsNaN"
op_type: "IsNaN"
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "Returns which elements of the input are NaN."
----f
input: "X"
output: "Y"
name: "LRN"
op_type: "LRN"
attribute {
name: "alpha"
f: 0.0001
type: FLOAT
}
attribute {
name: "beta"
f: 0.75
type: FLOAT
}
attribute {
name: "bias"
f: 1.0
type: FLOAT
}
attribute {
name: "size"
s: ""
type: INT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nLocal Response Normalization proposed in the [AlexNet paper](https://papers.nips.cc/paper/4824-imagenet-classification-with-deep-convolutional-neural-networks.pdf).\nIt normalizes over local input regions.\nThe local region is defined across the channels. For an element X[n, c, d1, ..., dk] in a tensor\nof shape (N x C x D1 x D2, ..., Dk), its region is\n{X[n, i, d1, ..., dk] | max(0, c - floor((size - 1) / 2)) <= i <= min(C - 1, c + ceil((size - 1) / 2))}.\n\nsquare_sum[n, c, d1, ..., dk] = sum(X[n, i, d1, ..., dk] ^ 2),\nwhere max(0, c - floor((size - 1) / 2)) <= i <= min(C - 1, c + ceil((size - 1) / 2)).\n\nY[n, c, d1, ..., dk] = X[n, c, d1, ..., dk] / (bias + alpha / size * square_sum[n, c, d1, ..., dk] ) ^ beta\n"
----f
input: "X"
input: "W"
input: "R"
input: "B"
input: "sequence_lens"
input: "initial_h"
input: "initial_c"
input: "P"
output: "Y"
output: "Y_h"
output: "Y_c"
name: "LSTM"
op_type: "LSTM"
attribute {
name: "activation_alpha"
s: ""
type: FLOATS
}
attribute {
name: "activation_beta"
s: ""
type: FLOATS
}
attribute {
name: "activations"
s: ""
type: STRINGS
}
attribute {
name: "clip"
s: ""
type: FLOAT
}
attribute {
name: "direction"
s: "forward"
type: STRING
}
attribute {
name: "hidden_size"
s: ""
type: INT
}
attribute {
name: "input_forget"
i: 0
type: INT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "W-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "R-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "B-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "sequence_lens-types"
strings: "int32"
type: STRINGS
}
attribute {
name: "initial_h-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "initial_c-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "P-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nComputes an one-layer LSTM. This operator is usually supported via some\ncustom implementation such as CuDNN.\n\nNotations:\n\n`X` - input tensor\n\n`i` - input gate\n\n`o` - output gate\n\n`f` - forget gate\n\n`c` - cell gate\n\n`t` - time step (t-1 means previous time step)\n\n`W[iofc]` - W parameter weight matrix for input, output, forget, and cell gates\n\n`R[iofc]` - R recurrence weight matrix for input, output, forget, and cell gates\n\n`Wb[iofc]` - W bias vectors for input, output, forget, and cell gates\n\n`Rb[iofc]` - R bias vectors for input, output, forget, and cell gates\n\n`P[iof]` - P peephole weight vector for input, output, and forget gates\n\n`WB[iofc]` - W parameter weight matrix for backward input, output, forget, and cell gates\n\n`RB[iofc]` - R recurrence weight matrix for backward input, output, forget, and cell gates\n\n`WBb[iofc]` - W bias vectors for backward input, output, forget, and cell gates\n\n`RBb[iofc]` - R bias vectors for backward input, output, forget, and cell gates\n\n`PB[iof]` - P peephole weight vector for backward input, output, and forget gates\n\n`H` - Hidden state\n\n`num_directions` - 2 if direction == bidirectional else 1\n\nActivation functions:\n\n Relu(x) - max(0, x)\n\n Tanh(x) - (1 - e^{-2x})/(1 + e^{-2x})\n\n Sigmoid(x) - 1/(1 + e^{-x})\n\n (NOTE: Below are optional)\n\n Affine(x) - alpha*x + beta\n\n LeakyRelu(x) - x if x >= 0 else alpha * x\n\n ThresholdedRelu(x) - x if x >= alpha else 0\n\n ScaledTanh(x) - alpha*Tanh(beta*x)\n\n HardSigmoid(x) - min(max(alpha*x + beta, 0), 1)\n\n Elu(x) - x if x >= 0 else alpha*(e^x - 1)\n\n Softsign(x) - x/(1 + |x|)\n\n Softplus(x) - log(1 + e^x)\n\nEquations (Default: f=Sigmoid, g=Tanh, h=Tanh):\n\n - it = f(Xt*(Wi^T) + Ht-1*(Ri^T) + Pi (.) Ct-1 + Wbi + Rbi)\n\n - ft = f(Xt*(Wf^T) + Ht-1*(Rf^T) + Pf (.) Ct-1 + Wbf + Rbf)\n\n - ct = g(Xt*(Wc^T) + Ht-1*(Rc^T) + Wbc + Rbc)\n\n - Ct = ft (.) Ct-1 + it (.) ct\n\n - ot = f(Xt*(Wo^T) + Ht-1*(Ro^T) + Po (.) Ct + Wbo + Rbo)\n\n - Ht = ot (.) h(Ct)\nThis operator has **optional** inputs/outputs. See [the doc](IR.md) for more details about the representation of optional arguments. An empty string may be used in the place of an actual argument\'s name to indicate a missing argument. Trailing optional arguments (those not followed by an argument that is present) may also be simply omitted.\n"
----f
input: "X"
output: "Y"
name: "LabelEncoder"
op_type: "LabelEncoder"
attribute {
name: "default_float"
f: -0.0
type: FLOAT
}
attribute {
name: "default_int64"
i: -1
type: INT
}
attribute {
name: "default_string"
s: "_Unused"
type: STRING
}
attribute {
name: "keys_floats"
s: ""
type: FLOATS
}
attribute {
name: "keys_int64s"
s: ""
type: INTS
}
attribute {
name: "keys_strings"
s: ""
type: STRINGS
}
attribute {
name: "values_floats"
s: ""
type: FLOATS
}
attribute {
name: "values_int64s"
s: ""
type: INTS
}
attribute {
name: "values_strings"
s: ""
type: STRINGS
}
attribute {
name: "X-types"
strings: "string"
strings: "float"
strings: "int64"
type: STRINGS
}
doc_string: "\n Maps each element in the input tensor to another value.<br>\n The mapping is determined by the two parallel attributes, \'keys_*\' and\n \'values_*\' attribute. The i-th value in the specified \'keys_*\' attribute\n would be mapped to the i-th value in the specified \'values_*\' attribute. It\n implies that input\'s element type and the element type of the specified\n \'keys_*\' should be identical while the output type is identical to the\n specified \'values_*\' attribute. If an input element can not be found in the\n specified \'keys_*\' attribute, the \'default_*\' that matches the specified\n \'values_*\' attribute may be used as its output value.<br>\n Let\'s consider an example which maps a string tensor to an integer tensor.\n Assume and \'keys_strings\' is [\"Amy\", \"Sally\"], \'values_int64s\' is [5, 6],\n and \'default_int64\' is \'-1\'. The input [\"Dori\", \"Amy\", \"Amy\", \"Sally\",\n \"Sally\"] would be mapped to [-1, 5, 5, 6, 6].<br>\n Since this operator is an one-to-one mapping, its input and output shapes\n are the same. Notice that only one of \'keys_*\'/\'values_*\' can be set.<br>\n For key look-up, bit-wise comparison is used so even a float NaN can be\n mapped to a value in \'values_*\' attribute.<br>\n"
----f
input: "X"
output: "Y"
name: "LeakyRelu"
op_type: "LeakyRelu"
attribute {
name: "alpha"
f: 0.01
type: FLOAT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nLeakyRelu takes input data (Tensor<T>) and an argument alpha, and produces one\noutput data (Tensor<T>) where the function `f(x) = alpha * x for x < 0`,\n`f(x) = x for x >= 0`, is applied to the data tensor elementwise.\n"
----f
input: "A"
input: "B"
output: "C"
name: "Less"
op_type: "Less"
attribute {
name: "A-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "B-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nReturns the tensor resulted from performing the `less` logical operation\nelementwise on the input tensors `A` and `B` (with Numpy-style broadcasting support).\n\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "A"
input: "B"
output: "C"
name: "LessOrEqual"
op_type: "LessOrEqual"
attribute {
name: "A-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "B-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nReturns the tensor resulted from performing the `less_equal` logical operation\nelementwise on the input tensors `A` and `B` (with Numpy-style broadcasting support).\n\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "X"
output: "Y"
output: "Z"
name: "LinearClassifier"
op_type: "LinearClassifier"
attribute {
name: "classlabels_ints"
s: ""
type: INTS
}
attribute {
name: "classlabels_strings"
s: ""
type: STRINGS
}
attribute {
name: "coefficients"
s: ""
type: FLOATS
}
attribute {
name: "intercepts"
s: ""
type: FLOATS
}
attribute {
name: "multi_class"
i: 0
type: INT
}
attribute {
name: "post_transform"
s: "NONE"
type: STRING
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\n Linear classifier\n"
----f
input: "X"
output: "Y"
name: "LinearRegressor"
op_type: "LinearRegressor"
attribute {
name: "coefficients"
s: ""
type: FLOATS
}
attribute {
name: "intercepts"
s: ""
type: FLOATS
}
attribute {
name: "post_transform"
s: "NONE"
type: STRING
}
attribute {
name: "targets"
i: 1
type: INT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\n Generalized linear regression evaluation.<br>\n If targets is set to 1 (default) then univariate regression is performed.<br>\n If targets is set to M then M sets of coefficients must be passed in as a sequence\n and M results will be output for each input n in N.<br>\n The coefficients array is of length n, and the coefficients for each target are contiguous.\n Intercepts are optional but if provided must match the number of targets.\n"
----f
input: "input"
output: "output"
name: "Log"
op_type: "Log"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the natural log of the given input tensor, element-wise.\n"
----f
input: "input"
output: "output"
name: "LogSoftmax"
op_type: "LogSoftmax"
attribute {
name: "axis"
i: 1
type: INT
}
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nThe operator computes the logsoftmax (log of softmax) values for each layer in the batch\n of the given input.\n\nThe input does not need to explicitly be a 2D vector; rather, it will be\ncoerced into one. For an arbitrary n-dimensional tensor\ninput \\in [a_0, a_1, ..., a_{k-1}, a_k, ..., a_{n-1}] and k is\nthe axis provided, then input will be coerced into a 2-dimensional tensor with\ndimensions [a_0 * ... * a_{k-1}, a_k * ... * a_{n-1}]. For the default\ncase where axis=1, this means the input tensor will be coerced into a 2D tensor\nof dimensions [a_0, a_1 * ... * a_{n-1}], where a_0 is often the batch size.\nIn this situation, we must have a_0 = N and a_1 * ... * a_{n-1} = D.\nEach of these dimensions must be matched correctly, or else the operator\nwill throw errors. The output tensor has the same shape\nand contains the logsoftmax values of the corresponding input.\n"
----f
input: "M"
input: "cond"
input: "v_initial"
output: "v_final_and_scan_outputs"
name: "Loop"
op_type: "Loop"
attribute {
name: "body"
s: ""
type: GRAPH
}
attribute {
name: "M-types"
strings: "int64"
type: STRINGS
}
attribute {
name: "cond-types"
strings: "bool"
type: STRINGS
}
attribute {
name: "v_initial-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nGeneric Looping construct. This loop has multiple termination conditions:\n\n1) Trip count. Iteration count specified at runtime. Set by\n specifying the input M. Optional. Set to empty string to omit.\n Note that a static trip count (specified at graph construction time) can be\n specified by passing in a constant node for input M.\n2) Loop termination condition. This is an input to the op that determines\n whether to run the first iteration and also a loop-carried dependency for\n the body graph. The body graph must yield a value for the condition variable,\n whether this input is provided or not.\n\nThis table summarizes the operating modes of this operator with equivalent\nC-style code:\n\n Operator inputs defined as (max_trip_count, condition_var).\n\n input (\"\", \"\"):\n for (int i=0; ; ++i) {\n cond = ... // Note this value is ignored, but is required in the body\n }\n\n input (\"\", cond) // Note this is analogous to a while loop\n bool cond = ...;\n for (int i=0; cond; ++i) {\n cond = ...;\n }\n\n input (\"\", 1) // Note this is analogous to a do-while loop\n bool cond = true\n for (int i=0; cond; ++i) {\n cond = ...;\n }\n\n input (trip_count, \"\") // Note this is analogous to a for loop\n int trip_count = ...\n for (int i=0; i < trip_count; ++i) {\n cond = ...; // ignored\n }\n\n input (trip_count, cond)\n int trip_count = ...;\n bool cond = ...;\n for (int i=0; i < trip_count && cond; ++i) {\n cond = ...;\n }\n\n\n*Sample usage - cond as well as trip count*\n\n graph predict-net {\n %a = Constant[value = <Scalar Tensor [3]>]()\n %b = Constant[value = <Scalar Tensor [6]>]()\n %keepgoing = Constant[value = <Scalar Tensor [1]>]()\n %max_trip_count = Constant[value = <Scalar Tensor [10]>]()\n %keepgoing_out, %b_out, %user_defined_vals = Loop[body = <graph body-net>](%max_trip_count, %keepgoing, %b)\n return\n }\n\n graph body-net (\n %i[INT32, scalar] // iteration number\n %keepgoing_in[BOOL, scalar] // incoming loop-termination-condition; not used\n %b_in[INT32, scalar] // incoming value of loop-carried-dependency b\n ) {\n %my_local = Add(%a, %b_in)\n %b_out = Sub(%a, %b_in) // outgoing value of loop-carried-dependency b\n %keepgoing_out = Greater(%my_local, %b_out) // outgoing loop-termination-condition\n %user_defined_val = Add(%b_in, %b_in) // scan-output value to be accumulated\n return %keepgoing_out, %b_out, %user_defined_val\n }\n\n*Sample equivalent C code*\n\n {\n /* User-defined code (enclosing scope) */\n int a = 3, b = 6;\n bool keepgoing = true; // Analogous to input cond\n /* End user-defined code */\n\n /* Implicitly-defined code */\n const int max_trip_count = 10; // Analogous to input M\n int user_defined_vals[]; // Imagine this is resizable\n /* End implicitly-defined code */\n /* initialize loop-carried variables and scan-output variables */\n bool keepgoing_out = keepgoing\n int b_out = b\n\n for (int i=0; i < max_trip_count && keepgoing_out; ++i) {\n /* Implicitly-defined code: bind actual parameter values\n to formal parameter variables of loop-body */\n bool keepgoing_in = keepgoing_out; \n bool b_in = b_out;\n\n /* User-defined code (loop body) */\n int my_local = a + b_in; // Reading value \"a\" from the enclosing scope is fine\n b_out = a - b_in;\n keepgoing_out = my_local > b_out; \n user_defined_val = b_in + b_in; // b_in and b_out are different variables\n /* End user-defined code */\n\n /* Implicitly defined-code */\n user_defined_vals[i] = user_defined_val // accumulate scan-output values\n }\n // int t = my_local; // Can\'t do this. my_local is not accessible here.\n\n // The values below are bound to the output variables
----f
input: "input"
output: "output"
name: "LpNormalization"
op_type: "LpNormalization"
attribute {
name: "axis"
i: -1
type: INT
}
attribute {
name: "p"
i: 2
type: INT
}
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nGiven a matrix, apply Lp-normalization along the provided axis.\n"
----f
input: "X"
output: "Y"
name: "LpPool"
op_type: "LpPool"
attribute {
name: "auto_pad"
s: "NOTSET"
type: STRING
}
attribute {
name: "kernel_shape"
s: ""
type: INTS
}
attribute {
name: "p"
i: 2
type: INT
}
attribute {
name: "pads"
s: ""
type: INTS
}
attribute {
name: "strides"
s: ""
type: INTS
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\n LpPool consumes an input tensor X and applies Lp pooling across\n the tensor according to kernel sizes, stride sizes, and pad lengths.\n Lp pooling consisting of computing the Lp norm on all values of a subset\n of the input tensor according to the kernel size and downsampling the\n data into the output tensor Y for further processing."
----f
input: "A"
input: "B"
output: "Y"
name: "MatMul"
op_type: "MatMul"
attribute {
name: "A-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
attribute {
name: "B-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nMatrix product that behaves like numpy.matmul: https://docs.scipy.org/doc/numpy-1.13.0/reference/generated/numpy.matmul.html\n"
----f
input: "A"
input: "B"
input: "a_zero_point"
input: "b_zero_point"
output: "Y"
name: "MatMulInteger"
op_type: "MatMulInteger"
attribute {
name: "A-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "B-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "a_zero_point-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "b_zero_point-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
doc_string: "\nMatrix product that behaves like numpy.matmul: https://docs.scipy.org/doc/numpy-1.13.0/reference/generated/numpy.matmul.html.\nThe production MUST never overflow. The accumulation may overflow if and only if in 32 bits.\n"
----f
input: "data_0"
output: "max"
name: "Max"
op_type: "Max"
attribute {
name: "data_0-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nElement-wise max of each of the input tensors (with Numpy-style broadcasting support).\nAll inputs and outputs must have the same data type.\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "X"
output: "Y"
output: "Indices"
name: "MaxPool"
op_type: "MaxPool"
attribute {
name: "auto_pad"
s: "NOTSET"
type: STRING
}
attribute {
name: "ceil_mode"
i: 0
type: INT
}
attribute {
name: "dilations"
s: ""
type: INTS
}
attribute {
name: "kernel_shape"
s: ""
type: INTS
}
attribute {
name: "pads"
s: ""
type: INTS
}
attribute {
name: "storage_order"
i: 0
type: INT
}
attribute {
name: "strides"
s: ""
type: INTS
}
attribute {
name: "X-types"
strings: "int8"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "float"
type: STRINGS
}
doc_string: "\n MaxPool consumes an input tensor X and applies max pooling across\n the tensor according to kernel sizes, stride sizes, and pad lengths.\n max pooling consisting of computing the max on all values of a\n subset of the input tensor according to the kernel size and downsampling the\n data into the output tensor Y for further processing. The output spatial shape will be following:\n ```\n output_spatial_shape[i] = floor((input_spatial_shape[i] + pad_shape[i] - ((kernel_spatial_shape[i] - 1) * dilations[i] + 1)) / strides_spatial_shape[i] + 1)\n ```\n or\n ```\n output_spatial_shape[i] = ceil((input_spatial_shape[i] + pad_shape[i] - ((kernel_spatial_shape[i] - 1) * dilations[i] + 1)) / strides_spatial_shape[i] + 1)\n ```\n if ceil_mode is enabled\n\n ```\n * pad_shape[i] is sum of pads along axis i\n ```\n\n `auto_pad` is a DEPRECATED attribute. If you are using them currently, the output spatial shape will be following:\n ```\n VALID: output_spatial_shape[i] = ceil((input_spatial_shape[i] - ((kernel_spatial_shape[i] - 1) * dilations[i] + 1) + 1) / strides_spatial_shape[i])\n SAME_UPPER or SAME_LOWER: output_spatial_shape[i] = ceil(input_spatial_shape[i] / strides_spatial_shape[i])\n ```\n And pad shape will be following if `SAME_UPPER` or `SAME_LOWER`:\n ```\n pad_shape[i] = (output_spatial_shape[i] - 1) * strides_spatial_shape[i] + ((kernel_spatial_shape[i] - 1) * dilations[i] + 1) - input_spatial_shape[i]\n ```\n The output of each pooling window is maximum number of elements exclude pad. \n "
----f
input: "X"
input: "rois"
output: "Y"
name: "MaxRoiPool"
op_type: "MaxRoiPool"
attribute {
name: "pooled_shape"
s: ""
type: INTS
}
attribute {
name: "spatial_scale"
f: 1.0
type: FLOAT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "rois-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\n ROI max pool consumes an input tensor X and region of interests (RoIs) to\n apply max pooling across each RoI, to produce output 4-D tensor of shape\n (num_rois, channels, pooled_shape[0], pooled_shape[1])."
----f
input: "X"
input: "I"
input: "output_shape"
output: "output"
name: "MaxUnpool"
op_type: "MaxUnpool"
attribute {
name: "kernel_shape"
s: ""
type: INTS
}
attribute {
name: "pads"
s: ""
type: INTS
}
attribute {
name: "strides"
s: ""
type: INTS
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "I-types"
strings: "int64"
type: STRINGS
}
attribute {
name: "output_shape-types"
strings: "int64"
type: STRINGS
}
doc_string: "\nMaxUnpool essentially computes the partial inverse of the MaxPool op.\n The input information to this op is typically the the output information from a MaxPool op. The first\n input tensor X is the tensor that needs to be unpooled, which is typically the pooled tensor (first output)\n from MaxPool. The second input tensor, I, contains the indices to the (locally maximal) elements corrsponding\n to the elements in the first input tensor X. Input tensor I is typically the second output of the MaxPool op.\n The third (optional) input is a tensor that specifies the output size of the unpooling operation.\n\nMaxUnpool is intended to do \'partial\' inverse of the MaxPool op. \'Partial\' because all the non-maximal\n values from the original input to MaxPool are set to zero in the output of the MaxUnpool op. Pooling\n the result of an unpooling operation should give back the original input to the unpooling op.\n\nMaxUnpool can produce the same output size for several input sizes, which makes unpooling op ambiguous.\n The third input argument, output_size, is meant to disambiguate the op and produce output tensor of\n known/predictable size.\n\nIn addition to the inputs, MaxUnpool takes three attributes, namely kernel_shape, strides, and pads,\n which define the exact unpooling op. The attributes typically have the same values as the corrsponding\n pooling op that the unpooling op is trying to invert.\n"
----f
input: "data_0"
output: "mean"
name: "Mean"
op_type: "Mean"
attribute {
name: "data_0-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nElement-wise mean of each of the input tensors (with Numpy-style broadcasting support).\nAll inputs and outputs must have the same data type.\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "X"
output: "Y"
name: "MeanVarianceNormalization"
op_type: "MeanVarianceNormalization"
attribute {
name: "axes"
ints: 0
ints: 2
ints: 3
type: INTS
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\n A MeanVarianceNormalization Function: Perform mean variance normalization\n on the input tensor X using formula: <br/> ``` (X-EX)/sqrt(E(X-EX)^2) ```\n"
----f
input: "data_0"
output: "min"
name: "Min"
op_type: "Min"
attribute {
name: "data_0-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nElement-wise min of each of the input tensors (with Numpy-style broadcasting support).\nAll inputs and outputs must have the same data type.\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "A"
input: "B"
output: "C"
name: "Mod"
op_type: "Mod"
attribute {
name: "fmod"
i: 0
type: INT
}
attribute {
name: "A-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "B-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\n Performs element-wise binary modulus (with Numpy-style broadcasting support). \n The sign of the remainder is the same as that of the Divisor.\n \n Mod operator can also behave like C fmod() or numpy.fmod. In this case, the sign of the remainder however, will be the same as the Dividend \n (in contrast to integer mod). To force a behavior like numpy.fmod() an \'fmod\' Attribute is provided.\n This attribute is set to 0 by default causing the behavior to be like integer mod. \n Setting this attribute to 1 causes the remainder to be calculated similar to that of numpy.fmod().\n\n If the input type is floating point, then `fmod` attribute must be set to 1.\n \n In case of dividend being zero, the results will be platform dependent.\n\n This operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "R"
input: "T"
input: "inputs"
output: "outputs"
name: "Momentum"
op_type: "Momentum"
attribute {
name: "alpha"
s: ""
type: FLOAT
}
attribute {
name: "beta"
s: ""
type: FLOAT
}
attribute {
name: "mode"
s: ""
type: STRING
}
attribute {
name: "norm_coefficient"
s: ""
type: FLOAT
}
attribute {
name: "R-types"
strings: "float"
strings: "double"
type: STRINGS
}
attribute {
name: "T-types"
strings: "int64"
type: STRINGS
}
attribute {
name: "inputs-types"
strings: "float"
strings: "double"
type: STRINGS
}
doc_string: "\n Compute one iteration of stochastic gradient update with momentum.\n This operator can conduct the optimization of multiple tensor variables.\n\n Let\'s define the behavior of this operator. As you can imagine, SG with momentum requires\n several parameters:\n \n - The learning-rate \"R\".\n - The update count \"T\". That is, the number of conducted training iterations. It should\n be zero in the first training iteration.\n - A L2-norm regularization coefficient \"norm_coefficient\".\n - A decay coefficient of previous accumulated gradient (i.e., momentum) \"alpha\".\n - The scaling coefficient of current gradient \"beta\".\n - An attribute to choose either standard momentum or Nesterov\'s momentum \"mode\" should\n be used.\n\n For the sake of simplicity, assume that there is only one tensor (called \"X\") to be optimized.\n Other necessary inputs are \"X\"\'s gradient (called \"G\") and \"X\"\'s momentum (called \"V\"). This\n Momentum operator maps all these inputs to the new value of \"X\" (called \"X_new\") and its new\n momentum (called \"V_new\").\n \n This operator supports two different momentum algorithms. Set the attribute \"mode\" to\n \"nesterov\" if Nesterov\'s momentum is desired. Otherwise, set the attribute \"model\" to\n \"standard\" to use standard momentum. Computation details are described subsequently.\n\n Let \"+\", \"-\", \"*\", and \"/\" are all element-wise operations with numpy-style broadcasting.\n\n Pseudo code for SG with standard momentum:\n\n // Add gradient of 0.5 * norm_coefficient * ||X||^2, where ||X|| is the sum of squared\n // values of all elements in X.\n G_regularized = norm_coefficient * X + G\n\n // In the first training iteration, beta should always be 1.\n beta_adjusted = T > 0 ? beta : 1\n\n // Compute the current momentum based on previous momentum and the current gradient.\n V_new = alpha * V + beta_adjusted * G_regularized\n\n // Update X.\n X_new = X - R * V_new\n\n Pseudo code for SG with Nesterov\'s momentum:\n\n // Add gradient of 0.5 * norm_coefficient * ||X||^2, where ||X|| is the sum of squared\n // values of all elements in X.\n G_regularized = norm_coefficient * X + G;\n\n // In the first training iteration, beta should always be 1.\n beta_adjusted = T > 0 ? beta : 1\n\n // Compute the current momentum based on previous momentum and the current gradient.\n V_new = alpha * V + beta_adjusted * G_regularized;\n\n // Compute final update direction and then update X.\n X_new = X - R * (G_regularized + alpha * V_new)\n\n If one assign this operators to optimize multiple inputs, for example, \"X_1\" and \"X_2\". The same\n pseudo code would be extended to handle all tensors jointly. More specifically, we can view \"X\" as a\n concatenation of \"X_1\" and \"X_2\" (of course, their gradient and accumulate gradient should\n be concatenated too) and then our pseudo code becomes applicable.\n"
----f
input: "A"
input: "B"
output: "C"
name: "Mul"
op_type: "Mul"
attribute {
name: "A-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
attribute {
name: "B-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nPerforms element-wise binary multiplication (with Numpy-style broadcasting support).\n\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "input"
output: "output"
name: "Multinomial"
op_type: "Multinomial"
attribute {
name: "dtype"
i: 6
type: INT
}
attribute {
name: "sample_size"
i: 1
type: INT
}
attribute {
name: "seed"
s: ""
type: FLOAT
}
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nGenerate a tensor of samples from a multinomial distribution according to the probabilities\nof each of the possible outcomes.\n"
----f
input: "X"
output: "Y"
name: "Neg"
op_type: "Neg"
attribute {
name: "X-types"
strings: "int8"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "float"
strings: "int16"
type: STRINGS
}
doc_string: "\nNeg takes one input data (Tensor<T>) and produces one output data\n(Tensor<T>) where each element flipped sign, y = -x, is applied to\nthe tensor elementwise.\n"
----f
input: "input"
input: "target"
input: "weight"
output: "loss"
name: "NegativeLogLikelihoodLoss"
op_type: "NegativeLogLikelihoodLoss"
attribute {
name: "ignore_index"
s: ""
type: INT
}
attribute {
name: "reduction"
s: "mean"
type: STRING
}
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "target-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
attribute {
name: "weight-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nA NegativeLogLikelihoodLoss operator computes (weighted) negative log likelihood loss.\nIts \"input\" tensor has the shape of (N, C, d1, d2, ..., dk) where k >= 0.\nThe \"input\" tensor contains log-probabilities for input[n, :, d_1, d_2,..., d_k] being in a class of [0, C).\nThe operator\'s \"target\" input tensor has the shape of (N, d1, d2, ..., dk). It encodes class labels (one of C classes)\nor it may contain a special value (indicated by an attribute ignore_index) for N x d1 x d2 x ... x dk samples.\nThe loss value for input[n, :, d_1, d_2,...d_k] being classified as class c = target[n][d_1][d_2]...[d_k] is computed as:\n\n loss[n][d_1][d_2]...[d_k] = -input[n][c][d_1][d_2]...[d_k].\n\nWhen an optional \"weight\" is provided, the sample loss is calculated as:\n\n loss[n][d_1][d_2]...[d_k] = -input[n][c][d_1][d_2]...[d_k] * weight[c].\n\nloss is zero for the case when target-value equals ignore_index.\n \n loss[n][d_1][d_2]...[d_k] = 0, when target[n][d_1][d_2]...[d_k] = ignore_index\n\nIf \"reduction\" attribute is set to \"none\", the operator\'s output will be the above loss with shape (N, d1, d2, ..., dk).\nIf \"reduction\" attribute is set to \"mean\" (the default attribute value), the output loss is (weight) averaged:\n\n mean(loss), if \"weight\" is not provided,\n\nor if weight is provided,\n\n sum(loss) / sum(weight[target[n][d_1][d_2]...[d_k]]]), for all samples.\n\nIf \"reduction\" attribute is set to \"sum\", the output is a scalar:\n sum(loss).\n\nSee also https://pytorch.org/docs/stable/nn.html#torch.nn.NLLLoss.\n\nExample 1:\n\n // negative log likelihood loss, \"none\" reduction\n N, C, d1 = 2, 3, 2\n input = [[[1.0, 2.0], [2.0, 2.0], [3.0, 2.0]],\n [[0.0, 1.0], [2.0, 2.0], [1.0, 2]]]\n target = [[2, 1], [0, 2]]\n\n loss = np.zeros((N, d1))\n for n in range(N):\n for d_1 in range(d1):\n c = target[n][d_1]\n loss[n][d_1] = -input[n][c][d_1]\n\n // print(loss)\n // [[-3. -2.]\n // [-0. -2.]]\n\nExample 2:\n\n // weighted negative log likelihood loss, sum reduction\n N, C, d1 = 2, 3, 2\n input = [[[1.0, 2.0], [2.0, 2.0], [3.0, 2.0]],\n [[0.0, 1.0], [2.0, 2.0], [1.0, 2]]]\n target = [[2, 1], [0, 2]]\n weight = [0.2, 0.3, 0.1]\n loss = np.zeros((N, d1))\n for n in range(N):\n for d_1 in range(d1):\n c = target[n][d_1]\n loss[n][d_1] = -input[n][c][d_1] * weight[c]\n\n loss = np.sum(loss)\n // print(loss)\n // -1.1\n\nExample 3:\n\n // weighted negative log likelihood loss, mean reduction\n N, C, d1 = 2, 3, 2\n input = [[[1.0, 2.0], [2.0, 2.0], [3.0, 2.0]],\n [[0.0, 1.0], [2.0, 2.0], [1.0, 2]]]\n target = [[2, 1], [0, 2]]\n weight = [0.2, 0.3, 0.1]\n loss = np.zeros((N, d1))\n weight_total = 0\n for n in range(N):\n for d_1 in range(d1):\n c = target[n][d_1]\n loss[n][d_1] = -input[n][c][d_1] * weight[c]\n weight_total = weight_total + weight[c]\n\n loss = np.sum(loss) / weight_total\n // print(loss)\n // -1.57\n"
----f
input: "boxes"
input: "scores"
input: "max_output_boxes_per_class"
input: "iou_threshold"
input: "score_threshold"
output: "selected_indices"
name: "NonMaxSuppression"
op_type: "NonMaxSuppression"
attribute {
name: "center_point_box"
i: 0
type: INT
}
attribute {
name: "boxes-types"
strings: "float"
type: STRINGS
}
attribute {
name: "scores-types"
strings: "float"
type: STRINGS
}
attribute {
name: "max_output_boxes_per_class-types"
strings: "int64"
type: STRINGS
}
attribute {
name: "iou_threshold-types"
strings: "float"
type: STRINGS
}
attribute {
name: "score_threshold-types"
strings: "float"
type: STRINGS
}
doc_string: "\nFilter out boxes that have high intersection-over-union (IOU) overlap with previously selected boxes.\nBounding boxes with score less than score_threshold are removed. Bounding box format is indicated by attribute center_point_box.\nNote that this algorithm is agnostic to where the origin is in the coordinate system and more generally is invariant to\northogonal transformations and translations of the coordinate system; thus translating or reflections of the coordinate system\nresult in the same boxes being selected by the algorithm.\nThe selected_indices output is a set of integers indexing into the input collection of bounding boxes representing the selected boxes.\nThe bounding box coordinates corresponding to the selected indices can then be obtained using the Gather or GatherND operation.\n"
----f
input: "X"
output: "Y"
name: "NonZero"
op_type: "NonZero"
attribute {
name: "X-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\n Returns the indices of the elements that are non-zero\n (in row-major order - by dimension).\n NonZero behaves similar to numpy.nonzero:\n https://docs.scipy.org/doc/numpy/reference/generated/numpy.nonzero.html\n"
----f
input: "X"
output: "Y"
name: "Normalizer"
op_type: "Normalizer"
attribute {
name: "norm"
s: "MAX"
type: STRING
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\n Normalize the input. There are three normalization modes, which have the corresponding formulas,\n defined using element-wise infix operators \'/\' and \'^\' and tensor-wide functions \'max\' and \'sum\':<br>\n<br>\n Max: Y = X / max(X)<br>\n L1: Y = X / sum(X)<br>\n L2: Y = sqrt(X^2 / sum(X^2)}<br>\n In all modes, if the divisor is zero, Y == X.\n<br>\n For batches, that is, [N,C] tensors, normalization is done along the C axis. In other words, each row\n of the batch is normalized independently.\n"
----f
input: "X"
output: "Y"
name: "Not"
op_type: "Not"
attribute {
name: "X-types"
strings: "bool"
type: STRINGS
}
doc_string: "\nReturns the negation of the input tensor element-wise.\n"
----f
input: "indices"
input: "depth"
input: "values"
output: "output"
name: "OneHot"
op_type: "OneHot"
attribute {
name: "axis"
i: -1
type: INT
}
attribute {
name: "indices-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "depth-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "values-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\n Produces a one-hot tensor based on inputs.\n The locations represented by the index values in the \'indices\' input tensor will have \'on_value\'\n and the other locations will have \'off_value\' in the output tensor, where \'on_value\' and \'off_value\'\n are specified as part of required input argument \'values\', which is a two-element tensor of format\n [off_value, on_value]. The rank of the output tensor will be one greater than the rank of the\n input tensor. The additional dimension is for one-hot representation. The additional dimension will\n be inserted at the position specified by \'axis\'. If \'axis\' is not specified then then additional\n dimension will be inserted as the innermost dimension, i.e. axis=-1. The size of the additional\n dimension is specified by required scalar input \'depth\'. The type of the output tensor is the same\n as the type of the \'values\' input. Any entries in the \'indices\' input tensor with values outside\n the range [-depth, depth-1] will result in one-hot representation with all \'off_value\' values in the\n output tensor.\n\n when axis = 0:\n output[input[i, j, k], i, j, k] = 1 for all i, j, k and 0 otherwise.\n\n when axis = -1:\n output[i, j, k, input[i, j, k]] = 1 for all i, j, k and 0 otherwise.\n\n"
----f
input: "X"
output: "Y"
name: "OneHotEncoder"
op_type: "OneHotEncoder"
attribute {
name: "cats_int64s"
s: ""
type: INTS
}
attribute {
name: "cats_strings"
s: ""
type: STRINGS
}
attribute {
name: "zeros"
i: 1
type: INT
}
attribute {
name: "X-types"
strings: "int32"
strings: "string"
strings: "double"
strings: "int64"
strings: "float"
type: STRINGS
}
doc_string: "\n Replace each input element with an array of ones and zeros, where a single\n one is placed at the index of the category that was passed in. The total category count \n will determine the size of the extra dimension of the output array Y.<br>\n For example, if we pass a tensor with a single value of 4, and a category count of 8, \n the output will be a tensor with ``[0,0,0,0,1,0,0,0]``.<br>\n This operator assumes every input feature is from the same set of categories.<br>\n If the input is a tensor of float, int32, or double, the data will be cast\n to integers and the cats_int64s category list will be used for the lookups.\n"
----f
input: "A"
input: "B"
output: "C"
name: "Or"
op_type: "Or"
attribute {
name: "A-types"
strings: "bool"
type: STRINGS
}
attribute {
name: "B-types"
strings: "bool"
type: STRINGS
}
doc_string: "\nReturns the tensor resulted from performing the `or` logical operation\nelementwise on the input tensors `A` and `B` (with Numpy-style broadcasting support).\n\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "X"
input: "slope"
output: "Y"
name: "PRelu"
op_type: "PRelu"
attribute {
name: "X-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
attribute {
name: "slope-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nPRelu takes input data (Tensor<T>) and slope tensor as input, and produces one\noutput data (Tensor<T>) where the function `f(x) = slope * x for x < 0`,\n`f(x) = x for x >= 0`., is applied to the data tensor elementwise.\nThis operator supports **unidirectional broadcasting** (tensor slope should be unidirectional broadcastable to input tensor X); for more details please check [the doc](Broadcasting.md)."
----f
input: "data"
input: "pads"
input: "constant_value"
output: "output"
name: "Pad"
op_type: "Pad"
attribute {
name: "mode"
s: "constant"
type: STRING
}
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "pads-types"
strings: "int64"
type: STRINGS
}
attribute {
name: "constant_value-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nGiven a tensor containing the data to be padded (`data`), a tensor containing the number of start and end pad values for axis (`pads`), (optionally) a `mode`, and (optionally) `constant_value`, \na padded tensor (`output`) is generated.\n\nThe three supported `modes` are (similar to corresponding modes supported by `numpy.pad`):\n\n1) `constant`(default) - pads with a given constant value as specified by `constant_value` (which defaults to 0)\n\n2) `reflect` - pads with the reflection of the vector mirrored on the first and last values of the vector along each axis\n\n3) `edge` - pads with the edge values of array\n\n\nExample 1 (`constant` mode):\n Insert 0 pads to the beginning of the second dimension.\n\n data = \n [\n [1.0, 1.2],\n [2.3, 3.4],\n [4.5, 5.7],\n ] \n\n pads = [0, 2, 0, 0]\n\n mode = \'constant\'\n\n constant_value = 0.0\n\n output = \n [\n [\n [0.0, 0.0, 1.0, 1.2],\n [0.0, 0.0, 2.3, 3.4],\n [0.0, 0.0, 4.5, 5.7],\n ],\n ]\n\n\nExample 2 (`reflect` mode):\n data = \n [\n [1.0, 1.2],\n [2.3, 3.4],\n [4.5, 5.7],\n ] \n\n pads = [0, 2, 0, 0]\n\n mode = \'reflect\'\n\n output = \n [\n [\n [1.0, 1.2, 1.0, 1.2],\n [2.3, 3.4, 2.3, 3.4],\n [4.5, 5.7, 4.5, 5.7],\n ],\n ]\n\n\nExample 3 (`edge` mode):\n data = \n [\n [1.0, 1.2],\n [2.3, 3.4],\n [4.5, 5.7],\n ] \n\n pads = [0, 2, 0, 0]\n\n mode = \'edge\'\n\n output = \n [\n [\n [1.0, 1.0, 1.0, 1.2],\n [2.3, 2.3, 2.3, 3.4],\n [4.5, 4.5, 4.5, 5.7],\n ],\n ]\n\n"
----f
input: "X"
input: "Y"
output: "Z"
name: "Pow"
op_type: "Pow"
attribute {
name: "X-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "float"
type: STRINGS
}
attribute {
name: "Y-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nPow takes input data (Tensor<T>) and exponent Tensor, and\nproduces one output data (Tensor<T>) where the function `f(x) = x^exponent`,\nis applied to the data tensor elementwise.\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md)."
----f
input: "x"
input: "x_scale"
input: "x_zero_point"
input: "w"
input: "w_scale"
input: "w_zero_point"
input: "y_scale"
input: "y_zero_point"
input: "B"
output: "y"
name: "QLinearConv"
op_type: "QLinearConv"
attribute {
name: "auto_pad"
s: "NOTSET"
type: STRING
}
attribute {
name: "dilations"
s: ""
type: INTS
}
attribute {
name: "group"
i: 1
type: INT
}
attribute {
name: "kernel_shape"
s: ""
type: INTS
}
attribute {
name: "pads"
s: ""
type: INTS
}
attribute {
name: "strides"
s: ""
type: INTS
}
attribute {
name: "x-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "x_scale-types"
strings: "float"
type: STRINGS
}
attribute {
name: "x_zero_point-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "w-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "w_scale-types"
strings: "float"
type: STRINGS
}
attribute {
name: "w_zero_point-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "y_scale-types"
strings: "float"
type: STRINGS
}
attribute {
name: "y_zero_point-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "B-types"
strings: "int32"
type: STRINGS
}
doc_string: "\nThe convolution operator consumes a quantized input tensor, its scale and zero point,\na quantized filter, its scale and zero point, and output\'s scale and zero point,\nand computes the quantized output. Each scale and zero-point pair must have same shape.\nIt means they must be either scalars (per tensor) or 1-D tensors (per output channel).\nEach input or output and its related zero point must have same type.\nWhen bias is present it must be quantized using scale = input scale * weight scale and \nzero point as 0.\n"
----f
input: "a"
input: "a_scale"
input: "a_zero_point"
input: "b"
input: "b_scale"
input: "b_zero_point"
input: "y_scale"
input: "y_zero_point"
output: "y"
name: "QLinearMatMul"
op_type: "QLinearMatMul"
attribute {
name: "a-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "a_scale-types"
strings: "float"
type: STRINGS
}
attribute {
name: "a_zero_point-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "b-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "b_scale-types"
strings: "float"
type: STRINGS
}
attribute {
name: "b_zero_point-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
attribute {
name: "y_scale-types"
strings: "float"
type: STRINGS
}
attribute {
name: "y_zero_point-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
doc_string: "\nMatrix product that behaves like numpy.matmul: https://docs.scipy.org/doc/numpy-1.13.0/reference/generated/numpy.matmul.html.\nIt consumes two quantized input tensors, their scales and zero points, scale and zero point of output, and computes the quantized output.\nThe quantization formula is y = saturate((x / y_scale) + y_zero_point). For (x / y_scale), it is rounding to nearest ties to even.\nRefer to https://en.wikipedia.org/wiki/Rounding for details. Scale and zero point must have same shape.\nThey must be either scalar (per tensor) or 1-D tensor (per row for \'a\' and per column for \'b\'). If scale and zero point are 1-D tensor,\nthe number of elements of scale and zero point tensor of input \'a\' and output \'y\' should be equal to the number of rows of input \'a\',\nand the number of elements of scale and zero point tensor of input \'b\' should be equal to the number of columns of input \'b\'.\nProduction must never overflow, and accumulation may overflow if and only if in 32 bits.\n"
----f
input: "x"
input: "y_scale"
input: "y_zero_point"
output: "y"
name: "QuantizeLinear"
op_type: "QuantizeLinear"
attribute {
name: "x-types"
strings: "float"
strings: "int32"
type: STRINGS
}
attribute {
name: "y_scale-types"
strings: "float"
type: STRINGS
}
attribute {
name: "y_zero_point-types"
strings: "int8"
strings: "uint8"
type: STRINGS
}
doc_string: "\nThe linear per-tensor/layer quantization operator. It consumes a high precision tensor, a scale, a zero point to compute the low precision / quantized tensor.\nThe quantization formula is y = saturate ((x / y_scale) + y_zero_point). For saturation, it saturates to [0, 255] if it\'s uint8, or [-128, 127] if it\'s int8.\nFor (x / y_scale), it\'s rounding to nearest ties to even. Refer to https://en.wikipedia.org/wiki/Rounding for details. \'y_zero_point\' and \'y\' must have same type.\n"
----f
input: "X"
input: "W"
input: "R"
input: "B"
input: "sequence_lens"
input: "initial_h"
output: "Y"
output: "Y_h"
name: "RNN"
op_type: "RNN"
attribute {
name: "activation_alpha"
s: ""
type: FLOATS
}
attribute {
name: "activation_beta"
s: ""
type: FLOATS
}
attribute {
name: "activations"
strings: "Tanh"
strings: "Tanh"
type: STRINGS
}
attribute {
name: "clip"
s: ""
type: FLOAT
}
attribute {
name: "direction"
s: "forward"
type: STRING
}
attribute {
name: "hidden_size"
s: ""
type: INT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "W-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "R-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "B-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "sequence_lens-types"
strings: "int32"
type: STRINGS
}
attribute {
name: "initial_h-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nComputes an one-layer simple RNN. This operator is usually supported\nvia some custom implementation such as CuDNN.\n\nNotations:\n\n`X` - input tensor\n\n`i` - input gate\n\n`t` - time step (t-1 means previous time step)\n\n`Wi` - W parameter weight matrix for input gate\n\n`Ri` - R recurrence weight matrix for input gate\n\n`Wbi` - W parameter bias vector for input gate\n\n`Rbi` - R parameter bias vector for input gate\n\n`WBi` - W parameter weight matrix for backward input gate\n\n`RBi` - R recurrence weight matrix for backward input gate\n\n`WBbi` - WR bias vectors for backward input gate\n\n`RBbi` - RR bias vectors for backward input gate\n\n`H` - Hidden state\n\n`num_directions` - 2 if direction == bidirectional else 1\n\nActivation functions:\n\n Relu(x) - max(0, x)\n\n Tanh(x) - (1 - e^{-2x})/(1 + e^{-2x})\n\n Sigmoid(x) - 1/(1 + e^{-x})\n\n (NOTE: Below are optional)\n\n Affine(x) - alpha*x + beta\n\n LeakyRelu(x) - x if x >= 0 else alpha * x\n\n ThresholdedRelu(x) - x if x >= alpha else 0\n\n ScaledTanh(x) - alpha*Tanh(beta*x)\n\n HardSigmoid(x) - min(max(alpha*x + beta, 0), 1)\n\n Elu(x) - x if x >= 0 else alpha*(e^x - 1)\n\n Softsign(x) - x/(1 + |x|)\n\n Softplus(x) - log(1 + e^x)\n\nEquations (Default: f=Tanh):\n\n - Ht = f(Xt*(Wi^T) + Ht-1*(Ri^T) + Wbi + Rbi)\nThis operator has **optional** inputs/outputs. See [the doc](IR.md) for more details about the representation of optional arguments. An empty string may be used in the place of an actual argument\'s name to indicate a missing argument. Trailing optional arguments (those not followed by an argument that is present) may also be simply omitted.\n"
----f
output: "output"
name: "RandomNormal"
op_type: "RandomNormal"
attribute {
name: "dtype"
i: 1
type: INT
}
attribute {
name: "mean"
f: 0.0
type: FLOAT
}
attribute {
name: "scale"
f: 1.0
type: FLOAT
}
attribute {
name: "seed"
s: ""
type: FLOAT
}
attribute {
name: "shape"
s: ""
type: INTS
}
doc_string: "\nGenerate a tensor with random values drawn from a normal distribution. The shape\nof the tensor is specified by the `shape` argument and the parameter of the normal distribution\nspecified by `mean` and `scale`.\n\nThe data type is specified by the \'dtype\' argument. The \'dtype\' argument must\nbe one of the data types specified in the \'DataType\' enum field in the\nTensorProto message.\n"
----f
input: "input"
output: "output"
name: "RandomNormalLike"
op_type: "RandomNormalLike"
attribute {
name: "dtype"
s: ""
type: INT
}
attribute {
name: "mean"
f: 0.0
type: FLOAT
}
attribute {
name: "scale"
f: 1.0
type: FLOAT
}
attribute {
name: "seed"
s: ""
type: FLOAT
}
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nGenerate a tensor with random values drawn from a normal distribution.\nThe shape of the output tensor is copied from the shape of the input tensor,\nand the parameters of the normal distribution are specified by `mean` and `scale`.\n\nThe data type is specified by the \'dtype\' argument, or copied from the input tensor if not provided.\nThe \'dtype\' argument must be one of the data types specified in the \'DataType\' enum field in the\nTensorProto message, and be valid as an output type.\n"
----f
output: "output"
name: "RandomUniform"
op_type: "RandomUniform"
attribute {
name: "dtype"
i: 1
type: INT
}
attribute {
name: "high"
f: 1.0
type: FLOAT
}
attribute {
name: "low"
f: 0.0
type: FLOAT
}
attribute {
name: "seed"
s: ""
type: FLOAT
}
attribute {
name: "shape"
s: ""
type: INTS
}
doc_string: "\nGenerate a tensor with random values drawn from a uniform distribution. The shape\nof the tensor is specified by the `shape` argument and the range by `low` and `high`.\n\nThe data type is specified by the \'dtype\' argument. The \'dtype\' argument must\nbe one of the data types specified in the \'DataType\' enum field in the\nTensorProto message.\n"
----f
input: "input"
output: "output"
name: "RandomUniformLike"
op_type: "RandomUniformLike"
attribute {
name: "dtype"
s: ""
type: INT
}
attribute {
name: "high"
f: 1.0
type: FLOAT
}
attribute {
name: "low"
f: 0.0
type: FLOAT
}
attribute {
name: "seed"
s: ""
type: FLOAT
}
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nGenerate a tensor with random values drawn from a uniform distribution.\nThe shape of the output tensor is copied from the shape of the input tensor,\nand the parameters of the uniform distribution are specified by `low` and `high`.\n\nThe data type is specified by the \'dtype\' argument, or copied from the input tensor if not provided.\nThe \'dtype\' argument must be one of the data types specified in the \'DataType\' enum field in the\nTensorProto message and be valid as an output type.\n"
----f
input: "start"
input: "limit"
input: "delta"
output: "output"
name: "Range"
op_type: "Range"
attribute {
name: "start-types"
strings: "int32"
strings: "double"
strings: "int64"
strings: "float"
strings: "int16"
type: STRINGS
}
attribute {
name: "limit-types"
strings: "int32"
strings: "double"
strings: "int64"
strings: "float"
strings: "int16"
type: STRINGS
}
attribute {
name: "delta-types"
strings: "int32"
strings: "double"
strings: "int64"
strings: "float"
strings: "int16"
type: STRINGS
}
doc_string: "\nGenerate a tensor containing a sequence of numbers that begin at `start` and extends by increments of `delta`\nup to `limit` (exclusive).\n\nThe number of elements in the output of range is computed as below-\n\n`number_of_elements = max( ceil( (limit - start) / delta ) , 0 )`\n\nThe pseudocode determining the contents of the output is shown below-\n\n`for(int i=0; i<number_of_elements; ++i)`\n\n`{`\n\n` output[i] = start + (i * delta); `\n\n`}`\n\n`Example 1`\nInputs: start = 3, limit = 9, delta = 3\nOutput: [3, 6]\n\n`Example 2`\nInputs: start = 10, limit = 4, delta = -2\nOutput: [10, 8, 6]\n\n"
----f
input: "X"
output: "Y"
name: "Reciprocal"
op_type: "Reciprocal"
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nReciprocal takes one input data (Tensor<T>) and produces one output data\n(Tensor<T>) where the reciprocal is, y = 1/x, is applied to\nthe tensor elementwise.\n"
----f
input: "data"
output: "reduced"
name: "ReduceL1"
op_type: "ReduceL1"
attribute {
name: "axes"
s: ""
type: INTS
}
attribute {
name: "keepdims"
i: 1
type: INT
}
attribute {
name: "data-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nComputes the L1 norm of the input tensor\'s element along the provided axes. The resulted\ntensor has the same rank as the input if keepdims equal 1. If keepdims equal 0, then\nthe resulted tensor have the reduced dimension pruned.\n\nThe above behavior is similar to numpy, with the exception that numpy default keepdims to\nFalse instead of True."
----f
input: "data"
output: "reduced"
name: "ReduceL2"
op_type: "ReduceL2"
attribute {
name: "axes"
s: ""
type: INTS
}
attribute {
name: "keepdims"
i: 1
type: INT
}
attribute {
name: "data-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nComputes the L2 norm of the input tensor\'s element along the provided axes. The resulted\ntensor has the same rank as the input if keepdims equal 1. If keepdims equal 0, then\nthe resulted tensor have the reduced dimension pruned.\n\nThe above behavior is similar to numpy, with the exception that numpy default keepdims to\nFalse instead of True."
----f
input: "data"
output: "reduced"
name: "ReduceLogSum"
op_type: "ReduceLogSum"
attribute {
name: "axes"
s: ""
type: INTS
}
attribute {
name: "keepdims"
i: 1
type: INT
}
attribute {
name: "data-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nComputes the log sum of the input tensor\'s element along the provided axes. The resulted\ntensor has the same rank as the input if keepdims equal 1. If keepdims equal 0, then\nthe resulted tensor have the reduced dimension pruned.\n\nThe above behavior is similar to numpy, with the exception that numpy default keepdims to\nFalse instead of True."
----f
input: "data"
output: "reduced"
name: "ReduceLogSumExp"
op_type: "ReduceLogSumExp"
attribute {
name: "axes"
s: ""
type: INTS
}
attribute {
name: "keepdims"
i: 1
type: INT
}
attribute {
name: "data-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nComputes the log sum exponent of the input tensor\'s element along the provided axes. The resulted\ntensor has the same rank as the input if keepdims equal 1. If keepdims equal 0, then\nthe resulted tensor have the reduced dimension pruned.\n\nThe above behavior is similar to numpy, with the exception that numpy default keepdims to\nFalse instead of True."
----f
input: "data"
output: "reduced"
name: "ReduceMax"
op_type: "ReduceMax"
attribute {
name: "axes"
s: ""
type: INTS
}
attribute {
name: "keepdims"
i: 1
type: INT
}
attribute {
name: "data-types"
strings: "int8"
strings: "float16"
strings: "int32"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nComputes the max of the input tensor\'s element along the provided axes. The resulted\ntensor has the same rank as the input if keepdims equal 1. If keepdims equal 0, then\nthe resulted tensor have the reduced dimension pruned.\n\nThe above behavior is similar to numpy, with the exception that numpy default keepdims to\nFalse instead of True."
----f
input: "data"
output: "reduced"
name: "ReduceMean"
op_type: "ReduceMean"
attribute {
name: "axes"
s: ""
type: INTS
}
attribute {
name: "keepdims"
i: 1
type: INT
}
attribute {
name: "data-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nComputes the mean of the input tensor\'s element along the provided axes. The resulted\ntensor has the same rank as the input if keepdims equal 1. If keepdims equal 0, then\nthe resulted tensor have the reduced dimension pruned.\n\nThe above behavior is similar to numpy, with the exception that numpy default keepdims to\nFalse instead of True."
----f
input: "data"
output: "reduced"
name: "ReduceMin"
op_type: "ReduceMin"
attribute {
name: "axes"
s: ""
type: INTS
}
attribute {
name: "keepdims"
i: 1
type: INT
}
attribute {
name: "data-types"
strings: "int8"
strings: "float16"
strings: "int32"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nComputes the min of the input tensor\'s element along the provided axes. The resulted\ntensor has the same rank as the input if keepdims equal 1. If keepdims equal 0, then\nthe resulted tensor have the reduced dimension pruned.\n\nThe above behavior is similar to numpy, with the exception that numpy default keepdims to\nFalse instead of True."
----f
input: "data"
output: "reduced"
name: "ReduceProd"
op_type: "ReduceProd"
attribute {
name: "axes"
s: ""
type: INTS
}
attribute {
name: "keepdims"
i: 1
type: INT
}
attribute {
name: "data-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nComputes the product of the input tensor\'s element along the provided axes. The resulted\ntensor has the same rank as the input if keepdims equal 1. If keepdims equal 0, then\nthe resulted tensor have the reduced dimension pruned.\n\nThe above behavior is similar to numpy, with the exception that numpy default keepdims to\nFalse instead of True."
----f
input: "data"
output: "reduced"
name: "ReduceSum"
op_type: "ReduceSum"
attribute {
name: "axes"
s: ""
type: INTS
}
attribute {
name: "keepdims"
i: 1
type: INT
}
attribute {
name: "data-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nComputes the sum of the input tensor\'s element along the provided axes. The resulted\ntensor has the same rank as the input if keepdims equal 1. If keepdims equal 0, then\nthe resulted tensor have the reduced dimension pruned.\n\nThe above behavior is similar to numpy, with the exception that numpy default keepdims to\nFalse instead of True."
----f
input: "data"
output: "reduced"
name: "ReduceSumSquare"
op_type: "ReduceSumSquare"
attribute {
name: "axes"
s: ""
type: INTS
}
attribute {
name: "keepdims"
i: 1
type: INT
}
attribute {
name: "data-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nComputes the sum square of the input tensor\'s element along the provided axes. The resulted\ntensor has the same rank as the input if keepdims equal 1. If keepdims equal 0, then\nthe resulted tensor have the reduced dimension pruned.\n\nThe above behavior is similar to numpy, with the exception that numpy default keepdims to\nFalse instead of True."
----f
input: "X"
output: "Y"
name: "Relu"
op_type: "Relu"
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nRelu takes one input data (Tensor<T>) and produces one output data\n(Tensor<T>) where the rectified linear function, y = max(0, x), is applied to\nthe tensor elementwise.\n"
----f
input: "data"
input: "shape"
output: "reshaped"
name: "Reshape"
op_type: "Reshape"
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "shape-types"
strings: "int64"
type: STRINGS
}
doc_string: "\nReshape the input tensor similar to numpy.reshape.\nFirst input is the data tensor, second input is a shape tensor which specifies the output shape. It outputs the reshaped tensor.\nAt most one dimension of the new shape can be -1. In this case, the value is\ninferred from the size of the tensor and the remaining dimensions. A dimension\ncould also be 0, in which case the actual dimension value is unchanged (i.e. taken\nfrom the input tensor)."
----f
input: "X"
input: "roi"
input: "scales"
input: "sizes"
output: "Y"
name: "Resize"
op_type: "Resize"
attribute {
name: "coordinate_transformation_mode"
s: "half_pixel"
type: STRING
}
attribute {
name: "cubic_coeff_a"
f: -0.75
type: FLOAT
}
attribute {
name: "exclude_outside"
i: 0
type: INT
}
attribute {
name: "extrapolation_value"
f: 0.0
type: FLOAT
}
attribute {
name: "mode"
s: "nearest"
type: STRING
}
attribute {
name: "nearest_mode"
s: "round_prefer_floor"
type: STRING
}
attribute {
name: "X-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "roi-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "scales-types"
strings: "float"
type: STRINGS
}
attribute {
name: "sizes-types"
strings: "int64"
type: STRINGS
}
doc_string: "\nResize the input tensor. In general, it calculates every value in the output tensor as a weighted average of neighborhood (a.k.a. sampling locations) in the input tensor.\nEach dimension value of the output tensor is:\n output_dimension = floor(input_dimension * (roi_end - roi_start) * scale) if input \\\"sizes\\\" is not specified.\n"
----f
input: "input"
input: "sequence_lens"
output: "Y"
name: "ReverseSequence"
op_type: "ReverseSequence"
attribute {
name: "batch_axis"
i: 1
type: INT
}
attribute {
name: "time_axis"
i: 0
type: INT
}
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "sequence_lens-types"
strings: "int64"
type: STRINGS
}
doc_string: "\nReverse batch of sequences having different lengths specified by `sequence_lens`.\n\nFor each slice i iterating on batch axis, the operator reverses the first sequence_lens[i] elements on time axis,\nand copies elements whose index\'s beyond sequence_lens[i] to the output. So the output slice i contains reversed\nsequences on the first sequence_lens[i] elements, then have original values copied for the other elements.\n\nExample 1:\n input = [[0.0, 4.0, 8.0, 12.0],\n [1.0, 5.0, 9.0, 13.0],\n [2.0, 6.0, 10.0, 14.0],\n [3.0, 7.0, 11.0, 15.0]]\n sequence_lens = [4, 3, 2, 1]\n time_axis = 0\n batch_axis = 1\n\n output = [[3.0, 6.0, 9.0, 12.0],\n [2.0, 5.0, 8.0, 13.0],\n [1.0, 4.0, 10.0, 14.0],\n [0.0, 7.0, 11.0, 15.0]]\n\nExample 2:\n input = [[0.0, 1.0, 2.0, 3.0 ],\n [4.0, 5.0, 6.0, 7.0 ],\n [8.0, 9.0, 10.0, 11.0],\n [12.0, 13.0, 14.0, 15.0]]\n sequence_lens = [1, 2, 3, 4]\n time_axis = 1\n batch_axis = 0\n\n output = [[0.0, 1.0, 2.0, 3.0 ],\n [5.0, 4.0, 6.0, 7.0 ],\n [10.0, 9.0, 8.0, 11.0],\n [15.0, 14.0, 13.0, 12.0]]\n"
----f
input: "X"
input: "rois"
input: "batch_indices"
output: "Y"
name: "RoiAlign"
op_type: "RoiAlign"
attribute {
name: "mode"
s: "avg"
type: STRING
}
attribute {
name: "output_height"
i: 1
type: INT
}
attribute {
name: "output_width"
i: 1
type: INT
}
attribute {
name: "sampling_ratio"
i: 0
type: INT
}
attribute {
name: "spatial_scale"
f: 1.0
type: FLOAT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "rois-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "batch_indices-types"
strings: "int64"
type: STRINGS
}
doc_string: "\nRegion of Interest (RoI) align operation described in the\n[Mask R-CNN paper](https://arxiv.org/abs/1703.06870).\nRoiAlign consumes an input tensor X and region of interests (rois)\nto apply pooling across each RoI; it produces a 4-D tensor of shape\n(num_rois, C, output_height, output_width).\n\nRoiAlign is proposed to avoid the misalignment by removing\nquantizations while converting from original image into feature\nmap and from feature map into RoI feature; in each ROI bin,\nthe value of the sampled locations are computed directly\nthrough bilinear interpolation.\n"
----f
input: "X"
output: "Y"
name: "Round"
op_type: "Round"
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nRound takes one input Tensor and rounds the values, element-wise, meaning\nit finds the nearest integer for each value.\nIn case of halfs, the rule is to round them to the nearest even integer.\nThe output tensor has the same shape and type as the input.\n\nExamples:\n```\nround([0.9]) = [1.0]\nround([2.5]) = [2.0]\nround([2.3]) = [2.0]\nround([1.5]) = [2.0]\nround([-4.5]) = [-4.0]\n```\n"
----f
input: "X"
output: "Y"
output: "Z"
name: "SVMClassifier"
op_type: "SVMClassifier"
attribute {
name: "classlabels_ints"
s: ""
type: INTS
}
attribute {
name: "classlabels_strings"
s: ""
type: STRINGS
}
attribute {
name: "coefficients"
s: ""
type: FLOATS
}
attribute {
name: "kernel_params"
s: ""
type: FLOATS
}
attribute {
name: "kernel_type"
s: "LINEAR"
type: STRING
}
attribute {
name: "post_transform"
s: "NONE"
type: STRING
}
attribute {
name: "prob_a"
s: ""
type: FLOATS
}
attribute {
name: "prob_b"
s: ""
type: FLOATS
}
attribute {
name: "rho"
s: ""
type: FLOATS
}
attribute {
name: "support_vectors"
s: ""
type: FLOATS
}
attribute {
name: "vectors_per_class"
s: ""
type: INTS
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\n Support Vector Machine classifier\n"
----f
input: "X"
output: "Y"
name: "SVMRegressor"
op_type: "SVMRegressor"
attribute {
name: "coefficients"
s: ""
type: FLOATS
}
attribute {
name: "kernel_params"
s: ""
type: FLOATS
}
attribute {
name: "kernel_type"
s: "LINEAR"
type: STRING
}
attribute {
name: "n_supports"
i: 0
type: INT
}
attribute {
name: "one_class"
i: 0
type: INT
}
attribute {
name: "post_transform"
s: "NONE"
type: STRING
}
attribute {
name: "rho"
s: ""
type: FLOATS
}
attribute {
name: "support_vectors"
s: ""
type: FLOATS
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\n Support Vector Machine regression prediction and one-class SVM anomaly detection.\n"
----f
input: "X"
output: "Y"
name: "Scaler"
op_type: "Scaler"
attribute {
name: "offset"
s: ""
type: FLOATS
}
attribute {
name: "scale"
s: ""
type: FLOATS
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\n Rescale input data, for example to standardize features by removing the mean and scaling to unit variance.\n"
----f
input: "initial_state_and_scan_inputs"
output: "final_state_and_scan_outputs"
name: "Scan"
op_type: "Scan"
attribute {
name: "body"
s: ""
type: GRAPH
}
attribute {
name: "num_scan_inputs"
s: ""
type: INT
}
attribute {
name: "scan_input_axes"
s: ""
type: INTS
}
attribute {
name: "scan_input_directions"
s: ""
type: INTS
}
attribute {
name: "scan_output_axes"
s: ""
type: INTS
}
attribute {
name: "scan_output_directions"
s: ""
type: INTS
}
attribute {
name: "initial_state_and_scan_inputs-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nScan can be used to iterate over one or more scan_input tensors,\nconstructing zero or more scan_output tensors. It combines ideas from general recurrences,\nfunctional programming constructs such as scan, fold, map, and zip and is intended to enable\ngeneralizations of RNN-like constructs for sequence-to-sequence processing.\nOther tensors (referred to as state_variables here) can be used to carry a state\nwhen iterating from one element to another (similar to hidden-state in RNNs, also referred\nto as loop-carried dependences in the context of loops).\nMany common usages involve a single scan_input tensor (where functionality\nsimilar to scan, fold and map can be obtained). When more than one scan_input is used,\na behavior similar to zip is obtained.\n\nThe attribute body must be a graph, specifying the computation to be performed in\nevery iteration. It takes as input the current values of the state_variables and\nthe current iterated element of the scan_inputs. It must return the (updated) values\nof the state_variables and zero or more scan_output_element tensors. The values of the\nscan_output_element tensors are concatenated over all the iterations to produce the\nscan_output values of the scan construct (similar to the concatenated intermediate\nhidden-state values of RNN-like constructs). All the output tensors (state_variables as\nwell as scan_output_element tensors) are required to have the same shape in each iteration\nof the loop (a restriction imposed to enable efficient memory allocation).\n\nNote that the iterated element passed to the body subgraph does not have a sequence\naxis. It will have a rank one less than the rank of the corresponding scan_input.\n\nThe scan operation returns the final values of the state_variables as well as the\nscan_outputs.\n\nThe optional attribute scan_input_directions specifies the direction (forward or backward)\nfor each scan input. If this attribute is omitted, all sequences are scanned in the forward\ndirection. A bidirectional scan may be performed by specifying the same tensor input twice\nin the scan_inputs, once with a forward direction, and once with a backward direction.\n\nThe scan_output of the operation is produced by concatenating the scan_output_element\nvalues produced by the body in each iteration. The optional attribute scan_output_directions\nspecifies the direction in which scan_output is constructed (by appending or prepending the\nscan_output_element to scan_output in each iteration) for each scan_output. If this attribute\nis omitted, the scan_output_element is appended to the scan_output in each iteration.\n\nThe optional attribute scan_input_axes specifies the axis to be scanned for each scan_input.\nIf omitted, every scan_input will be scanned in axis 0. For example, if axis 0 is the\nbatch axis and axis 1 is the time axis (to be scanned), specify an axis value of 1.\nNote that scanning a non-zero axis may be less efficient than scanning axis zero.\n\nThe optional attribute scan_output_axes specifies the axis along which the scan_outputs\nare accumulated for each scan_output. For example, if axis 1 is the time axis (to be\nscanned) for both inputs and outputs, specify a scan_input axis and scan_output axis\nvalue of 1.\n\nNote that because of the ONNX restriction that only the last parameter of an operator can\nbe variadic, the initial-states and scan-inputs are listed together as one input parameter.\nSimilarly, the final-states and scan-outputs are listed together as one output parameter.\nThe attribute num_scan_inputs indicates the number M of scan-inputs.\n\nThe behavior of\n\n Scan <\n num_scan_inputs = m,\n body = loop-body,\n scan_input_axes = [axis_1, ..., axis_m]\n > (init_1, ..., init_n, scan_1, ..., scan_m)\n\nis equivalent to the following pseudo-code:\n\n // scan_i.shape[axis_i] denotes the (max) sequence-length of scan_i\n // scan_i.shape[axis_i] is required to be equal to scan_j.shape[axis_j] for all i,j.\n sequence_length = scan_1.shape[axis_1];\n\n // initialize state-variab
----f
input: "data"
input: "indices"
input: "updates"
output: "output"
name: "Scatter"
op_type: "Scatter"
attribute {
name: "axis"
i: 0
type: INT
}
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "indices-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
attribute {
name: "updates-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nThis operator is deprecated. Please use ScatterElements, which provides the same functionality.\n\nScatter takes three inputs `data`, `updates`, and `indices` of the same\nrank r >= 1 and an optional attribute axis that identifies an axis of `data`\n(by default, the outer-most axis, that is axis 0). The output of the operation\nis produced by creating a copy of the input `data`, and then updating its value\nto values specified by `updates` at specific index positions specified by\n`indices`. Its output shape is the same as the shape of `data`.\n\nFor each entry in `updates`, the target index in `data` is obtained by combining\nthe corresponding entry in `indices` with the index of the entry itself: the\nindex-value for dimension = axis is obtained from the value of the corresponding\nentry in `indices` and the index-value for dimension != axis is obtained from the\nindex of the entry itself.\n\nFor instance, in a 2-D tensor case, the update corresponding to the [i][j] entry\nis performed as below:\n```\n output[indices[i][j]][j] = updates[i][j] if axis = 0, \n output[i][indices[i][j]] = updates[i][j] if axis = 1,\n```\n\nThis operator is the inverse of GatherElements. It is similar to Torch\'s Scatter operation.\n\nExample 1:\n```\n data = [\n [0.0, 0.0, 0.0],\n [0.0, 0.0, 0.0],\n [0.0, 0.0, 0.0],\n ]\n indices = [\n [1, 0, 2],\n [0, 2, 1],\n ]\n updates = [\n [1.0, 1.1, 1.2],\n [2.0, 2.1, 2.2],\n ]\n output = [\n [2.0, 1.1, 0.0]\n [1.0, 0.0, 2.2]\n [0.0, 2.1, 1.2]\n ]\n```\nExample 2:\n```\n data = [[1.0, 2.0, 3.0, 4.0, 5.0]]\n indices = [[1, 3]]\n updates = [[1.1, 2.1]]\n axis = 1\n output = [[1.0, 1.1, 3.0, 2.1, 5.0]]\n```\n"
----f
input: "data"
input: "indices"
input: "updates"
output: "output"
name: "ScatterElements"
op_type: "ScatterElements"
attribute {
name: "axis"
i: 0
type: INT
}
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "indices-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
attribute {
name: "updates-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nScatterElements takes three inputs `data`, `updates`, and `indices` of the same\nrank r >= 1 and an optional attribute axis that identifies an axis of `data`\n(by default, the outer-most axis, that is axis 0). The output of the operation\nis produced by creating a copy of the input `data`, and then updating its value\nto values specified by `updates` at specific index positions specified by\n`indices`. Its output shape is the same as the shape of `data`.\n\nFor each entry in `updates`, the target index in `data` is obtained by combining\nthe corresponding entry in `indices` with the index of the entry itself: the\nindex-value for dimension = axis is obtained from the value of the corresponding\nentry in `indices` and the index-value for dimension != axis is obtained from the\nindex of the entry itself.\n\nFor instance, in a 2-D tensor case, the update corresponding to the [i][j] entry\nis performed as below:\n```\n output[indices[i][j]][j] = updates[i][j] if axis = 0, \n output[i][indices[i][j]] = updates[i][j] if axis = 1,\n```\n\nThis operator is the inverse of GatherElements. It is similar to Torch\'s Scatter operation.\n\nExample 1:\n```\n data = [\n [0.0, 0.0, 0.0],\n [0.0, 0.0, 0.0],\n [0.0, 0.0, 0.0],\n ]\n indices = [\n [1, 0, 2],\n [0, 2, 1],\n ]\n updates = [\n [1.0, 1.1, 1.2],\n [2.0, 2.1, 2.2],\n ]\n output = [\n [2.0, 1.1, 0.0]\n [1.0, 0.0, 2.2]\n [0.0, 2.1, 1.2]\n ]\n```\nExample 2:\n```\n data = [[1.0, 2.0, 3.0, 4.0, 5.0]]\n indices = [[1, 3]]\n updates = [[1.1, 2.1]]\n axis = 1\n output = [[1.0, 1.1, 3.0, 2.1, 5.0]]\n```\n"
----f
input: "data"
input: "indices"
input: "updates"
output: "output"
name: "ScatterND"
op_type: "ScatterND"
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "indices-types"
strings: "int64"
type: STRINGS
}
attribute {
name: "updates-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nScatterND takes three inputs `data` tensor of rank r >= 1, `indices` tensor of rank q >= 1,\nand `updates` tensor of rank q + r - indices.shape[-1] - 1. The output of the operation\nis produced by creating a copy of the input `data`, and then updating its value to values\nspecified by `updates` at specific index positions specified by `indices`. Its output shape\nis the same as the shape of `data`. Note that `indices` should not have duplicate entries.\nThat is, two or more `updates` for the same index-location is not supported.\n\n`indices` is an integer tensor. Let k denote indices.shape[-1], the last dimension in the shape of `indices`.\n `indices` is treated as a (q-1)-dimensional tensor of k-tuples, where each k-tuple is a partial-index into `data`.\nHence, k can be a value at most the rank of `data`. When k equals rank(data), each update entry specifies an\nupdate to a single element of the tensor. When k is less than rank(data) each update entry specifies an\nupdate to a slice of the tensor.\n\n`updates` is treated as a (q-1)-dimensional tensor of replacement-slice-values. Thus, the\nfirst (q-1) dimensions of updates.shape must match the first (q-1) dimensions of indices.shape.\nThe remaining dimensions of `updates` correspond to the dimensions of the\nreplacement-slice-values. Each replacement-slice-value is a (r-k) dimensional tensor,\ncorresponding to the trailing (r-k) dimensions of `data`. Thus, the shape of `updates`\nmust equal indices.shape[0:q-1] ++ data.shape[k:r-1], where ++ denotes the concatenation\nof shapes.\n\nThe `output` is calculated via the following equation:\n\n output = np.copy(data)\n update_indices = indices.shape[:-1]\n for idx in np.ndindex(update_indices):\n output[indices[idx]] = updates[idx]\n\nThe order of iteration in the above loop is not specified.\nIn particular, indices should not have duplicate entries: that is, if idx1 != idx2, then indices[idx1] != indices[idx2].\nThis ensures that the output value does not depend on the iteration order.\n\nThis operator is the inverse of GatherND.\n\nExample 1:\n```\n data = [1, 2, 3, 4, 5, 6, 7, 8]\n indices = [[4], [3], [1], [7]]\n updates = [9, 10, 11, 12]\n output = [1, 11, 3, 10, 9, 6, 7, 12]\n```\n\nExample 2:\n```\n data = [[[1, 2, 3, 4], [5, 6, 7, 8], [8, 7, 6, 5], [4, 3, 2, 1]],\n [[1, 2, 3, 4], [5, 6, 7, 8], [8, 7, 6, 5], [4, 3, 2, 1]],\n [[8, 7, 6, 5], [4, 3, 2, 1], [1, 2, 3, 4], [5, 6, 7, 8]],\n [[8, 7, 6, 5], [4, 3, 2, 1], [1, 2, 3, 4], [5, 6, 7, 8]]]\n indices = [[0], [2]]\n updates = [[[5, 5, 5, 5], [6, 6, 6, 6], [7, 7, 7, 7], [8, 8, 8, 8]],\n [[1, 1, 1, 1], [2, 2, 2, 2], [3, 3, 3, 3], [4, 4, 4, 4]]]\n output = [[[5, 5, 5, 5], [6, 6, 6, 6], [7, 7, 7, 7], [8, 8, 8, 8]],\n [[1, 2, 3, 4], [5, 6, 7, 8], [8, 7, 6, 5], [4, 3, 2, 1]],\n [[1, 1, 1, 1], [2, 2, 2, 2], [3, 3, 3, 3], [4, 4, 4, 4]],\n [[8, 7, 6, 5], [4, 3, 2, 1], [1, 2, 3, 4], [5, 6, 7, 8]]]\n```\n"
----f
input: "X"
output: "Y"
name: "Selu"
op_type: "Selu"
attribute {
name: "alpha"
f: 1.6732632
type: FLOAT
}
attribute {
name: "gamma"
f: 1.050701
type: FLOAT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nSelu takes one input data (Tensor<T>) and produces one output data\n(Tensor<T>) where the scaled exponential linear unit function,\n`y = gamma * (alpha * e^x - alpha) for x <= 0`, `y = gamma * x for x > 0`,\nis applied to the tensor elementwise.\n"
----f
input: "input_sequence"
input: "position"
output: "tensor"
name: "SequenceAt"
op_type: "SequenceAt"
attribute {
name: "input_sequence-types"
strings: "seq(bool"
strings: "seq(complex128"
strings: "seq(string"
strings: "seq(float16"
strings: "seq(int64"
strings: "seq(float"
strings: "seq(int32"
strings: "seq(uint32"
strings: "seq(uint16"
strings: "seq(int8"
strings: "seq(int16"
strings: "seq(complex64"
strings: "seq(uint64"
strings: "seq(double"
strings: "seq(uint8"
type: STRINGS
}
attribute {
name: "position-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\nOutputs a tensor copy from the tensor at \'position\' in \'input_sequence\'.\nAccepted range for \'position\' is in `[-n, n - 1]`, where `n` is the number of tensors in \'input_sequence\'.\nNegative value means counting positions from the back.\n"
----f
input: "inputs"
output: "output_sequence"
name: "SequenceConstruct"
op_type: "SequenceConstruct"
attribute {
name: "inputs-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nConstruct a tensor sequence containing \'inputs\' tensors.\nAll tensors in \'inputs\' must have the same data type.\n"
----f
output: "output"
name: "SequenceEmpty"
op_type: "SequenceEmpty"
attribute {
name: "dtype"
s: ""
type: INT
}
doc_string: "\nConstruct an empty tensor sequence, with given data type.\n"
----f
input: "input_sequence"
input: "position"
output: "output_sequence"
name: "SequenceErase"
op_type: "SequenceErase"
attribute {
name: "input_sequence-types"
strings: "seq(bool"
strings: "seq(complex128"
strings: "seq(string"
strings: "seq(float16"
strings: "seq(int64"
strings: "seq(float"
strings: "seq(int32"
strings: "seq(uint32"
strings: "seq(uint16"
strings: "seq(int8"
strings: "seq(int16"
strings: "seq(complex64"
strings: "seq(uint64"
strings: "seq(double"
strings: "seq(uint8"
type: STRINGS
}
attribute {
name: "position-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\nOutputs a tensor sequence that removes the tensor at \'position\' from \'input_sequence\'.\nAccepted range for \'position\' is in `[-n, n - 1]`, where `n` is the number of tensors in \'input_sequence\'.\nNegative value means counting positions from the back.\n\'position\' is optional, by default it erases the last tensor from \'input_sequence\'.\n"
----f
input: "input_sequence"
input: "tensor"
input: "position"
output: "output_sequence"
name: "SequenceInsert"
op_type: "SequenceInsert"
attribute {
name: "input_sequence-types"
strings: "seq(bool"
strings: "seq(complex128"
strings: "seq(string"
strings: "seq(float16"
strings: "seq(int64"
strings: "seq(float"
strings: "seq(int32"
strings: "seq(uint32"
strings: "seq(uint16"
strings: "seq(int8"
strings: "seq(int16"
strings: "seq(complex64"
strings: "seq(uint64"
strings: "seq(double"
strings: "seq(uint8"
type: STRINGS
}
attribute {
name: "tensor-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "position-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\nOutputs a tensor sequence that inserts \'tensor\' into \'input_sequence\' at \'position\'.\n\'tensor\' must have the same data type as \'input_sequence\'.\nAccepted range for \'position\' is in `[-n, n]`, where `n` is the number of tensors in \'input_sequence\'.\nNegative value means counting positions from the back.\n\'position\' is optional, by default it inserts \'tensor\' to the back of \'input_sequence\'.\n"
----f
input: "input_sequence"
output: "length"
name: "SequenceLength"
op_type: "SequenceLength"
attribute {
name: "input_sequence-types"
strings: "seq(bool"
strings: "seq(complex128"
strings: "seq(string"
strings: "seq(float16"
strings: "seq(int64"
strings: "seq(float"
strings: "seq(int32"
strings: "seq(uint32"
strings: "seq(uint16"
strings: "seq(int8"
strings: "seq(int16"
strings: "seq(complex64"
strings: "seq(uint64"
strings: "seq(double"
strings: "seq(uint8"
type: STRINGS
}
doc_string: "\nProduces a scalar(tensor of empty shape) containing the number of tensors in \'input_sequence\'.\n"
----f
input: "data"
output: "shape"
name: "Shape"
op_type: "Shape"
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nTakes a tensor as input and outputs an 1D int64 tensor containing the shape of the input tensor.\n"
----f
input: "input"
output: "output"
name: "Shrink"
op_type: "Shrink"
attribute {
name: "bias"
f: 0.0
type: FLOAT
}
attribute {
name: "lambd"
f: 0.5
type: FLOAT
}
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nShrink takes one input data (Tensor<numeric>) and produces one Tensor output,\nhaving same datatype and shape with input. It has two attributes, lambd and\nbias. The formula of this operator is: If x < -lambd, y = x + bias;\nIf x > lambd, y = x - bias; Otherwise, y = 0.\n"
----f
input: "X"
output: "Y"
name: "Sigmoid"
op_type: "Sigmoid"
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nSigmoid takes one input data (Tensor<T>) and produces one output data\n(Tensor<T>) where the sigmoid function, y = 1 / (1 + exp(-x)), is applied to the\ntensor elementwise.\n"
----f
input: "input"
output: "output"
name: "Sign"
op_type: "Sign"
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nCalculate the sign of the given input tensor element-wise.\nIf input > 0, output 1. if input < 0, output -1. if input == 0, output 0.\n"
----f
input: "input"
output: "output"
name: "Sin"
op_type: "Sin"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the sine of the given input tensor, element-wise.\n"
----f
input: "input"
output: "output"
name: "Sinh"
op_type: "Sinh"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the hyperbolic sine of the given input tensor element-wise.\n"
----f
input: "data"
output: "size"
name: "Size"
op_type: "Size"
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nTakes a tensor as input and outputs a int64 scalar that equals to the total number of elements of the input tensor.\n"
----f
input: "data"
input: "starts"
input: "ends"
input: "axes"
input: "steps"
output: "output"
name: "Slice"
op_type: "Slice"
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "starts-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
attribute {
name: "ends-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
attribute {
name: "axes-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
attribute {
name: "steps-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\nProduces a slice of the input tensor along multiple axes. Similar to numpy:\nhttps://docs.scipy.org/doc/numpy/reference/arrays.indexing.html\nSlices uses `starts`, `ends`, `axes` and `steps` inputs to specify the start and end\ndimension and step for each axis in the list of axes, it uses this information to\nslice the input `data` tensor. If a negative value is passed for any of the\nstart or end indices, it represents number of elements before the end of that\ndimension. If the value passed to start or end is larger than the `n` (the\nnumber of elements in this dimension), it represents `n`. For slicing to the\nend of a dimension with unknown size, it is recommended to pass in `INT_MAX` \nwhen sclicing forward and \'INT_MIN\' when slicing backward.\nIf a negative value is passed for step, it represents slicing backward. \nHowever step value cannot be 0.\nIf `axes` are omitted, they are set to `[0, ..., ndim-1]`.\nIf `steps` are omitted, they are set to `[1, ..., 1]` of length `len(starts)`\nExample 1:\n data = [\n [1, 2, 3, 4],\n [5, 6, 7, 8],\n ]\n axes = [0, 1]\n starts = [1, 0]\n ends = [2, 3]\n steps = [1, 2]\n result = [\n [5, 7],\n ]\nExample 2:\n data = [\n [1, 2, 3, 4],\n [5, 6, 7, 8],\n ]\n starts = [0, 1]\n ends = [-1, 1000]\n result = [\n [2, 3, 4],\n ]\n"
----f
input: "input"
output: "output"
name: "Softmax"
op_type: "Softmax"
attribute {
name: "axis"
i: 1
type: INT
}
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nThe operator computes the softmax (normalized exponential) values for each layer in the batch\n of the given input.\n\nThe input does not need to explicitly be a 2D vector; rather, it will be\ncoerced into one. For an arbitrary n-dimensional tensor\ninput \\in [a_0, a_1, ..., a_{k-1}, a_k, ..., a_{n-1}] and k is\nthe axis provided, then input will be coerced into a 2-dimensional tensor with\ndimensions [a_0 * ... * a_{k-1}, a_k * ... * a_{n-1}]. For the default\ncase where axis=1, this means the input tensor will be coerced into a 2D tensor\nof dimensions [a_0, a_1 * ... * a_{n-1}], where a_0 is often the batch size.\nIn this situation, we must have a_0 = N and a_1 * ... * a_{n-1} = D.\nEach of these dimensions must be matched correctly, or else the operator\nwill throw errors. The output tensor has the same shape\nand contains the softmax values of the corresponding input.\n"
----f
input: "scores"
input: "labels"
input: "weights"
output: "output"
output: "log_prob"
name: "SoftmaxCrossEntropyLoss"
op_type: "SoftmaxCrossEntropyLoss"
attribute {
name: "ignore_index"
s: ""
type: INT
}
attribute {
name: "reduction"
s: "mean"
type: STRING
}
attribute {
name: "scores-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
attribute {
name: "labels-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
attribute {
name: "weights-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "Loss function that measures the softmax cross entropy\nbetween \'scores\' and \'labels\'.\nThis operator first computes a loss tensor whose shape is identical to the labels input.\nIf the input is 2-D with shape (N, C), the loss tensor may be a N-element vector L = (l_1, l_2, ..., l_N).\nIf the input is N-D tensor with shape (N, C, D1, D2, ..., Dk),\nthe loss tensor L may have (N, D1, D2, ..., Dk) as its shape and L[i,][j_1][j_2]...[j_k] denotes a scalar element in L.\nAfter L is available, this operator can optionally do a reduction operator.\n\nshape(scores): (N, C) where C is the number of classes, or (N, C, D1, D2,..., Dk),\n with K >= 1 in case of K-dimensional loss.\nshape(labels): (N) where each value is 0 <= labels[i] <= C-1, or (N, D1, D2,..., Dk),\n with K >= 1 in case of K-dimensional loss.\n\nThe loss for one sample, l_i, can caculated as follows:\n l[i][d1][d2]...[dk] = -y[i][c][d1][d2]..[dk], where i is the index of classes.\nor\n l[i][d1][d2]...[dk] = -y[i][c][d1][d2]..[dk] * weights[c], if \'weights\' is provided.\n\nloss is zero for the case when label-value equals ignore_index.\n l[i][d1][d2]...[dk] = 0, when labels[n][d1][d2]...[dk] = ignore_index\n\nwhere:\n p = Softmax(scores)\n y = Log(p)\n c = labels[i][d1][d2]...[dk]\n\nFinally, L is optionally reduced:\nIf reduction = \'none\', the output is L with shape (N, D1, D2, ..., Dk).\nIf reduction = \'sum\', the output is scalar: Sum(L).\nIf reduction = \'mean\', the output is scalar: ReduceMean(L), or if weight is provided: ReduceSum(L) / ReduceSum(W),\nwhere tensor W is of shape (N, D1, D2, ..., Dk) and W[n][d1][d2]...[dk] = weights[labels[i][d1][d2]...[dk]].\n"
----f
input: "X"
output: "Y"
name: "Softplus"
op_type: "Softplus"
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nSoftplus takes one input data (Tensor<T>) and produces one output data\n(Tensor<T>) where the softplus function, y = ln(exp(x) + 1), is applied to\nthe tensor elementwise.\n"
----f
input: "input"
output: "output"
name: "Softsign"
op_type: "Softsign"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the softsign (x/(1+|x|)) of the given input tensor element-wise.\n"
----f
input: "input"
output: "output"
name: "SpaceToDepth"
op_type: "SpaceToDepth"
attribute {
name: "blocksize"
s: ""
type: INT
}
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "SpaceToDepth rearranges blocks of spatial data into depth. More specifically,\nthis op outputs a copy of the input tensor where values from the height and width dimensions\nare moved to the depth dimension.\n"
----f
input: "input"
output: "outputs"
name: "Split"
op_type: "Split"
attribute {
name: "axis"
i: 0
type: INT
}
attribute {
name: "split"
s: ""
type: INTS
}
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "Split a tensor into a list of tensors, along the specified\n\'axis\'. Lengths of the parts can be specified using argument \'split\'.\nOtherwise, the tensor is split to equal sized parts.\n"
----f
input: "input"
input: "split"
output: "output_sequence"
name: "SplitToSequence"
op_type: "SplitToSequence"
attribute {
name: "axis"
i: 0
type: INT
}
attribute {
name: "keepdims"
i: 1
type: INT
}
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "split-types"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "Split a tensor into a sequence of tensors, along the specified\n\'axis\'. Lengths of the parts can be specified using argument \'split\'.\n\'split\' must contain only positive numbers.\n\'split\' is either a scalar (tensor of empty shape), or a 1-D tensor.\nIf \'split\' is a scalar, then \'input\' will be split into equally sized chunks(if possible).\nLast chunk will be smaller if the \'input\' size along the given axis \'axis\' is not divisible\nby \'split\'.\nOtherwise, the tensor is split into \'size(split)\' chunks, with lengths of the parts on \'axis\'\nspecified in \'split\'. In this scenario, the sum of entries in \'split\' must be equal to the\ndimension size of input tensor on \'axis\'.\n"
----f
input: "X"
output: "Y"
name: "Sqrt"
op_type: "Sqrt"
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nSquare root takes one input data (Tensor<T>) and produces one output data\n(Tensor<T>) where the square root is, y = x^0.5, is applied to\nthe tensor elementwise. If x is negative, then it will return NaN.\n"
----f
input: "data"
output: "squeezed"
name: "Squeeze"
op_type: "Squeeze"
attribute {
name: "axes"
s: ""
type: INTS
}
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nRemove single-dimensional entries from the shape of a tensor.\nTakes a parameter `axes` with a list of axes to squeeze.\nIf `axes` is not provided, all the single dimensions will be removed from\nthe shape. If an axis is selected with shape entry not equal to one, an error is raised.\n"
----f
input: "X"
output: "Y"
name: "StringNormalizer"
op_type: "StringNormalizer"
attribute {
name: "case_change_action"
s: "NONE"
type: STRING
}
attribute {
name: "is_case_sensitive"
i: 0
type: INT
}
attribute {
name: "locale"
s: ""
type: STRING
}
attribute {
name: "stopwords"
s: ""
type: STRINGS
}
attribute {
name: "X-types"
strings: "string"
type: STRINGS
}
doc_string: "\nStringNormalization performs string operations for basic cleaning.\nThis operator has only one input (denoted by X) and only one output\n(denoted by Y). This operator first examines the elements in the X,\nand removes elements specified in \"stopwords\" attribute.\nAfter removing stop words, the intermediate result can be further lowercased,\nuppercased, or just returned depending the \"case_change_action\" attribute.\nThis operator only accepts [C]- and [1, C]-tensor.\nIf all elements in X are dropped, the output will be the empty value of string tensor with shape [1]\nif input shape is [C] and shape [1, 1] if input shape is [1, C].\n"
----f
input: "A"
input: "B"
output: "C"
name: "Sub"
op_type: "Sub"
attribute {
name: "A-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
attribute {
name: "B-types"
strings: "float16"
strings: "int32"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "uint64"
type: STRINGS
}
doc_string: "\nPerforms element-wise binary subtraction (with Numpy-style broadcasting support).\n\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "data_0"
output: "sum"
name: "Sum"
op_type: "Sum"
attribute {
name: "data_0-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nElement-wise sum of each of the input tensors (with Numpy-style broadcasting support).\nAll inputs and outputs must have the same data type.\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "input"
output: "output"
name: "Tan"
op_type: "Tan"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the tangent of the given input tensor, element-wise.\n"
----f
input: "input"
output: "output"
name: "Tanh"
op_type: "Tanh"
attribute {
name: "input-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nCalculates the hyperbolic tangent of the given input tensor element-wise.\n"
----f
input: "X"
output: "Y"
name: "TfIdfVectorizer"
op_type: "TfIdfVectorizer"
attribute {
name: "max_gram_length"
s: ""
type: INT
}
attribute {
name: "max_skip_count"
s: ""
type: INT
}
attribute {
name: "min_gram_length"
s: ""
type: INT
}
attribute {
name: "mode"
s: ""
type: STRING
}
attribute {
name: "ngram_counts"
s: ""
type: INTS
}
attribute {
name: "ngram_indexes"
s: ""
type: INTS
}
attribute {
name: "pool_int64s"
s: ""
type: INTS
}
attribute {
name: "pool_strings"
s: ""
type: STRINGS
}
attribute {
name: "weights"
s: ""
type: FLOATS
}
attribute {
name: "X-types"
strings: "string"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\nThis transform extracts n-grams from the input sequence and save them as a vector. Input can\nbe either a 1-D or 2-D tensor. For 1-D input, output is the n-gram representation of that input.\nFor 2-D input, the output is also a 2-D tensor whose i-th row is the n-gram representation of the i-th input row.\nMore specifically, if input shape is [C], the corresponding output shape would be [max(ngram_indexes) + 1].\nIf input shape is [N, C], this operator produces a [N, max(ngram_indexes) + 1]-tensor.\n\nIn contrast to standard n-gram extraction, here, the indexes of extracting an n-gram from the original\nsequence are not necessarily consecutive numbers. The discontinuity between indexes are controlled by the number of skips.\nIf the number of skips is 2, we should skip two tokens when scanning through the original sequence.\nLet\'s consider an example. Assume that input sequence is [94, 17, 36, 12, 28] and the number of skips is 2.\nThe associated 2-grams are [94, 12] and [17, 28] respectively indexed by [0, 3] and [1, 4].\nIf the number of skips becomes 0, the 2-grams generated are [94, 17], [17, 36], [36, 12], [12, 28]\nindexed by [0, 1], [1, 2], [2, 3], [3, 4], respectively.\n\nThe output vector (denoted by Y) stores the count of each n-gram;\nY[ngram_indexes[i]] indicates the times that the i-th n-gram is found. The attribute ngram_indexes is used to determine the mapping\nbetween index i and the corresponding n-gram\'s output coordinate. If pool_int64s is [94, 17, 17, 36], ngram_indexes is [1, 0],\nngram_counts=[0, 0], then the Y[0] (first element in Y) and Y[1] (second element in Y) are the counts of [17, 36] and [94, 17],\nrespectively. An n-gram which cannot be found in pool_strings/pool_int64s should be ignored and has no effect on the output.\nNote that we may consider all skips up to S when generating the n-grams.\n\nThe examples used above are true if mode is \"TF\". If mode is \"IDF\", all the counts larger than 1 would be truncated to 1 and\nthe i-th element in weights would be used to scale (by multiplication) the count of the i-th n-gram in pool. If mode is \"TFIDF\",\nthis operator first computes the counts of all n-grams and then scale them by the associated values in the weights attribute.\n\nOnly one of pool_strings and pool_int64s can be set. If pool_int64s is set, the input should be an integer tensor.\nIf pool_strings is set, the input must be a string tensor.\n"
----f
input: "X"
output: "Y"
name: "ThresholdedRelu"
op_type: "ThresholdedRelu"
attribute {
name: "alpha"
f: 1.0
type: FLOAT
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "float16"
type: STRINGS
}
doc_string: "\nThresholdedRelu takes one input data (Tensor<T>) and produces one output data\n(Tensor<T>) where the rectified linear function, y = x for x > alpha, y = 0 otherwise,\nis applied to the tensor elementwise.\n"
----f
input: "input"
input: "repeats"
output: "output"
name: "Tile"
op_type: "Tile"
attribute {
name: "input-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "repeats-types"
strings: "int64"
type: STRINGS
}
doc_string: "Constructs a tensor by tiling a given tensor.\nThis is the same as function `tile` in Numpy, but no broadcast.\nFor example A = [[1, 2], [3, 4]], B = [1, 2], tile(A, B) = [[1, 2, 1, 2], [3, 4, 3, 4]]\n"
----f
input: "X"
input: "K"
output: "Values"
output: "Indices"
name: "TopK"
op_type: "TopK"
attribute {
name: "axis"
i: -1
type: INT
}
attribute {
name: "largest"
i: 1
type: INT
}
attribute {
name: "sorted"
i: 1
type: INT
}
attribute {
name: "X-types"
strings: "uint16"
strings: "int8"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "float"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "K-types"
strings: "int64"
type: STRINGS
}
doc_string: "\nRetrieve the top-K largest or smallest elements along a specified axis. Given an input tensor of\nshape [a_1, a_2, ..., a_n, r] and integer argument k, return two outputs:\n -Value tensor of shape [a_1, a_2, ..., a_{axis-1}, k, a_{axis+1}, ... a_n]\n which contains the values of the top k elements along the specified axis\n -Index tensor of shape [a_1, a_2, ..., a_{axis-1}, k, a_{axis+1}, ... a_n] which\n contains the indices of the top k elements (original indices from the input\n tensor).\n\nIf \"largest\" is 1 (the default value) then the k largest elements are returned.\nIf \"sorted\" is 1 (the default value) then the resulting k elements will be sorted.\nIf \"sorted\" is 0, order of returned \'Values\' and \'Indices\' are undefined.\n\nGiven two equivalent values, this operator uses the indices along the axis as\n a tiebreaker. That is, the element with the lower index will appear first.\n"
----f
input: "data"
output: "transposed"
name: "Transpose"
op_type: "Transpose"
attribute {
name: "perm"
s: ""
type: INTS
}
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nTranspose the input tensor similar to numpy.transpose. For example, when\nperm=(1, 0, 2), given an input tensor of shape (1, 2, 3), the output shape\nwill be (2, 1, 3).\n"
----f
input: "X"
output: "Y"
output: "Z"
name: "TreeEnsembleClassifier"
op_type: "TreeEnsembleClassifier"
attribute {
name: "base_values"
s: ""
type: FLOATS
}
attribute {
name: "class_ids"
s: ""
type: INTS
}
attribute {
name: "class_nodeids"
s: ""
type: INTS
}
attribute {
name: "class_treeids"
s: ""
type: INTS
}
attribute {
name: "class_weights"
s: ""
type: FLOATS
}
attribute {
name: "classlabels_int64s"
s: ""
type: INTS
}
attribute {
name: "classlabels_strings"
s: ""
type: STRINGS
}
attribute {
name: "nodes_falsenodeids"
s: ""
type: INTS
}
attribute {
name: "nodes_featureids"
s: ""
type: INTS
}
attribute {
name: "nodes_hitrates"
s: ""
type: FLOATS
}
attribute {
name: "nodes_missing_value_tracks_true"
s: ""
type: INTS
}
attribute {
name: "nodes_modes"
s: ""
type: STRINGS
}
attribute {
name: "nodes_nodeids"
s: ""
type: INTS
}
attribute {
name: "nodes_treeids"
s: ""
type: INTS
}
attribute {
name: "nodes_truenodeids"
s: ""
type: INTS
}
attribute {
name: "nodes_values"
s: ""
type: FLOATS
}
attribute {
name: "post_transform"
s: "NONE"
type: STRING
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\n Tree Ensemble classifier. Returns the top class for each of N inputs.<br>\n The attributes named \'nodes_X\' form a sequence of tuples, associated by \n index into the sequences, which must all be of equal length. These tuples\n define the nodes.<br>\n Similarly, all fields prefixed with \'class_\' are tuples of votes at the leaves.\n A leaf may have multiple votes, where each vote is weighted by\n the associated class_weights index.<br>\n One and only one of classlabels_strings or classlabels_int64s\n will be defined. The class_ids are indices into this list.\n"
----f
input: "X"
output: "Y"
name: "TreeEnsembleRegressor"
op_type: "TreeEnsembleRegressor"
attribute {
name: "aggregate_function"
s: "SUM"
type: STRING
}
attribute {
name: "base_values"
s: ""
type: FLOATS
}
attribute {
name: "n_targets"
s: ""
type: INT
}
attribute {
name: "nodes_falsenodeids"
s: ""
type: INTS
}
attribute {
name: "nodes_featureids"
s: ""
type: INTS
}
attribute {
name: "nodes_hitrates"
s: ""
type: FLOATS
}
attribute {
name: "nodes_missing_value_tracks_true"
s: ""
type: INTS
}
attribute {
name: "nodes_modes"
s: ""
type: STRINGS
}
attribute {
name: "nodes_nodeids"
s: ""
type: INTS
}
attribute {
name: "nodes_treeids"
s: ""
type: INTS
}
attribute {
name: "nodes_truenodeids"
s: ""
type: INTS
}
attribute {
name: "nodes_values"
s: ""
type: FLOATS
}
attribute {
name: "post_transform"
s: "NONE"
type: STRING
}
attribute {
name: "target_ids"
s: ""
type: INTS
}
attribute {
name: "target_nodeids"
s: ""
type: INTS
}
attribute {
name: "target_treeids"
s: ""
type: INTS
}
attribute {
name: "target_weights"
s: ""
type: FLOATS
}
attribute {
name: "X-types"
strings: "float"
strings: "double"
strings: "int32"
strings: "int64"
type: STRINGS
}
doc_string: "\n Tree Ensemble regressor. Returns the regressed values for each input in N.<br>\n All args with nodes_ are fields of a tuple of tree nodes, and\n it is assumed they are the same length, and an index i will decode the\n tuple across these inputs. Each node id can appear only once\n for each tree id.<br>\n All fields prefixed with target_ are tuples of votes at the leaves.<br>\n A leaf may have multiple votes, where each vote is weighted by\n the associated target_weights index.<br>\n All trees must have their node ids start at 0 and increment by 1.<br>\n Mode enum is BRANCH_LEQ, BRANCH_LT, BRANCH_GTE, BRANCH_GT, BRANCH_EQ, BRANCH_NEQ, LEAF\n"
----f
input: "X"
output: "Y"
output: "indices"
output: "inverse_indices"
output: "counts"
name: "Unique"
op_type: "Unique"
attribute {
name: "axis"
s: ""
type: INT
}
attribute {
name: "sorted"
i: 1
type: INT
}
attribute {
name: "X-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nFind the unique elements of a tensor. When an optional attribute \'axis\' is provided, unique subtensors sliced along the \'axis\' are returned. \nOtherwise the input tensor is flattened and unique values of the flattened tensor are returned. \n\nThis operator returns the unique values or sliced unique subtensors of the input tensor and three optional outputs. \nThe first output tensor \'Y\' contains all unique values or subtensors of the input. \nThe second optional output tensor \'indices\' contains indices of \'Y\' elements\' first occurance in \'X\'.. \nThe third optional output tensor \'inverse_indices\' contains, for elements of \'X\', its corresponding indices in \'Y\'. \". \nThe fourth optional output tensor \'counts\' contains the count of each element of \'Y\' in the input. \n\nOutputs are either sorted in ascending order or optionally in the order of the first occurrence of the values in the input. \n\nhttps://docs.scipy.org/doc/numpy/reference/generated/numpy.unique.html\n\nExample 1:\n input_X = [2, 1, 1, 3, 4, 3]\n attribute_sorted = 0\n attribute_axis = None\n output_Y = [2, 1, 3, 4]\n output_indices = [0, 1, 3, 4]\n output_inverse_indices = [0, 1, 1, 2, 3, 2]\n output_counts = [1, 2, 2, 1]\n\nExample 2:\n input_X = [[1, 3], [2, 3]]\n attribute_sorted = 1\n attribute_axis = None\n output_Y = [1, 2, 3]\n output_indices = [0, 2, 1]\n output_inverse_indices = [0, 2, 1, 2]\n output_counts = [1, 1, 2]\n\nExample 3:\n input_X = [[1, 0, 0], [1, 0, 0], [2, 3, 4]]\n attribute_sorted = 1\n attribute_axis = 0\n output_Y = [[1, 0, 0], [2, 3, 4]]\n output_indices = [0, 2]\n output_inverse_indices = [0, 0, 1]\n output_counts = [2, 1]\n\nExample 4:\n input_x = [[[1., 1.], [0., 1.], [2., 1.], [0., 1.]], \n [[1., 1.], [0., 1.], [2., 1.], [0., 1.]]]\n attribute_sorted = 1\n attribute_axis = 1\n\n intermediate data are presented below for better understanding: \n \n there are 4 subtensors sliced along axis 1 of input_x (shape = (2, 4, 2)):\n A: [[1, 1], [1, 1]], \n [[0, 1], [0, 1]], \n [[2, 1], [2, 1]], \n [[0, 1], [0, 1]].\n \n there are 3 unique subtensors: \n [[1, 1], [1, 1]], \n [[0, 1], [0, 1]], \n [[2, 1], [2, 1]].\n \n sorted unique subtensors:\n B: [[0, 1], [0, 1]], \n [[1, 1], [1, 1]], \n [[2, 1], [2, 1]].\n \n output_Y is constructed from B:\n [[[0. 1.], [1. 1.], [2. 1.]], \n [[0. 1.], [1. 1.], [2. 1.]]]\n\n output_indices is to map from B to A:\n [1, 0, 2]\n \n output_inverse_indices is to map from A to B:\n [1, 0, 2, 0]\n\n output_counts = [2 1 1]\n"
----f
input: "data"
output: "expanded"
name: "Unsqueeze"
op_type: "Unsqueeze"
attribute {
name: "axes"
s: ""
type: INTS
}
attribute {
name: "data-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\nInsert single-dimensional entries to the shape of an input tensor (`data`).\nTakes one required argument `axes` - which contains a list of dimension indices and this operator will insert a dimension of value `1` into the corresponding index of the output tensor (`expanded`).\n\nFor example:\n Given an input tensor (`data`) of shape [3, 4, 5], then\n Unsqueeze(data, axes=[0, 4]) outputs a tensor (`expanded`) containing same data as `data` but with shape [1, 3, 4, 5, 1].\n\nThe attribute `axes` should not contain any duplicate entries. It is an error if it contains duplicates.\nThe rank of the output tensor (`output_rank`) is the rank of the input tensor (`data`) plus the number of values in `axes`.\nEach value in `axes` should be within the (inclusive) range [-output_rank , output_rank - 1]. \nThe order of values in `axes` does not matter and can come in any order. \n\n"
----f
input: "X"
input: "scales"
output: "Y"
name: "Upsample"
op_type: "Upsample"
attribute {
name: "mode"
s: "nearest"
type: STRING
}
attribute {
name: "X-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "scales-types"
strings: "float"
type: STRINGS
}
doc_string: "\nUpsample the input tensor.\nEach dimension value of the output tensor is:\n output_dimension = floor(input_dimension * scale).\n"
----f
input: "condition"
input: "X"
input: "Y"
output: "output"
name: "Where"
op_type: "Where"
attribute {
name: "condition-types"
strings: "bool"
type: STRINGS
}
attribute {
name: "X-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
attribute {
name: "Y-types"
strings: "uint16"
strings: "int8"
strings: "bool"
strings: "int32"
strings: "float16"
strings: "uint8"
strings: "string"
strings: "double"
strings: "int64"
strings: "uint32"
strings: "complex64"
strings: "float"
strings: "complex128"
strings: "int16"
strings: "uint64"
type: STRINGS
}
doc_string: "\n Return elements, either from X or Y, depending on condition\n (with Numpy-style broadcasting support).\n Where behaves like numpy.where with three parameters:\n https://docs.scipy.org/doc/numpy/reference/generated/numpy.where.html\n"
----f
input: "A"
input: "B"
output: "C"
name: "Xor"
op_type: "Xor"
attribute {
name: "A-types"
strings: "bool"
type: STRINGS
}
attribute {
name: "B-types"
strings: "bool"
type: STRINGS
}
doc_string: "\nReturns the tensor resulted from performing the `xor` logical operation\nelementwise on the input tensors `A` and `B` (with Numpy-style broadcasting support).\n\nThis operator supports **multidirectional (i.e., Numpy-style) broadcasting**; for more details please check [the doc](Broadcasting.md).\n"
----f
input: "X"
output: "Z"
name: "ZipMap"
op_type: "ZipMap"
attribute {
name: "classlabels_int64s"
s: ""
type: INTS
}
attribute {
name: "classlabels_strings"
s: ""
type: STRINGS
}
attribute {
name: "X-types"
strings: "float"
type: STRINGS
}
doc_string: "\n Creates a map from the input and the attributes.<br>\n The values are provided by the input tensor, while the keys are specified by the attributes.\n Must provide keys in either classlabels_strings or classlabels_int64s (but not both).<br>\n The columns of the tensor correspond one-by-one to the keys specified by the attributes. There must be as many columns as keys.<br>\n"
----f