pafoster / pyitlib

A library of information-theoretic methods for data analysis and machine learning, implemented in Python and NumPy.
MIT License
90 stars 17 forks source link

Issues with current version of Numpy #10

Open priamai opened 2 years ago

priamai commented 2 years ago

Running the example on python 3.9 and Numpy Version: 1.21.5

import numpy as np
from pyitlib import discrete_random_variable as drv

drv.entropy(['a', 'b', 'a', 'b'], base=np.exp(1))

TypeError: ufunc 'isnan' not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule ''safe''