scikit-image/scikit-image — pull request #984 by JDWarner (2014-04-19 00:11:36+00:00)
Title: Random Walker improvements and checks for trivial cases

In response to #983

If a fully labeled volume (i.e., no zero-valued regions) is passed as `labels`, `random_walker` now shortcuts and returns the user's data to them with an informative message. This also works if `return_full_prob=True`.

**Documentation fixes**
* Part of the docstring was incorrect; we implemented the solver fallback scheme last release but `'bf'` was still listed as the default solver. This was clarified.
* The example is now PEP8 compliant.
* Warnings to the user (particularly the UMFPACK warning) were clarified.

**Style**
* This PR improves input checking, converting `assert` statements (who did those, I wonder...) to `if bad_thing: raise exception`.
* The `spacing` kwarg functionality now match the docstring. It also checks to ensure all items in the iterable are numbers (against duck typing philosophy, but if you let this pass the errors are very uninformative).
* Added some whitespace to `random_walker` function to break up code blocks. It's much more readable to me now.

**Tests**
* New features / checks are fully covered.
* Now with more `'chickens'`