Skip to content

Commit df14317

Browse files
committed
Use size_in for NFFTOp
1 parent 748fd4f commit df14317

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

ext/LinearOperatorNFFTExt/NFFTOp.jl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,17 +56,17 @@ function NFFTOpImpl(shape::Tuple, tr::AbstractMatrix{T}; toeplitz, oversamplingF
5656
end
5757

5858
function produ!(y::AbstractVector, plan::AbstractNFFTPlan, x::AbstractVector)
59-
mul!(y, plan, reshape(x,plan.N))
59+
mul!(y, plan, reshape(x,size_in(plan)))
6060
end
6161

6262
function ctprodu!(x::AbstractVector, plan::AbstractNFFTPlan, y::AbstractVector)
63-
mul!(reshape(x, plan.N), adjoint(plan), y)
63+
mul!(reshape(x, size_in(plan)), adjoint(plan), y)
6464
end
6565

6666

6767
function Base.copy(S::NFFTOpImpl{T, vecT, P}) where {T, vecT, P}
6868
plan = copy(S.plan)
69-
return NFFTOpImpl{T, vecT, P}(size(plan.k,2), prod(plan.N), false, false
69+
return NFFTOpImpl{T, vecT, P}(size(plan.k,2), prod(size_in(plan)), false, false
7070
, (res,x) -> produ!(res,plan,x)
7171
, nothing
7272
, (res,y) -> ctprodu!(res,plan,y)
@@ -131,7 +131,7 @@ function NFFTToeplitzNormalOp(shape, W, fftplan, ifftplan, λ, xL1::matT, xL2::m
131131
end
132132

133133
function NFFTToeplitzNormalOp(nfft::NFFTOp{T}, W=nothing; kwargs...) where {T}
134-
shape = nfft.plan.N
134+
shape = size_in(nfft.plan)
135135

136136
tmpVec = similar(nfft.Mv5, (2 .* shape)...)
137137
tmpVec .= zero(T)

0 commit comments

Comments
 (0)