mirror of
https://github.com/wassname/scikit-image.git
synced 2026-06-27 20:22:51 +08:00
hack to avoid circular import when import canny
This commit is contained in:
@@ -3,7 +3,8 @@ Remember to list any API changes below in `doc/source/api_changes.txt`.
|
||||
Version 0.13
|
||||
------------
|
||||
* Remove deprecated `None` defaults for `skimage.exposure.rescale_intensity`
|
||||
* Remove deprecated `skimage.filter.canny` import in __init__.py that is now in `skimage.feature.canny` (and complete api_changes.txt. `GitHub discuss <https://github.com/scikit-image/scikit-image/pull/1113/files#r16934196>`__ )
|
||||
* Remove deprecated `skimage.filter.canny` import in filter/__init__.py file (canny is now in `skimage.feature.canny`).
|
||||
* Don't forget to complete api_changes.txt. (`GitHub discuss <https://github.com/scikit-image/scikit-image/pull/1113>`__ )
|
||||
|
||||
Version 0.12
|
||||
------------
|
||||
|
||||
@@ -19,8 +19,11 @@ denoise_tv_chambolle = deprecated('skimage.restoration.denoise_tv_chambolle')\
|
||||
(restoration.denoise_tv_chambolle)
|
||||
|
||||
# Backward compatibility v<0.11
|
||||
from ..feature import canny
|
||||
canny = deprecated('skimage.feature.canny')(canny)
|
||||
@deprecated
|
||||
def canny(*args, **kwargs):
|
||||
# Hack to avoid circular import
|
||||
from skimage.feature._canny import canny as canny_
|
||||
return canny_(*args, **kwargs)
|
||||
|
||||
|
||||
__all__ = ['inverse',
|
||||
|
||||
Reference in New Issue
Block a user