Bucketize

Versioned name: Bucketize-3

Category: Condition operation

Short description: Bucketize bucketizes the input based on boundaries. This is similar to Reference.

Detailed description: Bucketize computes a bucket index for each element from the first input and outputs a tensor of the first input shape. Buckets are defined with boundaries from the second input.

For example, if the first input tensor is [[3, 50], [10, -1]] and the second input is [0, 5, 10] with included right bound, the output will be [[1, 3], [2, 0]].

Attributes

Inputs:

Outputs:

Types

Example

<layer ... type="Bucketize">
<input>
<port id="0">
<dim>49</dim>
<dim>11</dim>
</port>
<port id="1">
<dim>5</dim>
</port>
</input>
<output>
<port id="1">
<dim>49</dim>
<dim>11</dim>
</port>
</output>
</layer>