Skip to content

Commit

Permalink
hotfix array check
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisRackauckas committed Dec 29, 2021
1 parent daf102a commit 61ee53d
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "LinearSolve"
uuid = "7ed4a6bd-45f5-4d41-b270-4a48e9bafcae"
authors = ["SciML"]
version = "1.2.2"
version = "1.2.3"

[deps]
ArrayInterface = "4fba245c-0d91-5ea0-9b3e-6abc04ee57a9"
Expand Down
16 changes: 8 additions & 8 deletions src/factorization.jl
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ function do_factorization(alg::LUFactorization, A, b, u)
A isa Union{AbstractMatrix,AbstractDiffEqOperator} ||
error("LU is not defined for $(typeof(A))")

if A isa AbstractDiffEqOperator
if A isa DiffEqArrayOperator
A = A.A
end
fact = lu!(A, alg.pivot)
Expand All @@ -63,7 +63,7 @@ function init_cacheval(alg::UMFPACKFactorization, A, b, u, Pl, Pr, maxiters, abs
end

function do_factorization(::UMFPACKFactorization, A, b, u)
if A isa AbstractDiffEqOperator
if A isa DiffEqArrayOperator
A = A.A
end
if A isa SparseMatrixCSC
Expand All @@ -75,7 +75,7 @@ end

function SciMLBase.solve(cache::LinearCache, alg::UMFPACKFactorization)
A = cache.A
if A isa AbstractDiffEqOperator
if A isa DiffEqArrayOperator
A = A.A
end
if cache.isfresh
Expand Down Expand Up @@ -103,7 +103,7 @@ function init_cacheval(alg::KLUFactorization, A, b, u, Pl, Pr, maxiters, abstol,
end

function do_factorization(::KLUFactorization, A, b, u)
if A isa AbstractDiffEqOperator
if A isa DiffEqArrayOperator
A = A.A
end
if A isa SparseMatrixCSC
Expand All @@ -115,7 +115,7 @@ end

function SciMLBase.solve(cache::LinearCache, alg::KLUFactorization)
A = cache.A
if A isa AbstractDiffEqOperator
if A isa DiffEqArrayOperator
A = A.A
end
if cache.isfresh
Expand Down Expand Up @@ -158,7 +158,7 @@ function do_factorization(alg::QRFactorization, A, b, u)
A isa Union{AbstractMatrix,AbstractDiffEqOperator} ||
error("QR is not defined for $(typeof(A))")

if A isa AbstractDiffEqOperator
if A isa DiffEqArrayOperator
A = A.A
end
if alg.inplace
Expand All @@ -182,7 +182,7 @@ function do_factorization(alg::SVDFactorization, A, b, u)
A isa Union{AbstractMatrix,AbstractDiffEqOperator} ||
error("SVD is not defined for $(typeof(A))")

if A isa AbstractDiffEqOperator
if A isa DiffEqArrayOperator
A = A.A
end

Expand All @@ -203,7 +203,7 @@ function do_factorization(alg::GenericFactorization, A, b, u)
A isa Union{AbstractMatrix,AbstractDiffEqOperator} ||
error("GenericFactorization is not defined for $(typeof(A))")

if A isa AbstractDiffEqOperator
if A isa DiffEqArrayOperator
A = A.A
end
fact = alg.fact_alg(A)
Expand Down

0 comments on commit 61ee53d

Please sign in to comment.