Skip to content

Commit

Permalink
Merge branch 'master' into removed-py38
Browse files Browse the repository at this point in the history
  • Loading branch information
vfdev-5 authored Dec 16, 2024
2 parents 83e83fd + d2f935d commit 30bedfc
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/ignite/metrics/test_roc_auc.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import pytest
import sklearn
import torch
from sklearn.exceptions import UndefinedMetricWarning
from sklearn.metrics import roc_auc_score

import ignite.distributed as idist
Expand Down Expand Up @@ -112,7 +113,7 @@ def test_check_compute_fn():
em = ROC_AUC(check_compute_fn=True)

em.reset()
with pytest.warns(EpochMetricWarning, match=r"Probably, there can be a problem with `compute_fn`"):
with pytest.warns((UndefinedMetricWarning, EpochMetricWarning), match=r"Only one class.+present in y_true"):
em.update(output)

em = ROC_AUC(check_compute_fn=False)
Expand Down

0 comments on commit 30bedfc

Please sign in to comment.