Mercurial > repos > public > sbplib_julia
changeset 1879:765f42559c47 refactor/lazy_tensors/elementwise_ops
Add some more docs
author | Jonatan Werpers <jonatan@werpers.com> |
---|---|
date | Mon, 27 Jan 2025 17:11:14 +0100 |
parents | b12e28a03b2e |
children | 378002c78e86 |
files | src/LazyTensors/lazy_tensor_operations.jl |
diffstat | 1 files changed, 6 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/LazyTensors/lazy_tensor_operations.jl Mon Jan 27 17:10:59 2025 +0100 +++ b/src/LazyTensors/lazy_tensor_operations.jl Mon Jan 27 17:11:14 2025 +0100 @@ -71,7 +71,7 @@ """ TensorSum{T,R,D,...} <: LazyTensor{T,R,D} -The sum of 2 or more lazy tensors. +The lazy sum of 2 or more lazy tensors. """ struct TensorSum{T,R,D,TT<:NTuple{N, LazyTensor{T,R,D}} where N} <: LazyTensor{T,R,D} tms::TT @@ -86,6 +86,11 @@ end end +""" + TensorSum(ts::Vararg{LazyTensor}) + +The lazy sum of the tensors `ts`. +""" function TensorSum(ts::Vararg{LazyTensor}) T = eltype(ts[1]) R = range_dim(ts[1])