GradHist2d
- class cockpit.quantities.GradHist2d(track_schedule, verbose=False, bins=(40, 50), range=((- 1, 1), (- 2, 2)), adapt=(None, None), keep_individual=False)[source]
Quantity class for two-dimensional histograms over gradient and parameters.
Tracks two-dimensional histogram of individual gradient elements over parameters. Individual gradient values are binned on the x-axis, parameter values are binned on the y-axis.
Initialize the 2D Histogram of individual gradient elements over parameters.
- Parameters
track_schedule (callable) – Function that maps the
global_step
to a boolean, which determines if the quantity should be computed.verbose (bool, optional) – Turns on verbose mode. Defaults to
False
.bins ([int, int]) – Number of bins in x and y direction. Default:
(40, 50)
range ([[float, float], [float, float]], optional) – Bin limits in x and y direction. Default
((-1, 1), (-2, 2))
.adapt ([BinAdaptation or None, BinAdaptation or None], optional) – Policy for adapting the bin limits in x and y direction.
None
indicates no adaptation. Default value:(None, None)
.keep_individual (bool, optional) – Whether to keep individual parameter histograms. Defaults to False.