# tensorplay.functional.logcumsumexp Source: https://www.tensorplay.cn/docs/generated/tensorplay.functional.logcumsumexp.html ```python tensorplay.functional.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 $$\text{logcumsumexp}(x)_{ij} = \log \sum\limits_{k=0}^{j} \exp(x_{ik})$$ Parameters: - input ([Tensor](/docs/generated/tensorplay.Tensor.html#tensorplay.Tensor)) – the input tensor. - dim ([int](https://docs.python.org/3/builtins/functions.html#int)) – the dimension to do the operation over Keyword Arguments: out ([Tensor](/docs/generated/tensorplay.Tensor.html#tensorplay.Tensor), optional) – the output tensor. Example: ``` >>> a = tensorplay.randn(10) >>> tensorplay.logcumsumexp(a, dim=0) tensor([-0.42296738, -0.04462666, 0.86278635, 0.94622083, 1.05277811, 1.39202815, 1.83525007, 1.84492621, 2.06084887, 2.06844475])) ```