make it runnable on older versions of numpy