Oral
Analyzing and Improving Representations with the Soft Nearest Neighbor Loss
Nicholas Frosst · Nicolas Papernot · Geoffrey Hinton

Thu Jun 13th 12:05 -- 12:10 PM @ Hall A

We introduce the Soft Nearest Neighbor Loss that measures the entanglement of class manifolds in representation space: i.e., how close pairs of points from the same class are relatively to pairs of points from different classes. We demonstrate several use cases of the loss. As an analytical tool, it provides insights into the evolution of similarity structures during learning. Surprisingly, we find that maximizing the entanglement of representations of different classes in the hidden layers is beneficial for discriminating, possibly because it encourages representations to identify class-independent similarity structures. Maximizing the soft nearest neighbor loss in the hidden layers leads not only to improved generalization but also to better-calibrated estimates of uncertainty on outlier data. Data that is not from the training distribution can be recognized by observing that in the hidden layers, it has fewer than the normal number of neighbors from the predicted class.

Author Information

Nicholas Frosst (Google Brain)
Nicolas Papernot
Geoffrey Hinton (Google)

Related Events (a corresponding poster, oral, or spotlight)

More from the Same Authors