Use relative imports in skimage files

This commit is contained in:
Johannes Schönberger
2015-01-22 07:36:48 -05:00
parent ea95b5419b
commit ee5c6fbeb2
67 changed files with 149 additions and 155 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
import numpy as np
import skimage
from skimage.feature import canny
from ...feature import canny
from .overlayplugin import OverlayPlugin
from ..widgets import Slider, ComboBox
+1 -3
View File
@@ -1,7 +1,6 @@
import numpy as np
import matplotlib.pyplot as plt
from skimage import color
from skimage import exposure
from ... import color, exposure
from .plotplugin import PlotPlugin
from ..canvastools import RectangleTool
@@ -92,4 +91,3 @@ def pct_total_area(image, percentile=0.80):
idx = int((image.size - 1) * percentile)
sorted_pixels = np.sort(image.flat)
return sorted_pixels[idx]
+1 -1
View File
@@ -1,6 +1,6 @@
from .base import Plugin
from ..canvastools import RectangleTool
from skimage.viewer.widgets import SaveButtons
from ...viewer.widgets import SaveButtons
__all__ = ['Crop']
+3 -4
View File
@@ -1,9 +1,8 @@
from __future__ import division
import numpy as np
from skimage.util.dtype import dtype_range
from skimage import draw
from skimage import measure
from ...util.dtype import dtype_range
from ... import draw, measure
from .plotplugin import PlotPlugin
from ..canvastools import ThickLineTool
@@ -65,7 +64,7 @@ class LineProfile(PlotPlugin):
on_change=self.line_changed)
self.line_tool.end_points = np.transpose([x, y])
scan_data = measure.profile_line(image,
scan_data = measure.profile_line(image,
*self.line_tool.end_points[:, ::-1])
self.scan_data = scan_data
if scan_data.ndim == 1:
+2 -2
View File
@@ -1,11 +1,11 @@
from warnings import warn
from skimage.util.dtype import dtype_range
from ...util.dtype import dtype_range
from .base import Plugin
from ..utils import ClearColormap, update_axes_image
import six
from skimage._shared.version_requirements import is_installed
from ..._shared.version_requirements import is_installed
__all__ = ['OverlayPlugin']