Fixed NumPy compatibility issue.