Large Scale Metric Learning for Distance-Based Image Classification on Open Ended Data Sets