Skip to content

Commit

Permalink
Improve PEP8 and Python 3 compliance
Browse files Browse the repository at this point in the history
Thanks to @JDWarner and @ahojnnes for the input.
  • Loading branch information
jni committed Jul 2, 2013
1 parent 5c4d021 commit 332ab04
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion skimage/util/regular_grid.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import numpy as np


def regular_grid(ar_shape, n_points):
"""Find `n_points` regularly spaced along `ar_shape`.
Expand Down Expand Up @@ -36,7 +37,7 @@ def regular_grid(ar_shape, n_points):
(1.0 / (ndim - dim - 1)))
if (sorted_dims >= stepsizes).all():
break
starts = np.floor(stepsizes/2)
starts = stepsizes // 2
stepsizes = np.round(stepsizes)
slices = [slice(start, None, step) for
start, step in zip(starts, stepsizes)]
Expand Down

0 comments on commit 332ab04

Please sign in to comment.