Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

torch_logcumsumexp

Logcumsumexp


Description

Logcumsumexp

Usage

torch_logcumsumexp(self, dim)

Arguments

self

(Tensor) the input tensor.

dim

(int) the dimension to do the operation over

logcumsumexp(input, dim, *, out=None) -> Tensor

Returns the logarithm of the cumulative summation of the exponentiation of elements of input in the dimension dim.

For summation index j given by dim and other indices i, the result is

\mbox{logcumsumexp}(x)_{ij} = \log ∑\limits_{j=0}^{i} \exp(x_{ij})

Examples

if (torch_is_installed()) {

a <- torch_randn(c(10))
torch_logcumsumexp(a, dim=1)
}

torch

Tensors and Neural Networks with 'GPU' Acceleration

v0.3.0
MIT + file LICENSE
Authors
Daniel Falbel [aut, cre, cph], Javier Luraschi [aut], Dmitriy Selivanov [ctb], Athos Damiani [ctb], Christophe Regouby [ctb], Krzysztof Joachimiak [ctb], RStudio [cph]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.