incerto.calibration.plot_smooth_reliability_diagram

incerto.calibration.plot_smooth_reliability_diagram#

incerto.calibration.plot_smooth_reliability_diagram(logits, labels, ax=None, title='Smooth Reliability Diagram')[source]#

Plot a smooth reliability diagram using kernel smoothing.

Uses the SmoothECE framework: Nadaraya-Watson kernel regression with automatic bandwidth selection via the fixed-point condition.

Reference:

Blasiok & Nakkiran, “Smooth ECE: Principled Reliability Diagrams via Kernel Smoothing” (ICLR 2024)

Parameters:
  • logits (Tensor) – Model logits (N, C)

  • labels (Tensor) – True labels (N,)

  • ax – Optional matplotlib axes

  • title (str) – Plot title

Returns:

matplotlib Axes