Extend plugins with imshow_collection

A first implementation is made for Matplotlib.
This commit is contained in:
Stefan van der Walt
2016-03-02 16:22:24 -08:00
parent 0d7289ea76
commit 3ffca2fdbd
7 changed files with 54 additions and 10 deletions
+7
View File
@@ -1,6 +1,8 @@
# This mock-up is called by ../tests/test_plugin.py
# to verify the behaviour of the plugin infrastructure
from skimage.io import ImageCollection
def imread(fname, dtype=None):
assert fname == 'test.png'
@@ -20,3 +22,8 @@ def imshow(arr, plugin_arg=None):
def imread_collection(x, conserve_memory=True):
assert conserve_memory == False
assert x == '*.png'
return ImageCollection([0, 1], load_func=lambda x: x)
def imshow_collection(x):
assert len(x) == 2