Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Native torch metrics #1488

Merged
merged 139 commits into from
Jun 13, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
139 commits
Select commit Hold shift + click to select a range
0390cc1
New metric classes (#1326)
justusschock Apr 3, 2020
9b62397
Create __init__.py
justusschock Apr 1, 2020
0800ae0
add tests for metric utils
justusschock Apr 1, 2020
30d1188
add docstrings for metrics utils
justusschock Apr 1, 2020
d3c5ad4
add function to recursively apply other function to collection
justusschock Apr 1, 2020
efc96eb
add tests for this function
justusschock Apr 1, 2020
8e00350
update test
justusschock Apr 1, 2020
efcf601
fix tests
justusschock Apr 2, 2020
fcfb1cc
fix to tensor conversion
justusschock Apr 2, 2020
0b5bad9
fix apply to collection
justusschock Apr 2, 2020
01d29da
remove tests from init
justusschock Apr 2, 2020
ff59c60
rename utils to convertors
justusschock Apr 2, 2020
5ce8207
Update pytorch_lightning/metrics/convertors.py
justusschock Apr 3, 2020
55b2329
Update pytorch_lightning/metrics/convertors.py
justusschock Apr 3, 2020
19c1d9d
Update pytorch_lightning/metrics/convertors.py
justusschock Apr 3, 2020
e7ccb29
Update tests/utilities/test_apply_to_collection.py
justusschock Apr 3, 2020
b78573a
Update tests/utilities/test_apply_to_collection.py
justusschock Apr 3, 2020
1619b55
Update tests/metrics/convertors.py
justusschock Apr 3, 2020
a29ce7a
Apply suggestions from code review
justusschock Apr 3, 2020
c1e6b3d
rename file and fix imports
justusschock Apr 3, 2020
59f5a9e
added parametrized test
justusschock Apr 3, 2020
b09eb6f
rename apply_to_collection to apply_func
justusschock Apr 3, 2020
4e284d8
Add requested changes and add ellipsis for doctest
justusschock Apr 3, 2020
5f7d4a0
forgot to push these files...
justusschock Apr 3, 2020
e70f4fb
add explicit check for dtype to convert to
justusschock Apr 3, 2020
3a3cc95
fix ddp tests
justusschock Apr 3, 2020
c82d4ee
remove explicit ddp destruction
justusschock Apr 3, 2020
627189b
add function to reduce tensors (similar to reduction in torch.nn)
justusschock Apr 13, 2020
5d74cba
add functionals of reduction metrics
justusschock Apr 13, 2020
8a40737
add more metrics
justusschock Apr 14, 2020
778531a
pep8 fixes
justusschock Apr 14, 2020
cb36557
Create utils.py
justusschock Apr 1, 2020
ca1cecf
Create __init__.py
justusschock Apr 1, 2020
4b3d8db
add tests for metric utils
justusschock Apr 1, 2020
430ffe6
add docstrings for metrics utils
justusschock Apr 1, 2020
fb8dca8
add function to recursively apply other function to collection
justusschock Apr 1, 2020
d0be141
add tests for this function
justusschock Apr 1, 2020
d110ef0
update test
justusschock Apr 1, 2020
2bae4b2
fix tests
justusschock Apr 2, 2020
01fb972
fix to tensor conversion
justusschock Apr 2, 2020
9b0c546
fix apply to collection
justusschock Apr 2, 2020
674cd80
remove tests from init
justusschock Apr 2, 2020
1339fb4
rename utils to convertors
justusschock Apr 2, 2020
7cf1bd4
Update pytorch_lightning/metrics/convertors.py
justusschock Apr 3, 2020
bceb07e
Update pytorch_lightning/metrics/convertors.py
justusschock Apr 3, 2020
d06e3d2
Update pytorch_lightning/metrics/convertors.py
justusschock Apr 3, 2020
e26bdff
Update tests/utilities/test_apply_to_collection.py
justusschock Apr 3, 2020
cdf8bd5
Update tests/utilities/test_apply_to_collection.py
justusschock Apr 3, 2020
0177ec0
Update tests/metrics/convertors.py
justusschock Apr 3, 2020
7408170
Apply suggestions from code review
justusschock Apr 3, 2020
82988c5
rename file and fix imports
justusschock Apr 3, 2020
4fd032b
added parametrized test
justusschock Apr 3, 2020
ddd7e4d
rename apply_to_collection to apply_func
justusschock Apr 3, 2020
a25cab7
Add requested changes and add ellipsis for doctest
justusschock Apr 3, 2020
121103c
forgot to push these files...
justusschock Apr 3, 2020
e7886d6
add explicit check for dtype to convert to
justusschock Apr 3, 2020
23dd2a5
fix ddp tests
justusschock Apr 3, 2020
817f09c
remove explicit ddp destruction
justusschock Apr 3, 2020
905befa
add functionals of reduction metrics
justusschock Apr 13, 2020
2e43d46
rename
Borda Apr 17, 2020
e79bea9
Create metric.py
justusschock Apr 1, 2020
a522ab2
Create __init__.py
justusschock Apr 1, 2020
281024c
add tests for this function
justusschock Apr 1, 2020
e354f4f
Update pytorch_lightning/metrics/metric.py
justusschock Apr 2, 2020
cdeecf0
update metric name
justusschock Apr 2, 2020
32345f0
remove example docs
justusschock Apr 2, 2020
3bf2023
add metric tests
justusschock Apr 2, 2020
5517458
Update pytorch_lightning/metrics/metric.py
justusschock Apr 2, 2020
7557f39
add missing type annotations
justusschock Apr 2, 2020
d58a1dc
rename utils to convertors
justusschock Apr 2, 2020
07d04ab
Update pytorch_lightning/metrics/metric.py
justusschock Apr 3, 2020
3515cfe
Apply suggestions from code review
justusschock Apr 3, 2020
69855c7
add doctest example
justusschock Apr 3, 2020
f493b6b
replace lambda with inlined function
justusschock Apr 3, 2020
ef6af9b
rename apply_to_collection to apply_func
justusschock Apr 3, 2020
e8c36a8
Separated class description from init args
justusschock Apr 3, 2020
0b0d26c
Apply suggestions from code review
justusschock Apr 3, 2020
ebe9342
adjust random values
justusschock Apr 3, 2020
f722d06
suppress output when seeding
justusschock Apr 3, 2020
af47a87
remove gpu from doctest
justusschock Apr 3, 2020
4de6776
Add requested changes and add ellipsis for doctest
justusschock Apr 3, 2020
cbfa32d
forgot to push these files...
justusschock Apr 3, 2020
24010d4
add reduction tests
justusschock Apr 28, 2020
c50f3f3
add first classification tests
justusschock Apr 28, 2020
9a20c24
bugfixes
justusschock Apr 28, 2020
10df5cf
bugfixes
justusschock Apr 29, 2020
20b458a
add more unit tests
justusschock Apr 29, 2020
b90ec08
fix roc score metric
cuent May 20, 2020
8ec7957
fix tests
cuent May 21, 2020
9ce2250
rename
Borda Apr 17, 2020
82cadb4
rename utils to convertors
justusschock Apr 2, 2020
38b84ff
solve tests
cuent May 26, 2020
d22abd0
fix ddp tests
justusschock Apr 3, 2020
56ed04e
fix docs
cuent May 26, 2020
fec8023
remove binaries
cuent May 27, 2020
b536763
Update CHANGELOG.md
Borda May 27, 2020
c43a0da
solve changes from rebase
cuent Jun 3, 2020
69c4566
add eos
cuent Jun 3, 2020
c1b9e74
test auc independently
cuent Jun 3, 2020
cfac264
fix formatting
cuent Jun 4, 2020
e225008
docs
Borda Jun 5, 2020
d80a8e4
docs
Borda Jun 5, 2020
ba2ee61
chlog
Borda Jun 8, 2020
6b6b96d
move
Borda Jun 8, 2020
c3ad1ca
function descriptions
Jun 9, 2020
3e979d0
Add documentation to native metrics (#2144)
cuent Jun 12, 2020
2967d70
Rename tests/metrics/test_classification.py to tests/metrics/function…
justusschock Jun 12, 2020
c6df2b6
Rename tests/metrics/test_reduction.py to tests/metrics/functional/te…
justusschock Jun 12, 2020
3d69f4a
Add module interface for classification metrics
justusschock Jun 12, 2020
2373ab4
add basic tests for classification metrics' module interface
justusschock Jun 12, 2020
d5f4aca
pep8
justusschock Jun 12, 2020
d409947
add additional converters
justusschock Jun 12, 2020
145b1dc
add additional base class
justusschock Jun 12, 2020
5608e0e
change baseclass for some metrics
justusschock Jun 12, 2020
4d4b1ea
update classification tests
justusschock Jun 12, 2020
a6f0e67
update converter tests
justusschock Jun 12, 2020
ec65588
update metric tests
justusschock Jun 12, 2020
0868b6f
Apply suggestions from code review
Borda Jun 12, 2020
f5ff39b
tests-params
Borda Jun 12, 2020
247fc76
tests-params
Borda Jun 12, 2020
4600978
imports
Borda Jun 12, 2020
7d98c5b
pep8
Borda Jun 12, 2020
7fa09f0
tests-params
Borda Jun 12, 2020
ace806a
formatting
Borda Jun 12, 2020
e523eda
fix test_metrics
Jun 12, 2020
a84de91
typo
Borda Jun 12, 2020
802104e
formatting
Borda Jun 12, 2020
cd790b9
fix dice tests
Jun 12, 2020
8391654
fix decorator order
justusschock Jun 12, 2020
f71331e
fix tests
Jun 12, 2020
612681b
seed
Borda Jun 12, 2020
3a62ac0
dice test
Borda Jun 12, 2020
9d08fc5
formatting
Borda Jun 12, 2020
be464bf
try freeze test
Borda Jun 12, 2020
b3e0459
formatting
Borda Jun 12, 2020
d786048
fix tests
Borda Jun 12, 2020
f672ab6
try spawn
Borda Jun 12, 2020
8c87640
formatting
Borda Jun 12, 2020
d81eeb1
fix
Borda Jun 12, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
- Remove explicit flush from tensorboard logger ([#2126](https://github.com/PyTorchLightning/pytorch-lightning/pull/2126))
- Added metric Base classes ([#1326](https://github.com/PyTorchLightning/pytorch-lightning/pull/1326), [#1877](https://github.com/PyTorchLightning/pytorch-lightning/pull/1877))
- Added Sklearn metrics classes ([#1327](https://github.com/PyTorchLightning/pytorch-lightning/pull/1327))
- Added Native torch metrics ([#1488](https://github.com/PyTorchLightning/pytorch-lightning/pull/1488))
- Added type hints in `Trainer.fit()` and `Trainer.test()` to reflect that also a list of dataloaders can be passed in ([#1723](https://github.com/PyTorchLightning/pytorch-lightning/pull/1723))
- Allow dataloaders without sampler field present ([#1907](https://github.com/PyTorchLightning/pytorch-lightning/pull/1907))
- Added option `save_last` to save the model at the end of every epoch in `ModelCheckpoint` [(#1908)](https://github.com/PyTorchLightning/pytorch-lightning/pull/1908)
Expand Down
2 changes: 1 addition & 1 deletion pytorch_lightning/metrics/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@

"""

from pytorch_lightning.metrics.converters import numpy_metric, tensor_metric
from pytorch_lightning.metrics.metric import Metric, TensorMetric, NumpyMetric
from pytorch_lightning.metrics.sklearn import (
SklearnMetric, Accuracy, AveragePrecision, AUC, ConfusionMatrix, F1, FBeta,
Precision, Recall, PrecisionRecallCurve, ROC, AUROC)
from pytorch_lightning.metrics.converters import numpy_metric, tensor_metric
Loading