histogram_oods#
- scio.eval.histogram_oods(conf_ind, conf_oods, *, oods_title=None, score_and_layers=None, **hist_kw)[source]#
For a given score, plot histograms over all OoD sets.
- Parameters:
conf_ind (
NDArray) – Confidence scores of In-Distribution samples. Shape(n_ind_samples,).conf_oods (
tuple[NDArray, ...]) – Same but for iterable of Out-of-Distribution samples. Shapes(n_oodi_samples,).oods_title (
tuple[str, ...], optional) – Seecompute_confidence(). Used only for legend purposes.score_and_layers (
ScoreClassifAndLayers | str, optional) –The score (and layers) used to compute the confidence scores. Example for
ScoreClassifAndLayers:score_and_layers = KNN(k=6), [(1, 1)]
Used only for legend purposes.
**hist_kw – Passed to
sns.histplot().
- Returns:
ax (
plt.Axes) – The matplotlib axes containing the plot.