Skip to content

Commit 228a2f1

Browse files
committed
add test for posterior contraction without aggregation
1 parent 7aeb14d commit 228a2f1

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

tests/test_diagnostics/test_diagnostics_metrics.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ def test_posterior_contraction(random_estimates, random_targets):
4343
assert out["values"].shape == (num_variables(random_estimates),)
4444
assert out["metric_name"] == "Posterior Contraction"
4545
assert out["variable_names"] == ["beta_0", "beta_1", "sigma"]
46+
# test without aggregation
47+
out = bf.diagnostics.metrics.posterior_contraction(random_estimates, random_targets, aggregation=None)
48+
assert out["values"].shape == (random_estimates["sigma"].shape[0], num_variables(random_estimates))
4649

4750

4851
def test_root_mean_squared_error(random_estimates, random_targets):

0 commit comments

Comments
 (0)