Skip to content

Commit

Permalink
2x faster import
Browse files Browse the repository at this point in the history
imported
  • Loading branch information
LaurentRDC committed Jun 1, 2018
1 parent d1d2b1d commit 419d6da
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions skued/io/io.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# -*- coding: utf-8 -*-

from pathlib import Path
from skimage.io import imread as skread
from tifffile import imread as tiffread
import skimage
import tifffile

from .merlin import mibread

Expand Down Expand Up @@ -41,11 +41,11 @@ def diffread(fname):
fname = str(fname) # In case of pathlib.Path

if fname.endswith(('tiff', 'tif')):
return tiffread(fname)
return tiffile.imread(fname)
elif fname.endswith('.mib'):
return mibread(fname)
else:
return skread(fname, as_grey = True)
return skimage.io.imread(fname, as_grey = True)

def diffshow(image):
"""
Expand Down

0 comments on commit 419d6da

Please sign in to comment.