Skip to content

youngklee/magnet-loss

Repository files navigation

magnet-loss

An encoder for learning embeddings via minimizing the magnet loss. In the embedding space each class forms its own cluster. See "METRIC LEARNING WITH ADAPTIVE DENSITY DISCRIMINATION" by Rippel et al. The codes from the following repos are used:

Batch Losses

plot_smooth(batch_losses)

batch_losses

Initial Embeddings of the MNIST dataset

plot_embedding(initial_reps[:500], y_train[:500])

initial_embeddings

Final Embeddings

plot_embedding(final_reps[:500], y_train[:500])

final_embeddings