Bug fix in mean nn distance and angular cosine changes