-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Description
Thanks for writing and maintaining this package, I find it super useful when writing code.
One thing I've noticed is that the following was automatically generated...
def summarise_shape(shape: npt.NDArray) -> list:
"""Summarise the region properties of a 2D numpy array using Scikit-Image.
Parameters
----------
shape : npt.NDArray
2D binary array of a shape.
Returns
-------
list
List of Region Properties each item describing one labelled region.
"""
return measure.regionprops(shape)I use the numpydoc pre-commit hook to make sure I get everything correct and on parsing the above it raised GL01.
Putting the first line on its own new line assuaged the linter.
def summarise_shape(shape: npt.NDArray) -> list:
"""
Summarise the region properties of a 2D numpy array using Scikit-Image.
Parameters
----------
shape : npt.NDArray
2D binary array of a shape.
Returns
-------
list
List of Region Properties each item describing one labelled region.
"""
return measure.regionprops(shape)I'll see if I can work out how to add this and make a Pull Request over the coming weeks but am writing this up now for reference.
Metadata
Metadata
Assignees
Labels
No labels