Robust Metric Learning by Smooth Optimization