We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
using Test using CUDA, CUDA.CUSPARSE using CUDSS using SparseArrays using LinearAlgebra using Random Random.seed!(1) n = 100 p = 5 T = ComplexF64 R = real(T) A_cpu = sprand(T, n, n, 0.01) + I A_cpu = A_cpu + A_cpu' X_cpu = zeros(T, n, p) B_cpu = rand(T, n, p) A_gpu = CuSparseMatrixCSR(A_cpu) X_gpu = CuMatrix(X_cpu) B_gpu = CuMatrix(B_cpu) matrix = CudssMatrix(A_gpu, "H", 'F', index='O') config = CudssConfig() data = CudssData() solver = CudssSolver(matrix, config, data) cudss("analysis", solver, X_gpu, B_gpu) cudss("factorization", solver, X_gpu, B_gpu) nnz_decomposition = cudss_get(solver, "lu_nnz") inertia = cudss_get(solver, "inertia") cudss("solve", solver, X_gpu, B_gpu) R_gpu = B_gpu - CuSparseMatrixCSR(A_cpu) * X_gpu @test norm(R_gpu) ≤ √eps(R) Y_cpu = zeros(T, n, n) Y_gpu = CuMatrix(Y_cpu) C_cpu = Matrix{T}(I, n, n) C_gpu = CuMatrix(C_cpu) cudss("solve", solver, Y_gpu, C_gpu) RR_gpu = C_gpu - CuSparseMatrixCSR(A_cpu) * Y_gpu @test norm(RR_gpu) ≤ √eps(R)
using MatrixMarket MatrixMarket.mmwrite("cudss_A.mtx", A_gpu |> SparseMatrixCSC) MatrixMarket.mmwrite("cudss_B.mtx", B_gpu |> Matrix |> sparse) MatrixMarket.mmwrite("cudss_X.mtx", X_gpu |> Matrix |> sparse) MatrixMarket.mmwrite("cudss_Y.mtx", Y_gpu |> Matrix |> sparse)
The text was updated successfully, but these errors were encountered:
It works if we remove the pivoting with
cudss_set(solver, "pivot_type", 'N')
This issue will be fixed in the next release.
Sorry, something went wrong.
Fixed by #17
No branches or pull requests
The text was updated successfully, but these errors were encountered: