Structs

  • | The operator performs sampling based | on the input sampling weights for each | batch. | | All weights must be non-negative numbers. | | The input is a 2-D tensor (Tensor) of | size (batch_size x weights_dim). | | For each batch, an index is randomly | sampled from the distribution given | by the weights of the corresponding | batch. | | The output is a 1-D tensor (Tensor) of | size (batch_size x 1) and contains the | index(es) of the sampled output. |