measure_cross_entropy function

Estimate the cross-entropy