Absract class prior construction to function sparse_class_distribution