Skip to content

Commit aa7fb52

Browse files
authored
Merge branch 'master' into master
2 parents 62436fd + 0d3494f commit aa7fb52

File tree

25 files changed

+1504
-45
lines changed

25 files changed

+1504
-45
lines changed

CHANGELOG.md

Lines changed: 25 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -12,52 +12,59 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1212

1313
### Added
1414

15-
- Added `NormalizedRootMeanSquaredError` metric to regression subpackage ([#2442](https://github.com/Lightning-AI/torchmetrics/pull/2442))
15+
-
1616

1717

18-
- Added `NegativePredictiveValue` to classification metrics ([#2433](https://github.com/Lightning-AI/torchmetrics/pull/2433))
18+
### Changed
1919

20+
-
2021

21-
- Added method `merge_state` to `Metric` ([#2786](https://github.com/Lightning-AI/torchmetrics/pull/2786))
2222

23+
### Removed
2324

24-
- Added a new audio metric `NISQA` ([#2792](https://github.com/PyTorchLightning/metrics/pull/2792))
25+
-
2526

2627

27-
- Added `Dice` metric to segmentation metrics ([#2725](https://github.com/Lightning-AI/torchmetrics/pull/2725))
28+
### Fixed
2829

30+
- Fixed multiclass recall macro avg. ignore index ([#2710](https://github.com/Lightning-AI/torchmetrics/pull/2710))
2931

30-
- Added support for propagation of the autograd graph in ddp setting ([#2754](https://github.com/Lightning-AI/torchmetrics/pull/2754))
3132

33+
- Fixed iou scores in detection for either empty predictions/targets leading to wrong scores ([#2805](https://github.com/Lightning-AI/torchmetrics/pull/2805))
34+
35+
36+
---
37+
38+
## [1.6.0] - 2024-11-12
39+
40+
### Added
41+
42+
- Added audio metric `NISQA` ([#2792](https://github.com/PyTorchLightning/metrics/pull/2792))
43+
- Added classification metric `LogAUC` ([#2377](https://github.com/Lightning-AI/torchmetrics/pull/2377))
44+
- Added classification metric `NegativePredictiveValue` ([#2433](https://github.com/Lightning-AI/torchmetrics/pull/2433))
45+
- Added regression metric `NormalizedRootMeanSquaredError` ([#2442](https://github.com/Lightning-AI/torchmetrics/pull/2442))
46+
- Added segmentation metric `Dice` ([#2725](https://github.com/Lightning-AI/torchmetrics/pull/2725))
47+
- Added method `merge_state` to `Metric` ([#2786](https://github.com/Lightning-AI/torchmetrics/pull/2786))
48+
- Added support for propagation of the autograd graph in ddp setting ([#2754](https://github.com/Lightning-AI/torchmetrics/pull/2754))
3249

3350
### Changed
3451

3552
- Changed naming and input order arguments in `KLDivergence` ([#2800](https://github.com/Lightning-AI/torchmetrics/pull/2800))
3653

37-
3854
### Deprecated
3955

4056
- Deprecated Dice from classification metrics ([#2725](https://github.com/Lightning-AI/torchmetrics/pull/2725))
4157

42-
4358
### Removed
4459

4560
- Changed minimum supported Pytorch version to 2.0 ([#2671](https://github.com/Lightning-AI/torchmetrics/pull/2671))
46-
47-
4861
- Dropped support for Python 3.8 ([#2827](https://github.com/Lightning-AI/torchmetrics/pull/2827))
49-
50-
5162
- Removed `num_outputs` in `R2Score` ([#2800](https://github.com/Lightning-AI/torchmetrics/pull/2800))
5263

53-
5464
### Fixed
5565

56-
- Fixed multiclass recall macro avg. ignore index ([#2710](https://github.com/Lightning-AI/torchmetrics/pull/2710))
57-
58-
59-
- Fixed iou scores in detection for either empty predictions/targets leading to wrong scores ([#2805](https://github.com/Lightning-AI/torchmetrics/pull/2805))
60-
66+
- Fixed segmentation `Dice` + `GeneralizedDice` for 2d index tensors ([#2832](https://github.com/Lightning-AI/torchmetrics/pull/2832))
67+
- Fixed mixed results of `rouge_score` with `accumulate='best'` ([#2830](https://github.com/Lightning-AI/torchmetrics/pull/2830))
6168

6269
---
6370

docs/source/classification/logauc.rst

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
.. customcarditem::
2+
:header: Log Area Receiver Operating Characteristic (LogAUC)
3+
:image: https://pl-flash-data.s3.amazonaws.com/assets/thumbnails/tabular_classification.svg
4+
:tags: Classification
5+
6+
.. include:: ../links.rst
7+
8+
#######
9+
Log AUC
10+
#######
11+
12+
Module Interface
13+
________________
14+
15+
.. autoclass:: torchmetrics.LogAUC
16+
:exclude-members: update, compute
17+
:special-members: __new__
18+
19+
BinaryLogAUC
20+
^^^^^^^^^^^^
21+
22+
.. autoclass:: torchmetrics.classification.BinaryLogAUC
23+
:exclude-members: update, compute
24+
25+
MulticlassLogAUC
26+
^^^^^^^^^^^^^^^^
27+
28+
.. autoclass:: torchmetrics.classification.MulticlassLogAUC
29+
:exclude-members: update, compute
30+
31+
MultilabelLogAUC
32+
^^^^^^^^^^^^^^^^
33+
34+
.. autoclass:: torchmetrics.classification.MultilabelLogAUC
35+
:exclude-members: update, compute
36+
37+
Functional Interface
38+
____________________
39+
40+
.. autofunction:: torchmetrics.functional.logauc
41+
42+
binary_logauc
43+
^^^^^^^^^^^^^
44+
45+
.. autofunction:: torchmetrics.functional.classification.binary_logauc
46+
47+
multiclass_logauc
48+
^^^^^^^^^^^^^^^^^
49+
50+
.. autofunction:: torchmetrics.functional.classification.multiclass_logauc
51+
52+
multilabel_logauc
53+
^^^^^^^^^^^^^^^^^
54+
55+
.. autofunction:: torchmetrics.functional.classification.multilabel_logauc

docs/source/links.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,4 +177,5 @@
177177
.. _Hausdorff Distance: https://en.wikipedia.org/wiki/Hausdorff_distance
178178
.. _averaging curve objects: https://scikit-learn.org/stable/auto_examples/model_selection/plot_roc.html
179179
.. _Procrustes Disparity: https://en.wikipedia.org/wiki/Procrustes_analysis
180+
.. _Log AUC: https://pubmed.ncbi.nlm.nih.gov/20735049/
180181
.. _Negative Predictive Value: https://en.wikipedia.org/wiki/Positive_and_negative_predictive_values

requirements/_tests.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@ codecov ==2.1.13
55
coverage ==7.6.*
66
codecov ==2.1.13
77
pytest ==8.3.*
8-
pytest-cov ==5.0.0
8+
pytest-cov ==6.0.0
99
pytest-doctestplus ==1.2.1
1010
pytest-rerunfailures ==14.0
1111
pytest-timeout ==2.3.1
1212
pytest-xdist ==3.6.1
1313
phmdoctest ==1.4.0
1414

1515
psutil ==6.*
16-
pyGithub >2.0.0, <2.5.0
16+
pyGithub >2.0.0, <2.6.0
1717
fire ==0.7.*
1818

1919
cloudpickle >1.3, <=3.1.0

requirements/classification_test.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,4 @@ pandas >1.4.0, <=2.2.3
55
netcal >1.0.0, <1.4.0 # calibration_error
66
numpy <2.2.0
77
fairlearn # group_fairness
8+
PyTDC ==0.4.1 ; python_version <"3.12" # locauc, temporal_dependency

requirements/text.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
# in case you want to preserve/enforce restrictions on the latest compatible version, add "strict" as an in-line comment
33

44
nltk >3.8.1, <=3.9.1
5-
tqdm <4.67.0
6-
regex >=2021.9.24, <=2024.9.11
5+
tqdm <4.68.0
6+
regex >=2021.9.24, <=2024.11.6
77
transformers >4.4.0, <4.47.0
88
mecab-python3 >=1.0.6, <1.1.0
99
ipadic >=1.0.0, <1.1.0

src/torchmetrics/__about__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
__version__ = "1.6.0dev"
1+
__version__ = "1.7.0dev"
22
__author__ = "Lightning-AI et al."
33
__author_email__ = "[email protected]"
44
__license__ = "Apache-2.0"
5-
__copyright__ = f"Copyright (c) 2020-2023, {__author__}."
5+
__copyright__ = f"Copyright (c) 2020-2024, {__author__}."
66
__homepage__ = "https://github.com/Lightning-AI/torchmetrics"
77
__docs__ = "PyTorch native Metrics"
88
__docs_url__ = "https://lightning.ai/docs/torchmetrics/stable/"

src/torchmetrics/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@
6868
HammingDistance,
6969
HingeLoss,
7070
JaccardIndex,
71+
LogAUC,
7172
MatthewsCorrCoef,
7273
NegativePredictiveValue,
7374
Precision,
@@ -196,6 +197,7 @@
196197
"JaccardIndex",
197198
"KLDivergence",
198199
"KendallRankCorrCoef",
200+
"LogAUC",
199201
"LogCoshError",
200202
"MatchErrorRate",
201203
"MatthewsCorrCoef",

src/torchmetrics/classification/__init__.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@
5757
MulticlassJaccardIndex,
5858
MultilabelJaccardIndex,
5959
)
60+
from torchmetrics.classification.logauc import BinaryLogAUC, LogAUC, MulticlassLogAUC, MultilabelLogAUC
6061
from torchmetrics.classification.matthews_corrcoef import (
6162
BinaryMatthewsCorrCoef,
6263
MatthewsCorrCoef,
@@ -223,6 +224,10 @@
223224
"MulticlassSensitivityAtSpecificity",
224225
"MultilabelSensitivityAtSpecificity",
225226
"SensitivityAtSpecificity",
227+
"BinaryLogAUC",
228+
"LogAUC",
229+
"MulticlassLogAUC",
230+
"MultilabelLogAUC",
226231
"BinaryNegativePredictiveValue",
227232
"MulticlassNegativePredictiveValue",
228233
"MultilabelNegativePredictiveValue",

0 commit comments

Comments
 (0)