Skip to content

Commit

Permalink
Merge pull request #776 from christiangnrd/patch-1
Browse files Browse the repository at this point in the history
Fix `UndefVarError: sparseinv not defined` test failures
  • Loading branch information
oxinabox authored Jan 29, 2024
2 parents e569283 + e8f01da commit 1d01f3d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/rulesets/SparseArrays/sparsematrix.jl
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,8 @@ function rrule(::typeof(findnz), v::AbstractSparseVector)
end

if Base.USE_GPL_LIBS # Don't define rrules for sparse determinants if we don't have CHOLMOD from SuiteSparse.jl

using SparseInverseSubset

if VERSION < v"1.7"
#=
The method below for `logabsdet(F::UmfpackLU)` is required to calculate the (log)
Expand Down Expand Up @@ -82,8 +83,6 @@ if Base.USE_GPL_LIBS # Don't define rrules for sparse determinants if we don't h
end
return ifelse(isodd(result), -1, 1)
end

using SparseInverseSubset

function LinearAlgebra.logabsdet(F::UmfpackLU{T, TI}) where {T<:Union{Float64,ComplexF64},TI<:Union{Int32, Int64}}
n = checksquare(F)
Expand Down

0 comments on commit 1d01f3d

Please sign in to comment.