I had a np.sqrt()
snippet that didn't check for negative values, so I understandably got warnings. I thought I had fixed it, but I got one again:
RuntimeWarning: invalid value encountered in sqrt
data_std = np.sqrt(np.absolute(data_std))
Are there any invalid numbers other than negative ones for np.sqrt
?