Mercurial > repos > public > sbplib_julia
comparison src/LazyTensors/lazy_tensor_operations.jl @ 1210:fa0800591306 feature/variable_derivatives
Add note about removing apply_with_region
author | Jonatan Werpers <jonatan@werpers.com> |
---|---|
date | Fri, 03 Feb 2023 22:50:42 +0100 |
parents | 5a3281429a48 |
children | 102ebdaf7c11 |
comparison
equal
deleted
inserted
replaced
1093:703eaa3e50c4 | 1210:fa0800591306 |
---|---|
314 function Base.showerror(io::IO, err::RangeSizeMismatch) | 314 function Base.showerror(io::IO, err::RangeSizeMismatch) |
315 print(io, "RangeSizeMismatch: ") | 315 print(io, "RangeSizeMismatch: ") |
316 print(io, "range size $(range_size(err.tm)) of LazyTensor not matching size $(err.sz)") | 316 print(io, "range size $(range_size(err.tm)) of LazyTensor not matching size $(err.sz)") |
317 end | 317 end |
318 | 318 |
319 | 319 # TODO: These should probably be removed. From new testing in performance/get_region_type_inference it seems that the problems are solved without these |
320 function apply_with_region(op, v, boundary_width::Integer, dim_size::Integer, i) | 320 function apply_with_region(op, v, boundary_width::Integer, dim_size::Integer, i) |
321 if 0 < i <= boundary_width | 321 if 0 < i <= boundary_width |
322 return LazyTensors.apply(op,v,Index(i,Lower)) | 322 return LazyTensors.apply(op,v,Index(i,Lower)) |
323 elseif boundary_width < i <= dim_size-boundary_width | 323 elseif boundary_width < i <= dim_size-boundary_width |
324 return LazyTensors.apply(op,v,Index(i,Interior)) | 324 return LazyTensors.apply(op,v,Index(i,Interior)) |