Edit on GitHub

dvclive.next_step()

Signals that the current step has ended. Check the init parameters for configuring the behavior.

def next_step()

Usage:

import dvclive

for step in range(3):
    dvclive.log("metric", 0.9)
    dvclive.next_step()

Description

Each call to dvclive.next_step() will behave depending on the parameters selected in dvclive.init() and whether DVC is available or not.

If summary is True, on each dvclive.next_step() call, DVCLive will generate a summary of the values previously logged with dvclive.log(), and increase the step count.

The metrics summary will be saved to {path}.json. Here's an example:

{
  "step": 2,
  "metric": 0.9
}

๐Ÿ’ก These JSON files can be visualized with dvc metrics.

DVC Integration

When dvclive is used alongside DVC, each dvclive.next_step() call will have additional features.

By default, on each dvclive.next_step() call, DVC will create a new checkpoint.

In addition, if html is True, on each dvclive.next_step() call, DVC will prepare an HTML report with all the metrics logs logged in path.

Exceptions

โ€ฆ

Content

๐Ÿ› Found an issue? Let us know! Or fix it:

Edit on GitHub

โ“ Have a question? Join our chat, we will help you:

Discord Chat