You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If `A.data` is a dense array, return a new [`QuantumObject`](@ref) where `A.data` is in the type of `CUDA.CuArray` for gpu calculations.
12
12
"""
13
-
CuArray(A::QuantumObject{Tq}) where {Tq<:Union{Vector,Matrix}} =QuantumObject(CuArray(A.data), A.type, A.dims)
13
+
CuArray(A::QuantumObject{Tq}) where {Tq<:Union{Vector,Matrix}} =QuantumObject(CuArray(A.data), A.type, A._dims)
14
14
15
15
@docraw"""
16
16
CuArray{T}(A::QuantumObject)
17
17
18
18
If `A.data` is a dense array, return a new [`QuantumObject`](@ref) where `A.data` is in the type of `CUDA.CuArray` with element type `T` for gpu calculations.
19
19
"""
20
-
CuArray{T}(A::QuantumObject{Tq}) where {T,Tq<:Union{Vector,Matrix}} =QuantumObject(CuArray{T}(A.data), A.type, A.dims)
20
+
CuArray{T}(A::QuantumObject{Tq}) where {T,Tq<:Union{Vector,Matrix}} =QuantumObject(CuArray{T}(A.data), A.type, A._dims)
21
21
22
22
@docraw"""
23
23
CuSparseVector(A::QuantumObject)
24
24
25
25
If `A.data` is a sparse vector, return a new [`QuantumObject`](@ref) where `A.data` is in the type of `CUDA.CUSPARSE.CuSparseVector` for gpu calculations.
If `A.data` is a sparse vector, return a new [`QuantumObject`](@ref) where `A.data` is in the type of `CUDA.CUSPARSE.CuSparseVector` with element type `T` for gpu calculations.
33
33
"""
34
-
CuSparseVector{T}(A::QuantumObject{<:SparseVector}) where {T} =QuantumObject(CuSparseVector{T}(A.data), A.type, A.dims)
34
+
CuSparseVector{T}(A::QuantumObject{<:SparseVector}) where {T} =
If `A.data` is in the type of `SparseMatrixCSC`, return a new [`QuantumObject`](@ref) where `A.data` is in the type of `CUDA.CUSPARSE.CuSparseMatrixCSC` for gpu calculations.
If `A.data` is in the type of `SparseMatrixCSC`, return a new [`QuantumObject`](@ref) where `A.data` is in the type of `CUDA.CUSPARSE.CuSparseMatrixCSC` with element type `T` for gpu calculations.
47
48
"""
48
49
CuSparseMatrixCSC{T}(A::QuantumObject{<:SparseMatrixCSC}) where {T} =
If `A.data` is in the type of `SparseMatrixCSC`, return a new [`QuantumObject`](@ref) where `A.data` is in the type of `CUDA.CUSPARSE.CuSparseMatrixCSR` for gpu calculations.
If `A.data` is in the type of `SparseMatrixCSC`, return a new [`QuantumObject`](@ref) where `A.data` is in the type of `CUDA.CUSPARSE.CuSparseMatrixCSR` with element type `T` for gpu calculations.
62
63
"""
63
64
CuSparseMatrixCSR{T}(A::QuantumObject{<:SparseMatrixCSC}) where {T} =
0 commit comments