JuliaDiff / SparseDiffTools.jl

Fast jacobian computation through sparsity exploitation and matrix coloring
MIT License
237 stars 41 forks source link

Modify `auto_jacvec` for compatibility with Zygote #157

Closed mateuszbaran closed 2 years ago

mateuszbaran commented 2 years ago

This fixes one of the problems encountered in https://github.com/SciML/DiffEqFlux.jl/pull/614 : Zygote seems to have trouble differentiating through this broadcast, so I've changed it to map. Additionally a different tag is used, more similar to what ForwardDiff.jl does. Related PR: https://github.com/JuliaDiff/SparseDiffTools.jl/pull/155 .

codecov-commenter commented 2 years ago

Codecov Report

Merging #157 (3f9ba40) into master (b324c2c) will increase coverage by 0.02%. The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #157      +/-   ##
==========================================
+ Coverage   83.69%   83.72%   +0.02%     
==========================================
  Files          12       12              
  Lines         687      688       +1     
==========================================
+ Hits          575      576       +1     
  Misses        112      112              
Impacted Files Coverage Δ
src/differentiation/jaches_products.jl 97.81% <100.00%> (+0.01%) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update b324c2c...3f9ba40. Read the comment docs.