@@ -29,9 +29,9 @@ class RunningAverage(Metric):
29
29
output_transform: a function to use to transform the output if `src` is None and
30
30
corresponds the output of process function. Otherwise it should be None.
31
31
epoch_bound: whether the running average should be reset after each epoch. It is depracated in favor of
32
- ``usage`` argument in :meth:`attach` method. Setting ``epoch_bound`` to ``False`` is equivalent with
33
- ``usage=SingleEpochRunningBatchWise()`` and setting it to ``True`` is equivalent with
34
- `usage=RunningBatchWise()` in the :method :`attach` method. Default None.
32
+ ``usage`` argument in :meth:`attach` method. Setting ``epoch_bound`` to ``False`` is equivalent to
33
+ ``usage=SingleEpochRunningBatchWise()`` and setting it to ``True`` is equivalent to
34
+ `usage=RunningBatchWise()` in the :meth :`attach` method. Default None.
35
35
device: specifies which device updates are accumulated on. Should be
36
36
None when ``src`` is an instance of :class:`~ignite.metrics.metric.Metric`, as the running average will
37
37
use the ``src``'s device. Otherwise, defaults to CPU. Only applicable when the computed value
@@ -185,8 +185,8 @@ def attach(self, engine: Engine, name: str, usage: Union[str, MetricUsage] = Run
185
185
======================================================= ===========================================
186
186
187
187
``RunningAverage`` retrieves ``engine.state.output`` at ``usage.ITERATION_COMPLETED`` if the ``src`` is not
188
- given and it's computed and updated using ``src`, by manually calling its ``compute`` method, or
189
- ``engine.state.output`` at ``usage.COMPLETED``event.
188
+ given and it's computed and updated using ``src`` , by manually calling its ``compute`` method, or
189
+ ``engine.state.output`` at ``usage.COMPLETED`` event.
190
190
Also if ``src`` is given, it is updated at ``usage.ITERATION_COMPLETED``, but its reset event is determined by
191
191
``usage`` type. If ``isinstance(usage, BatchWise)`` holds true, ``src`` is reset on ``BatchWise().STARTED``,
192
192
otherwise on ``EpochWise().STARTED`` if ``isinstance(usage, EpochWise)``.
0 commit comments