Open
Description
Currently this line
leads to a loss of structure because it constructs a dense matrix from 2 vectors. We should make this a lazy outer product (like in SciML/LinearSolve.jl#484) such that them x n
matrix's co-tangent only requires O(m + n)
memory. See https://discourse.julialang.org/t/zygote-jl-how-to-get-the-gradient-of-sparse-matrix/59067/12 for the potential gain and suggested implementation. If the idea gets a green light, I will open a PR.Metadata
Metadata
Assignees
Labels
No labels