diff --git a/TODO.txt b/TODO.txt index e8e70e6c..3e6b3a7e 100644 --- a/TODO.txt +++ b/TODO.txt @@ -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 `__ ) +* 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 `__ ) Version 0.12 ------------ diff --git a/skimage/filter/__init__.py b/skimage/filter/__init__.py index 75bbb6b9..0228957e 100644 --- a/skimage/filter/__init__.py +++ b/skimage/filter/__init__.py @@ -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',