Skip to content

Out of GPU memory #1024

@albertomercurio

Description

@albertomercurio

Hello,

By running the following code I get the Out of GPU memory error.

using LinearAlgebra
using SparseArrays
using CUDA
using Krylov
using KrylovPreconditioners

N = 1500000
A = 10*CUSPARSE.CuSparseMatrixCSR(sprand(ComplexF64, N, N, 1/N)) + I
b = CUDA.CuArray(rand(ComplexF64, N))

Pℓ = Diagonal(CuVector(1 ./ norm.(eachcol(SparseMatrixCSC(A)))))
x, stats = gmres(A, b, N=Pℓ, ldiv=false)

I'm not surprised that this can happen, given the huge size of the matrix. But I'm surprised that this happens when the algorithm has already started and a few iterations have been already done. This also happens if I use the KrylovOperator, that should improve the performance.

Am I doing something wrong?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions