Skip to content

Commit 0eba3a8

Browse files
authored
Merge pull request #30 from bayliffe/address_future_warnings
Address numpy future warnings in stratify.interpolate
2 parents 94ceaee + dec7b96 commit 0eba3a8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

stratify/_vinterp.pyx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -539,7 +539,7 @@ cdef class _Interpolation(object):
539539
z_src = np.array(z_src, dtype=np.float64)
540540
fz_src = np.array(fz_src)
541541
#: The result data dtype.
542-
if np.issubdtype(fz_src.dtype, int):
542+
if np.issubdtype(fz_src.dtype, np.signedinteger):
543543
self._target_dtype = np.dtype('f8')
544544
else:
545545
self._target_dtype = fz_src.dtype
@@ -633,7 +633,7 @@ cdef class _Interpolation(object):
633633
'the interpolation axis.')
634634
z_src_indexer = [0] * z_src.ndim
635635
z_src_indexer[zp_axis] = slice(0, 2)
636-
first_two = z_src[z_src_indexer]
636+
first_two = z_src[tuple(z_src_indexer)]
637637
rising = first_two[0] <= first_two[1]
638638

639639
self.rising = bool(rising)

0 commit comments

Comments
 (0)