From 17e63c472c7f4f92aad4c99e1720914bba24d417 Mon Sep 17 00:00:00 2001 From: Pasha Khosravi Date: Mon, 18 Oct 2021 22:06:39 -0700 Subject: [PATCH] forgot cuda.functional for tests --- test/structurelearner/rat_spn_tests.jl | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/test/structurelearner/rat_spn_tests.jl b/test/structurelearner/rat_spn_tests.jl index 1457cd47..8d274dbf 100644 --- a/test/structurelearner/rat_spn_tests.jl +++ b/test/structurelearner/rat_spn_tests.jl @@ -2,9 +2,7 @@ using Test using LogicCircuits using ProbabilisticCircuits using DataFrames - - - +using CUDA @testset "Random Region Graph tests" begin @@ -65,8 +63,11 @@ end @test typeof(circuit) <: ProbCircuit estimate_parameters_em(circuit, data; pseudocount, use_gpu=false, update_per_batch = false) - estimate_parameters_em(circuit, data; pseudocount, use_gpu=true, update_per_batch = false) estimate_parameters_em(circuit, data; pseudocount, use_gpu=false, update_per_batch = true) - estimate_parameters_em(circuit, data; pseudocount, use_gpu=true, update_per_batch = true) + + if CUDA.functional() + estimate_parameters_em(circuit, data; pseudocount, use_gpu=true, update_per_batch = false) + estimate_parameters_em(circuit, data; pseudocount, use_gpu=true, update_per_batch = true) + end end \ No newline at end of file