Mercurial > repos > public > sbplib_julia
comparison LazyTensors/src/Lazy.jl @ 193:2d97c54fd1f1 boundary_conditions
Change documentation of LazyElementWiseOperation to docstring
author | Jonatan Werpers <jonatan@werpers.com> |
---|---|
date | Thu, 20 Jun 2019 23:05:12 +0200 |
parents | 4799bc46eaa9 |
children |
comparison
equal
deleted
inserted
replaced
192:4799bc46eaa9 | 193:2d97c54fd1f1 |
---|---|
1 module Lazy | 1 module Lazy |
2 | 2 |
3 # Struct allowing for lazy evaluation of operations on AbstractArrays | 3 |
4 # A LazyElementwiseOperation is defined by two same-sized AbstractArrays | 4 """ |
5 # together with an operation. The operations are carried out when the | 5 LazyElementwiseOperation{T,D,Op, T1<:AbstractArray{T,D}, T2 <: AbstractArray{T,D}} <: AbstractArray{T,D} |
6 # LazyElementwiseOperation is indexed. | 6 |
7 Struct allowing for lazy evaluation of elementwise operations on AbstractArrays. | |
8 | |
9 A LazyElementwiseOperation contains two AbstractArrays of equal size, | |
10 together with an operation. The operations are carried out when the | |
11 LazyElementwiseOperation is indexed. | |
12 """ | |
7 struct LazyElementwiseOperation{T,D,Op, T1<:AbstractArray{T,D}, T2 <: AbstractArray{T,D}} <: AbstractArray{T,D} | 13 struct LazyElementwiseOperation{T,D,Op, T1<:AbstractArray{T,D}, T2 <: AbstractArray{T,D}} <: AbstractArray{T,D} |
8 a::T1 | 14 a::T1 |
9 b::T2 | 15 b::T2 |
10 | 16 |
11 function LazyElementwiseOperation{T,D,Op}(a::T1,b::T2) where {T,D,Op, T1<:AbstractArray{T,D}, T2<:AbstractArray{T,D}} | 17 function LazyElementwiseOperation{T,D,Op}(a::T1,b::T2) where {T,D,Op, T1<:AbstractArray{T,D}, T2<:AbstractArray{T,D}} |