Skip to content

Commit

Permalink
improve manellic test
Browse files Browse the repository at this point in the history
  • Loading branch information
dehann committed May 20, 2024
1 parent a05cbc6 commit 98aca3b
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions test/manellic/testManellicTree.jl
Original file line number Diff line number Diff line change
Expand Up @@ -435,11 +435,13 @@ mtree = ApproxManifoldProducts.buildTree_Manellic!(M, pts; kernel_bw = diagm([0.
p = exp(M, ϵ, hat(M, ϵ, [10, 20, 0.1]))
y_amp = AMP.evaluate(mtree, p)
y_pdf = pdf(dis, [10,20,0.1])
# check kde eval is within 40% of true value
# check kde eval is within 20% of true value
y_err = y_amp - y_pdf
@show y_pdf
@test isapprox(0, y_err; atol=0.4*y_pdf)
@warn "weak test for approx function vs. true Normal density function evaluation"
if !isapprox(0, y_err; atol=0.2*y_pdf)
@warn "soft test failure for approx function vs. true Normal density function evaluation"
@test_broken false
end

end

Expand Down

0 comments on commit 98aca3b

Please sign in to comment.