Michael Abbott
Michael Abbott
This changes the meaning of `==` for dual numbers, to demand that both real and ~~imaginary~~ dual parts match. Fixes #197, fixes #407. Edit -- also closes #490, closes #506,...
This follows LinearAlgebra in explicitly forbidding offset arrays. They don't work anyway, but this replaces a BoundsError with something deliberate: ```julia julia> ForwardDiff.gradient(sum, OffsetArray([1,2,3], 3)) # before ERROR: BoundsError: attempt...
Consider this function: ```julia sq(x) = x==1 ? one(x) : x^2 @test FiniteDifferences.central_fdm(5, 1)(sq, 1) ≈ 2.0 @test_broken ForwardDiff.derivative(sq, 1.0) == 2.0 ``` Here `ForwardDiff` gets the wrong answer, according...
I think this is still blocked by https://github.com/JuliaDiff/ReverseDiff.jl/issues/135, here's the error: ```julia julia> Base.gensym(ex::Expr) = gensym(string(ex)); # without this, LoadError: MethodError: no method matching gensym(::Expr) instead julia> using ReverseDiff, Tullio...
This is mostly an experiment to see how easy it might be to hook up https://github.com/JuliaFolds/FoldsCUDA.jl
From https://discourse.julialang.org/t/avoid-memory-allocation-in-passing-arrays/66560 ``` julia> M = [1 2; 3 4.0]; julia> @btime @tullio _ = $M[q,1] * $M[q,1] 22.381 ns (1 allocation: 16 bytes) 10.0 julia> @btime @tullio _ =...
```julia julia> using Tullio, Tracker, ForwardDiff julia> plus10(x) = x + 10; # a function unknown to DiffRules julia> Tracker.gradient(rand(3)) do x @tullio res := x[k] * plus10(k) verbose=true end...
Motivated by #115, this tries to detect indexing of this pattern: ```julia x = rand(Int8, 10) .+ 0; y = copy(x) @tullio y[i] = y[i-1] + y[i] ``` i.e. writing...
In this expression, Tullio fails to notice that the same array is being read and written into. It's happy to multi-thread over `x`, but the answer will depend on the...
LoopVectorization has changed two things since its interaction with Tullio was thought out: 1. a name change `@avx` -> `@turbo`, and 2. a multi-threading macro `@avxt` or `@tturbo == @turbo...