Skip to content

Commit fd72319

Browse files
TendonFFFcailixun
andauthored
Fix ADOs creating reshape object (#196)
Co-authored-by: cailixun <cailixun23@gmail.com>
1 parent 27bfb4e commit fd72319

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/ADOs.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ Generate the object of auxiliary density operators for HEOM model.
6262
- `parity::AbstractParity` : the parity label (`EVEN` or `ODD`). Default to `EVEN`.
6363
"""
6464
function ADOs::QuantumObject, N::Int = 1, parity::AbstractParity = EVEN)
65-
= sparsevec(ket2dm(ρ).data)
65+
= sparse(vec(ket2dm(ρ).data)) # to avoid _ρ begin reshape type, which cannot do _ρ.nzind and _ρ.nzval
6666
return ADOs(sparsevec(_ρ.nzind, _ρ.nzval, N * length(_ρ)), ρ.dimensions, N, parity)
6767
end
6868
ADOs(ρ, N::Int = 1, parity::AbstractParity = EVEN) =

0 commit comments

Comments
 (0)