code: def test_plot_losses_to_outputs():
      """Test PlotLosses.to_output API"""
      plotlosses = PlotLosses(outputs=["MatplotlibPlot"])
      assert len(plotlosses.outputs) == 1
      plotlosses.reset_outputs()
      assert len(plotlosses.outputs) == 0
      plotlosses.to_matplotlib().to_extrema_printer().to_extrema_printer()
      assert len(plotlosses.outputs) == 3
  
imports: from livelossplot import MainLogger, PlotLosses
  from livelossplot.outputs import BaseOutput
label_desc: Use image node_id 2 for calling a global function with example usage: test_plot_losses_to_outputs() without return types