DILCA: Distance Learning for Categorical Attributes