numpy how to check if ssome values are nan code example Example: numpy is not nan a = a[~np.isnan(a)]