Skip to content

Commit

Permalink
copy! fix
Browse files Browse the repository at this point in the history
  • Loading branch information
thomaspinder committed Sep 4, 2019
1 parent 40a1b72 commit a64593a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/sparse/full_scale_approximation.jl
Expand Up @@ -67,7 +67,8 @@ end
function Base.Matrix(a::BlockDiagPDMat)
K = zeros(size(a))
for (pd,ind) in zip(a.blockPD,a.blockindices)
copy!(@view(K[ind,ind]), mat(pd))
b = @view(K[ind, ind])
b = copy(mat(pd))
end
return K
end
Expand Down
2 changes: 1 addition & 1 deletion test/test_sparse.jl
Expand Up @@ -155,7 +155,7 @@ module TestSparse
@testset "Fully Independent Training Conditionals" begin
test_sparse(FITC(x', Xu, Y, gp_full.mean, gp_full.kernel, gp_full.logNoise), -3709.601737889645)
end
@testset "Fully Independent Training Conditionals" begin
@testset "Full Scale Approximation" begin
test_sparse(FSA(x', Xu, blockindices, Y, gp_full.mean, gp_full.kernel, gp_full.logNoise), -3706.2892293004734)
end
end
Expand Down

0 comments on commit a64593a

Please sign in to comment.