incerto.utils.plot_uncertainty_distribution

incerto.utils.plot_uncertainty_distribution#

incerto.utils.plot_uncertainty_distribution(uncertainties, correct_mask, title='Uncertainty Distribution', xlabel='Uncertainty', save_path=None, show=True)[source]#

Plot uncertainty distribution for correct vs incorrect predictions.

Parameters:
  • uncertainties (Tensor) – Uncertainty scores (N,)

  • correct_mask (Tensor) – Boolean mask for correct predictions (N,)

  • title (str) – Plot title

  • xlabel (str) – X-axis label

  • save_path (Optional[str]) – Path to save figure (optional)

  • show (bool) – Whether to call plt.show() (default: True)