Skip to content

Commit

Permalink
Update examples in running (#2081)
Browse files Browse the repository at this point in the history
  • Loading branch information
OmerShubi authored Sep 14, 2023
1 parent c24c36a commit 9b21108
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/torchmetrics/wrappers/running.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,7 @@ class Running(WrapperMetric):
base_metric: The metric to wrap.
window: The size of the running window.
Example:
# Single metric
Example (single metric):
>>> from torch import tensor
>>> from torchmetrics.wrappers import Running
>>> from torchmetrics.aggregation import SumMetric
Expand All @@ -61,8 +60,7 @@ class Running(WrapperMetric):
current_val=tensor(4.), running_val=tensor(9.), total_val=tensor(10)
current_val=tensor(5.), running_val=tensor(12.), total_val=tensor(15)
Example:
# Metric collection
Example (metric collection):
>>> from torch import tensor
>>> from torchmetrics.wrappers import Running
>>> from torchmetrics import MetricCollection
Expand Down

0 comments on commit 9b21108

Please sign in to comment.