Skip to content

Commit

Permalink
Test forward logabsdetjac too
Browse files Browse the repository at this point in the history
  • Loading branch information
penelopeysm committed Nov 30, 2024
1 parent 7be7ea9 commit e82d0d7
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test/interface.jl
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,9 @@ contains(predicate::Function, b::Stacked) = any(contains.(predicate, b.bs))
d_big = Uniform(big(-1.0), big(1.0))
b_big = bijector(d_big)
x_big = inverse(b_big)(big(y))
@test logpdf(d, x_big) + logabsdetjacinv(b, y)
@test logpdf(d_big, x_big) + logabsdetjacinv(b, y)
logpdf_with_trans(d_big, x_big, true) atol = 1e-14
@test logpdf(d_big, x_big) - logabsdetjac(b, x_big)
logpdf_with_trans(d_big, x_big, true) atol = 1e-14
end
end
Expand Down

0 comments on commit e82d0d7

Please sign in to comment.