Unsupervised feature-learning for out-of-distribution detection