Skip to content

Commit

Permalink
Add functional metric docs [skip ci] (#3946)
Browse files Browse the repository at this point in the history
* add functional docs

* drop

* format

Co-authored-by: Jirka Borovec <jirka@pytorchlightning.ai>
  • Loading branch information
justusschock and Borda authored Oct 7, 2020
1 parent fef9b77 commit bd5621d
Showing 1 changed file with 200 additions and 0 deletions.
200 changes: 200 additions & 0 deletions docs/source/metrics.rst
Original file line number Diff line number Diff line change
Expand Up @@ -150,3 +150,203 @@ MeanSquaredLogError

.. autoclass:: pytorch_lightning.metrics.regression.MeanSquaredLogError
:noindex:


Functional Metrics
==================

The functional metrics follow the simple paradigm input in, output out. This means, they don't provide any advanced mechanisms for syncing across DDP nodes or aggregation over batches. They simply compute the metric value based on the given inputs.

Also the integration within other parts of PyTorch Lightning will never be as tight as with the class-based interface.
If you look for just computing the values, the functional metrics are the way to go. However, if you are looking for the best integration and user experience, please consider also to use the class interface.

Classification
--------------

accuracy [func]
^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.accuracy
:noindex:


auc [func]
^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.auc
:noindex:


auroc [func]
^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.auroc
:noindex:


average_precision [func]
^^^^^^^^^^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.average_precision
:noindex:


confusion_matrix [func]
^^^^^^^^^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.confusion_matrix
:noindex:


dice_score [func]
^^^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.dice_score
:noindex:


f1_score [func]
^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.f1_score
:noindex:


fbeta_score [func]
^^^^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.fbeta_score
:noindex:


iou [func]
^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.iou
:noindex:


multiclass_roc [func]
^^^^^^^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.multiclass_roc
:noindex:


precision [func]
^^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.precision
:noindex:


precision_recall [func]
^^^^^^^^^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.precision_recall
:noindex:


precision_recall_curve [func]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.precision_recall_curve
:noindex:


recall [func]
^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.recall
:noindex:


roc [func]
^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.roc
:noindex:


stat_scores [func]
^^^^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.stat_scores
:noindex:


stat_scores_multiple_classes [func]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.stat_scores_multiple_classes
:noindex:


to_categorical [func]
^^^^^^^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.to_categorical
:noindex:


to_onehot [func]
^^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.classification.to_onehot
:noindex:


Regression
----------

mae [func]
^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.regression.mae
:noindex:


mse [func]
^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.regression.mse
:noindex:


psnr [func]
^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.regression.psnr
:noindex:


rmse [func]
^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.regression.rmse
:noindex:


rmsle [func]
^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.regression.rmsle
:noindex:


ssim [func]
^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.regression.mae
:noindex:


NLP
---

bleu_score [func]
^^^^^^^^^^^^^^^^^

.. autofunction:: pytorch_lightning.metrics.functional.nlp.bleu_score
:noindex:

0 comments on commit bd5621d

Please sign in to comment.