scipy.maxentropy.maxentutils.arrayexp

scipy.maxentropy.maxentutils.arrayexp(x)

Returns the elementwise antilog of the real array x.

We try to exponentiate with numpy.exp() and, if that fails, with python’s math.exp(). numpy.exp() is about 10 times faster but throws an OverflowError exception for numerical underflow (e.g. exp(-800), whereas python’s math.exp() just returns zero, which is much more helpful.

Previous topic

scipy.maxentropy.conditionalmodel.logpmf

Next topic

scipy.maxentropy.maxentutils.arrayexpcomplex

This Page