Skip to content

Commit 2475c89

Browse files
committed
Test setup for CUDA
1 parent c278627 commit 2475c89

File tree

3 files changed

+8
-2
lines changed

3 files changed

+8
-2
lines changed

test/gpu/cuda.jl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
using CUDA, CuNFFT
2+
3+
arrayTypes = [CuArray]
4+
5+
include(joinpath(@__DIR__(), "..", "runtests.jl"))

test/runtests.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@ using NFFT
88
using RadonKA
99
using JLArrays
1010

11-
arrayTypes = [Array, JLArray]
11+
areTypesDefined = @isdefined arrayTypes
12+
arrayTypes = areTypesDefined ? arrayTypes : [Array, JLArray]
1213

1314
@testset "LinearOperatorCollection" begin
1415
include("testNormalOp.jl")

test/testOperators.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ function testNFFT2d(N=16;arrayType = Array)
234234
F_nfft.toeplitz = false
235235
AHA = normalOperator(F_nfft)
236236
y_AHA_nfft = Array(AHA * xop)
237-
y_AHA = F' * F * xop
237+
y_AHA = F' * F * vec(x)
238238
@test y_AHA y_AHA_nfft rtol = 1e-2
239239

240240
# test AHA with Toeplitz

0 commit comments

Comments
 (0)