Skip to content

Commit

Permalink
Fix test_label_transfer
Browse files Browse the repository at this point in the history
Uncertainty can go above 1, as entropy is not bounded by 1.
  • Loading branch information
stefanpeidli committed Sep 25, 2024
1 parent c4927eb commit f3fa186
Showing 1 changed file with 0 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,6 @@ def test_label_transfer():
ps.label_transfer(adata)
assert "unknown" not in adata.obs["perturbation"]
assert all(adata.obs["perturbation_transfer_uncertainty"] >= 0)
assert all(adata.obs["perturbation_transfer_uncertainty"] <= 1)
assert not all(adata.obs["perturbation_transfer_uncertainty"] == 0)
is_known = adata.obs["perturbation"] != "unknown"
assert all(adata.obs.loc[is_known, "perturbation_transfer_uncertainty"] == 0)

0 comments on commit f3fa186

Please sign in to comment.