Skip to content

Commit 9e3b73c

Browse files
authored
[FIX] change bool8->bool_ (#923)
* change bool8->bool_ * add shape to argument
1 parent 71d7799 commit 9e3b73c

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

nimare/meta/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ def _convolve_sphere(kernel, ijks, index, max_shape):
3333

3434
def np_all_axis1(x):
3535
"""Numba compatible version of np.all(x, axis=1)."""
36-
out = np.ones(x.shape[0], dtype=np.bool8)
36+
out = np.ones(x.shape[0], dtype=np.bool_)
3737
for i in range(x.shape[1]):
3838
out = np.logical_and(out, x[:, i])
3939
return out

nimare/utils.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1286,9 +1286,9 @@ def b_spline_bases(masker_voxels, spacing, margin=10):
12861286
x_spline_coords = x_spline.nonzero()
12871287
y_spline_coords = y_spline.nonzero()
12881288
z_spline_coords = z_spline.nonzero()
1289-
x_spline_sparse = sparse.COO(x_spline_coords, x_spline[x_spline_coords])
1290-
y_spline_sparse = sparse.COO(y_spline_coords, y_spline[y_spline_coords])
1291-
z_spline_sparse = sparse.COO(z_spline_coords, z_spline[z_spline_coords])
1289+
x_spline_sparse = sparse.COO(x_spline_coords, x_spline[x_spline_coords], shape=x_spline.shape)
1290+
y_spline_sparse = sparse.COO(y_spline_coords, y_spline[y_spline_coords], shape=y_spline.shape)
1291+
z_spline_sparse = sparse.COO(z_spline_coords, z_spline[z_spline_coords], shape=z_spline.shape)
12921292

12931293
# create spatial design matrix by tensor product of spline bases in 3 dimesion
12941294
# Row sums of X are all 1=> There is no need to re-normalise X

0 commit comments

Comments
 (0)