fix: replace deprecated np.float and np.int aliases for NumPy 1.24+

pull/976/head
Open Source Contributor 2 months ago
parent e993c82f6b
commit 5d411fa0cb

@ -246,7 +246,7 @@
"metadata": {},
"outputs": [],
"source": [
"Q = np.ones((width,height,len(actions)),dtype=np.float)*1.0/len(actions)"
"Q = np.ones((width,height,len(actions)),dtype=np.float64)*1.0/len(actions)"
]
},
{

@ -264,7 +264,7 @@
"metadata": {},
"outputs": [],
"source": [
"Q = np.ones((width,height,len(actions)),dtype=np.float)*1.0/len(actions)"
"Q = np.ones((width,height,len(actions)),dtype=np.float64)*1.0/len(actions)"
]
},
{

@ -209,7 +209,7 @@
"outputs": [],
"source": [
"def discretize(x):\n",
" return tuple((x/np.array([0.25, 0.25, 0.01, 0.1])).astype(np.int))"
" return tuple((x/np.array([0.25, 0.25, 0.01, 0.1])).astype(np.int_))"
]
},
{

Loading…
Cancel
Save