From 502f6af481709c60921ea9fa0e846aa4cc1de648 Mon Sep 17 00:00:00 2001 From: Steven Silvester Date: Fri, 24 Oct 2014 13:15:20 -0500 Subject: [PATCH] Pep8 cleanup --- skimage/io/collection.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/skimage/io/collection.py b/skimage/io/collection.py index c3ca5cfc..be1806ee 100644 --- a/skimage/io/collection.py +++ b/skimage/io/collection.py @@ -12,7 +12,6 @@ import six from PIL import Image from skimage.external.tifffile import TiffFile -from skimage.io._plugins.pil_plugin import pil_to_ndarray __all__ = ['MultiImage', 'ImageCollection', 'concatenate_images', @@ -76,6 +75,7 @@ def alphanumeric_key(s): class ImageCollection(object): + """Load and manage a collection of image files. Note that files are always stored in alphabetical order. Also note that @@ -151,6 +151,7 @@ class ImageCollection(object): >>> ic = io.ImageCollection('/tmp/work/*.png:/tmp/other/*.jpg') """ + def __init__(self, load_pattern, conserve_memory=True, load_func=None): """Load and manage a collection of images.""" if isinstance(load_pattern, six.string_types): @@ -243,8 +244,8 @@ class ImageCollection(object): n = self._check_imgnum(n) idx = n % len(self.data) - if (self.conserve_memory and n != self._cached) or \ - (self.data[idx] is None): + if ((self.conserve_memory and n != self._cached) or + (self.data[idx] is None)): if self._frame_index: fname, img_num = self._frame_index[idx] print('loading function')