nn.logsoftmax
fn logsoftmax(tensor: @Tensor<T>, axis: usize) -> Tensor<T>Applies the natural log to Softmax function to an n-dimensional input Tensor consisting of values in the range [0,1].
Args
tensor(@Tensor<T>) - The input tensor.axis(usize) - The axis along which to compute the natural lof softmax outputs.
Returns
A Tensor of fixed point numbers with the same shape than the input Tensor.
Type Constraints
Constrain input and output types to fixed point tensors.
Examples
Last updated