--- Begin Message ---
Source: skimage
Severity: normal
Tags: patch
User: debian-pyt...@lists.debian.org
Usertags: python3.6
Dear Maintainer,
skimage fails tests with Python 3.6 so in Ubuntu I upgraded to 0.13.0. uscan +
uupdate + the attached patch to debian/ did the trick for me.
Cheers,
mwh
-- System Information:
Debian Release: stretch/sid
APT prefers xenial-updates
APT policy: (500, 'xenial-updates'), (500, 'xenial-security'), (500,
'xenial'), (400, 'xenial-proposed'), (100, 'xenial-backports')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 4.4.0-83-generic (SMP w/4 CPU cores)
Locale: LANG=en_NZ.UTF-8, LC_CTYPE=en_NZ.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
diff -Nru skimage-0.12.3/debian/changelog skimage-0.13.0/debian/changelog
--- skimage-0.12.3/debian/changelog 2017-06-08 11:32:15.000000000 +1200
+++ skimage-0.13.0/debian/changelog 2017-07-17 09:08:23.000000000 +1200
@@ -1,3 +1,18 @@
+skimage (0.13.0-0ubuntu1) artful; urgency=medium
+
+ * New upstream release.
+ * d/patches/:
+ - changeset_6807f4ee8f5501703e447f95701190c836deaae1.diff,
+ dask-optional-dep.patch, fix_shape_type.patch, search-html.patch: dropped,
+ applied upstream.
+ - fix-doc-links.patch: updated
+ - skip_tests_failing_on_some_architectures.patch: split into more targetted
+ skip-failing-test-on-i386.patch & skip-failing-test-on-big-endian.patch.
+ * d/rules: CONTRIBUTING.txt has moved.
+ * d/control: add dependencies on python{3,}-pywt. python{3,}-numpydoc.
+
+ -- Michael Hudson-Doyle <michael.hud...@ubuntu.com> Fri, 14 Jul 2017 12:34:25 +1200
+
skimage (0.12.3-9build1) artful; urgency=medium
* No change rebuild to add Python 3.6 support.
diff -Nru skimage-0.12.3/debian/control skimage-0.13.0/debian/control
--- skimage-0.12.3/debian/control 2017-04-28 21:23:39.000000000 +1200
+++ skimage-0.13.0/debian/control 2017-07-14 14:07:54.000000000 +1200
@@ -10,21 +11,25 @@
libjs-twitter-bootstrap,
python-all-dev (>= 2.6.6-3~),
python-matplotlib (>= 1.3.1),
+ python-networkx (>= 1.8),
python-nose,
python-numpy (>= 1.7.2),
+ python-numpydoc,
python-pil (>= 1.7.8) | python-imaging,
+ python-pywt,
python-scipy (>= 0.10),
- python-networkx (>= 1.8),
python-setuptools,
python-six (>= 1.4),
python-sphinx (>= 1.3.0),
python3-all-dev,
python3-matplotlib (>= 1.3.1),
+ python3-networkx (>= 1.8),
python3-nose,
python3-numpy (>= 1.7.2),
+ python3-numpydoc,
python3-pil (>= 1.7.8) | python3-imaging,
+ python3-pywt,
python3-scipy,
- python3-networkx (>= 1.8),
python3-setuptools,
python3-six (>= 1.3.0),
xauth,
@@ -38,17 +43,16 @@
Package: python-skimage
Architecture: all
-Depends: python-numpy,
+Depends: python-matplotlib (>= 1.3.1),
+ python-networkx (>= 1.8),
+ python-numpy,
+ python-pil (>= 1.7.8) | python-imaging,
python-scipy (>= 0.10),
python-six (>= 1.4),
- python-matplotlib (>= 1.3.1),
- python-pil (>= 1.7.8) | python-imaging,
- python-networkx (>= 1.8),
python-skimage-lib (>= ${source:Version}),
${misc:Depends},
${python:Depends}
-Recommends: python-nose,
- python-qt4
+Recommends: python-nose, python-qt4
Suggests: python-opencv, python-skimage-doc
Description: Python modules for image processing
scikit-image is a collection of image processing algorithms for
@@ -59,12 +63,12 @@
Package: python3-skimage
Architecture: all
-Depends: python3-numpy (>= 1.7.2),
+Depends: python3-matplotlib (>= 1.3.1),
+ python3-networkx (>= 1.8),
+ python3-numpy (>= 1.7.2),
+ python3-pil (>= 1.7.8) | python3-imaging,
python3-scipy (>= 0.10),
python3-six (>= 1.4),
- python3-matplotlib (>= 1.3.1),
- python3-pil (>= 1.7.8) | python3-imaging,
- python3-networkx (>= 1.8),
python3-skimage-lib (>= ${source:Version}),
${misc:Depends},
${python3:Depends}
diff -Nru skimage-0.12.3/debian/patches/changeset_6807f4ee8f5501703e447f95701190c836deaae1.diff skimage-0.13.0/debian/patches/changeset_6807f4ee8f5501703e447f95701190c836deaae1.diff
--- skimage-0.12.3/debian/patches/changeset_6807f4ee8f5501703e447f95701190c836deaae1.diff 2017-04-28 21:04:03.000000000 +1200
+++ skimage-0.13.0/debian/patches/changeset_6807f4ee8f5501703e447f95701190c836deaae1.diff 1970-01-01 12:00:00.000000000 +1200
@@ -1,14 +0,0 @@
-From: Yaroslav Halchenko <deb...@onerussian.com>
-Subject: BF: Initialize firstbg to the numels so if no bg value found, second loop is not executed
-
---- a/skimage/measure/_ccomp.pyx
-+++ b/skimage/measure/_ccomp.pyx
-@@ -541,7 +541,7 @@ cdef void scanBG(DTYPE_t *data_p, DTYPE_
-
- The result of this function is update of forest_p and bg parameter.
- """
-- cdef DTYPE_t i, bgval = bg.background_val, firstbg
-+ cdef DTYPE_t i, bgval = bg.background_val, firstbg = shapeinfo.numels
- # We find the provisional label of the background, which is the index of
- # the first background pixel
- for i in range(shapeinfo.numels):
diff -Nru skimage-0.12.3/debian/patches/dask-optional-dep.patch skimage-0.13.0/debian/patches/dask-optional-dep.patch
--- skimage-0.12.3/debian/patches/dask-optional-dep.patch 2017-04-28 21:04:03.000000000 +1200
+++ skimage-0.13.0/debian/patches/dask-optional-dep.patch 1970-01-01 12:00:00.000000000 +1200
@@ -1,77 +0,0 @@
-Description: Make dask an optional dependency.
-
---- a/skimage/util/apply_parallel.py
-+++ b/skimage/util/apply_parallel.py
-@@ -4,6 +4,13 @@
- __all__ = ['apply_parallel']
-
-
-+try:
-+ import dask.array as da
-+ dask_available = True
-+except ImportError:
-+ dask_available = False
-+
-+
- def _get_chunks(shape, ncpu):
- """Split the array into equal sized chunks based on the number of
- available processors. The last chunk in each dimension absorbs the
-@@ -82,7 +89,9 @@
- equivalent `dask` boundary modes 'reflect', 'periodic' and 'nearest',
- respectively.
- """
-- import dask.array as da
-+ if not dask_available:
-+ raise RuntimeError("Could not import 'dask'. Please install "
-+ "using 'pip install dask'")
-
- if chunks is None:
- shape = array.shape
---- a/skimage/util/tests/test_apply_parallel.py
-+++ b/skimage/util/tests/test_apply_parallel.py
-@@ -2,11 +2,13 @@
-
- import numpy as np
- from numpy.testing import assert_array_almost_equal
-+from numpy.testing.decorators import skipif
-
- from skimage.filters import threshold_adaptive, gaussian
--from skimage.util.apply_parallel import apply_parallel
-+from skimage.util.apply_parallel import apply_parallel, dask_available
-
-
-+@skipif(not dask_available)
- def test_apply_parallel():
- # data
- a = np.arange(144).reshape(12, 12).astype(float)
-@@ -28,6 +30,7 @@
- assert_array_almost_equal(result2, expected2)
-
-
-+@skipif(not dask_available)
- def test_no_chunks():
- a = np.ones(1 * 4 * 8 * 9).reshape(1, 4, 8, 9)
-
-@@ -40,6 +43,7 @@
- assert_array_almost_equal(result, expected)
-
-
-+@skipif(not dask_available)
- def test_apply_parallel_wrap():
- def wrapped(arr):
- return gaussian(arr, 1, mode='wrap')
-@@ -50,6 +54,7 @@
- assert_array_almost_equal(result, expected)
-
-
-+@skipif(not dask_available)
- def test_apply_parallel_nearest():
- def wrapped(arr):
- return gaussian(arr, 1, mode='nearest')
---- a/requirements.txt
-+++ b/requirements.txt
-@@ -4,4 +4,3 @@
- six>=1.7.3
- networkx>=1.8
- pillow>=2.1.0
--dask[array]>=0.5.0
diff -Nru skimage-0.12.3/debian/patches/doc-privacy.patch skimage-0.13.0/debian/patches/doc-privacy.patch
--- skimage-0.12.3/debian/patches/doc-privacy.patch 2017-04-28 21:04:03.000000000 +1200
+++ skimage-0.13.0/debian/patches/doc-privacy.patch 2017-07-14 12:41:13.000000000 +1200
@@ -19,7 +19,7 @@
{%- for cssfile in css_files %}
<link rel="stylesheet" href="{{ pathto(cssfile, 1) }}" type="text/css" />
{%- endfor %}
-@@ -111,20 +109,3 @@
+@@ -106,20 +104,3 @@
</div>
</body>
</html>
diff -Nru skimage-0.12.3/debian/patches/fix-doc-links.patch skimage-0.13.0/debian/patches/fix-doc-links.patch
--- skimage-0.12.3/debian/patches/fix-doc-links.patch 2017-04-28 21:04:03.000000000 +1200
+++ skimage-0.13.0/debian/patches/fix-doc-links.patch 2017-07-14 12:41:06.000000000 +1200
@@ -2,15 +2,17 @@
change to absolute filesystem links
--- a/doc/source/_templates/navbar.html
+++ b/doc/source/_templates/navbar.html
-@@ -1,7 +1,7 @@
+@@ -1,8 +1,8 @@
-<li><a href="/">Home</a></li>
-<li><a href="/download.html">Download</a></li>
-<li><a href="/docs/dev/auto_examples">Gallery</a></li>
-<li><a href="/docs/dev">Documentation</a></li>
+-<li><a href="/community_guidelines.html">Community Guidelines</a></li>
+<li><a href="/usr/share/doc/python-skimage-doc/html/index.html">Home</a></li>
+<li><a href="http://scikit-image.org/download.html">Download</a></li>
+<li><a href="/usr/share/doc/python-skimage-doc/html/auto_examples/index.html">Gallery</a></li>
+<li><a href="/usr/share/doc/python-skimage-doc/html/index.html">Documentation</a></li>
++<li><a href="/usr/share/doc/python-skimage-doc/html/community_guidelines.html">Community Guidelines</a></li>
+
<li><a href="https://github.com/scikit-image/scikit-image">
<img src="{{ pathto('_static', 1) }}/GitHub-Mark-32px.png"
- style="height: 15px; width: 15px;
diff -Nru skimage-0.12.3/debian/patches/fix_shape_type.patch skimage-0.13.0/debian/patches/fix_shape_type.patch
--- skimage-0.12.3/debian/patches/fix_shape_type.patch 2017-04-28 21:04:03.000000000 +1200
+++ skimage-0.13.0/debian/patches/fix_shape_type.patch 1970-01-01 12:00:00.000000000 +1200
@@ -1,15 +0,0 @@
-Author: Ole Streicher <oleb...@debian.org>
-Description: Fix shape type for histogram
-
-The number of bins is always an integer, independently of the image data type.
---- a/skimage/filters/rank/generic.py
-+++ b/skimage/filters/rank/generic.py
-@@ -977,7 +977,7 @@
- """
-
- if n_bins is None:
-- n_bins = image.max() + 1
-+ n_bins = int(image.max()) + 1
-
- return _apply_vector_per_pixel(generic_cy._windowed_hist, image, selem,
- out=out, mask=mask,
diff -Nru skimage-0.12.3/debian/patches/search-html.patch skimage-0.13.0/debian/patches/search-html.patch
--- skimage-0.12.3/debian/patches/search-html.patch 2017-04-28 21:04:03.000000000 +1200
+++ skimage-0.13.0/debian/patches/search-html.patch 1970-01-01 12:00:00.000000000 +1200
@@ -1,21 +0,0 @@
-Description: change to ajax load of searchindex
- required so dh_sphinx recognises it as a search.html
---- a/doc/source/themes/scikit-image/search.html
-+++ b/doc/source/themes/scikit-image/search.html
-@@ -10,7 +10,15 @@
- {% extends "layout.html" %}
- {% set title = _('Search') %}
- {% set script_files = script_files + ['_static/searchtools.js'] %}
--{% set script_files = script_files + ['searchindex.js'] %}
-+{% block extrahead %}
-+ <script type="text/javascript">
-+ jQuery(function() { Search.loadIndex("{{ pathto('searchindex.js', 1) }}"); });
-+ </script>
-+ {# this is used when loading the search index using $.ajax fails,
-+ such as on Chrome for documents on localhost #}
-+ <script type="text/javascript" id="searchindexloader"></script>
-+ {{ super() }}
-+{% endblock %}
- {% block body %}
- <h1 id="search-documentation">{{ _('Search') }}</h1>
- <div id="fallback" class="admonition warning">
diff -Nru skimage-0.12.3/debian/patches/series skimage-0.13.0/debian/patches/series
--- skimage-0.12.3/debian/patches/series 2017-04-28 21:04:03.000000000 +1200
+++ skimage-0.13.0/debian/patches/series 2017-07-14 16:02:47.000000000 +1200
@@ -1,7 +1,4 @@
-changeset_6807f4ee8f5501703e447f95701190c836deaae1.diff
-dask-optional-dep.patch
-search-html.patch
fix-doc-links.patch
doc-privacy.patch
-fix_shape_type.patch
-skip_tests_failing_on_some_architectures.patch
+skip-failing-test-on-big-endian.patch
+skip-failing-test-on-i386.patch
diff -Nru skimage-0.12.3/debian/patches/skip-failing-test-on-big-endian.patch skimage-0.13.0/debian/patches/skip-failing-test-on-big-endian.patch
--- skimage-0.12.3/debian/patches/skip-failing-test-on-big-endian.patch 1970-01-01 12:00:00.000000000 +1200
+++ skimage-0.13.0/debian/patches/skip-failing-test-on-big-endian.patch 2017-07-14 16:05:53.000000000 +1200
@@ -0,0 +1,22 @@
+--- a/skimage/io/tests/test_pil.py
++++ b/skimage/io/tests/test_pil.py
+@@ -1,8 +1,10 @@
+ import os.path
+ import numpy as np
++import sys
+ from numpy.testing import (
+ assert_array_equal, assert_array_almost_equal, assert_raises,
+ assert_allclose, run_module_suite)
++from numpy.testing.decorators import skipif
+
+ from tempfile import NamedTemporaryFile
+
+@@ -220,6 +222,8 @@
+ color_check('pil', 'bmp')
+
+
++# https://github.com/scikit-image/scikit-image/issues/2120
++@skipif(sys.byteorder == 'big')
+ def test_all_mono():
+ mono_check('pil')
+
diff -Nru skimage-0.12.3/debian/patches/skip-failing-test-on-i386.patch skimage-0.13.0/debian/patches/skip-failing-test-on-i386.patch
--- skimage-0.12.3/debian/patches/skip-failing-test-on-i386.patch 1970-01-01 12:00:00.000000000 +1200
+++ skimage-0.13.0/debian/patches/skip-failing-test-on-i386.patch 2017-07-14 23:13:36.000000000 +1200
@@ -0,0 +1,47 @@
+--- a/skimage/feature/tests/test_orb.py
++++ b/skimage/feature/tests/test_orb.py
+@@ -1,6 +1,8 @@
++import os
+ import numpy as np
+ from numpy.testing import (assert_equal, assert_almost_equal, run_module_suite,
+ assert_raises)
++from numpy.testing.decorators import skipif
+ from skimage.feature import ORB
+ from skimage import data
+ from skimage._shared.testing import test_parallel
+@@ -69,6 +71,8 @@
+ assert_almost_equal(exp_cols, detector_extractor.keypoints[:, 1])
+
+
++# https://github.com/scikit-image/scikit-image/issues/2529
++@skipif(os.uname()[4] == 'i686')
+ def test_descriptor_orb():
+ detector_extractor = ORB(fast_n=12, fast_threshold=0.20)
+
+--- a/skimage/filters/rank/tests/test_rank.py
++++ b/skimage/filters/rank/tests/test_rank.py
+@@ -10,6 +10,7 @@
+ from skimage._shared._warnings import expected_warnings
+ from skimage._shared.testing import test_parallel
+
++machine = os.uname()[4]
+
+ class TestRank():
+ def setup(self):
+@@ -82,10 +83,12 @@
+ rank.tophat(self.image, selem))
+ assert_equal(refs["noise_filter"],
+ rank.noise_filter(self.image, selem))
+- assert_equal(refs["entropy"],
+- rank.entropy(self.image, selem))
+- assert_equal(refs["otsu"],
+- rank.otsu(self.image, selem))
++ # https://github.com/scikit-image/scikit-image/issues/2528
++ if machine != "i686":
++ assert_equal(refs["entropy"],
++ rank.entropy(self.image, selem))
++ assert_equal(refs["otsu"],
++ rank.otsu(self.image, selem))
+ assert_equal(refs["percentile"],
+ rank.percentile(self.image, selem))
+ assert_equal(refs["windowed_histogram"],
diff -Nru skimage-0.12.3/debian/patches/skip_tests_failing_on_some_architectures.patch skimage-0.13.0/debian/patches/skip_tests_failing_on_some_architectures.patch
--- skimage-0.12.3/debian/patches/skip_tests_failing_on_some_architectures.patch 2017-04-28 21:04:03.000000000 +1200
+++ skimage-0.13.0/debian/patches/skip_tests_failing_on_some_architectures.patch 1970-01-01 12:00:00.000000000 +1200
@@ -1,91 +0,0 @@
-Author: Andreas Tille <ti...@debian.org>
-Last-Update: Fri, 23 Dec 2016 08:45:21 +0100
-Bug-Debian: https://bugs.debian.org/840589
-Description: For the moment ignore tests failing on some architectures
-
---- a/skimage/feature/tests/test_orb.py
-+++ b/skimage/feature/tests/test_orb.py
-@@ -67,41 +67,5 @@
- assert_almost_equal(exp_rows, detector_extractor.keypoints[:, 0])
- assert_almost_equal(exp_cols, detector_extractor.keypoints[:, 1])
-
--
--def test_descriptor_orb():
-- detector_extractor = ORB(fast_n=12, fast_threshold=0.20)
--
-- exp_descriptors = np.array([[0, 1, 1, 1, 0, 1, 0, 1, 0, 1],
-- [1, 1, 1, 0, 0, 1, 0, 0, 1, 1],
-- [1, 0, 1, 1, 0, 0, 1, 1, 0, 0],
-- [0, 0, 0, 0, 0, 0, 0, 0, 1, 0],
-- [0, 1, 0, 0, 0, 0, 0, 0, 1, 0],
-- [1, 1, 0, 1, 1, 1, 0, 0, 1, 1],
-- [1, 1, 0, 1, 0, 0, 1, 0, 1, 1],
-- [0, 0, 1, 0, 1, 0, 0, 1, 1, 0],
-- [1, 0, 0, 0, 1, 0, 0, 0, 0, 1],
-- [0, 1, 1, 1, 1, 1, 1, 1, 1, 1],
-- [1, 1, 0, 1, 0, 1, 0, 0, 1, 1],
-- [1, 1, 1, 0, 0, 0, 1, 1, 1, 0],
-- [1, 1, 1, 1, 1, 1, 0, 0, 0, 0],
-- [1, 1, 1, 0, 1, 1, 1, 1, 0, 0],
-- [1, 1, 0, 0, 1, 0, 0, 1, 0, 1],
-- [1, 1, 0, 0, 0, 0, 1, 0, 0, 1],
-- [0, 0, 0, 0, 1, 1, 1, 0, 1, 0],
-- [0, 0, 0, 0, 1, 1, 1, 0, 0, 1],
-- [0, 0, 0, 0, 0, 1, 1, 0, 1, 1],
-- [0, 0, 0, 0, 1, 0, 1, 0, 1, 1]], dtype=bool)
-- detector_extractor.detect(img)
-- detector_extractor.extract(img, detector_extractor.keypoints,
-- detector_extractor.scales,
-- detector_extractor.orientations)
-- assert_equal(exp_descriptors,
-- detector_extractor.descriptors[100:120, 10:20])
--
-- detector_extractor.detect_and_extract(img)
-- assert_equal(exp_descriptors,
-- detector_extractor.descriptors[100:120, 10:20])
--
--
- if __name__ == '__main__':
- run_module_suite()
---- a/skimage/filters/rank/tests/test_rank.py
-+++ b/skimage/filters/rank/tests/test_rank.py
-@@ -79,10 +79,10 @@
- rank.tophat(image, selem))
- assert_equal(refs["noise_filter"],
- rank.noise_filter(image, selem))
-- assert_equal(refs["entropy"],
-- rank.entropy(image, selem))
-- assert_equal(refs["otsu"],
-- rank.otsu(image, selem))
-+ #assert_equal(refs["entropy"],
-+ # rank.entropy(image, selem))
-+ #assert_equal(refs["otsu"],
-+ # rank.otsu(image, selem))
- assert_equal(refs["percentile"],
- rank.percentile(image, selem))
- assert_equal(refs["windowed_histogram"],
---- a/skimage/io/tests/test_pil.py
-+++ b/skimage/io/tests/test_pil.py
-@@ -216,10 +216,6 @@
- color_check('pil', 'bmp')
-
-
--def test_all_mono():
-- mono_check('pil')
--
--
- def test_multi_page_gif():
- img = imread(os.path.join(data_dir, 'no_time_for_that_tiny.gif'))
- assert img.shape == (24, 25, 14, 3), img.shape
---- a/skimage/transform/tests/test_integral.py
-+++ b/skimage/transform/tests/test_integral.py
-@@ -43,7 +43,8 @@
- x[30:, 31:].sum()])
- start_pts = [(r0[i], c0[i]) for i in range(len(r0))]
- end_pts = [(r1[i], c1[i]) for i in range(len(r0))]
-- assert_equal(expected, integrate(s, r0, c0, r1, c1)) # test deprecated
-+# see https://github.com/numpy/numpy/issues/8413
-+# assert_equal(expected, integrate(s, r0, c0, r1, c1)) # test deprecated
- assert_equal(expected, integrate(s, start_pts, end_pts))
-
-
diff -Nru skimage-0.12.3/debian/rules skimage-0.13.0/debian/rules
--- skimage-0.12.3/debian/rules 2017-04-28 21:16:36.000000000 +1200
+++ skimage-0.13.0/debian/rules 2017-07-14 13:13:35.000000000 +1200
@@ -85,7 +85,7 @@
endif
override_dh_installdocs:
- dh_installdocs -A CONTRIBUTORS.txt README.md CONTRIBUTING.txt TASKS.txt
+ dh_installdocs -A CONTRIBUTORS.txt README.md .github/CONTRIBUTING.txt TASKS.txt
dh_link -ppython-skimage-doc /usr/share/twitter-bootstrap/files/js/bootstrap.min.js \
usr/share/doc/python-skimage-doc/html/_static/js/bootstrap.min.js
dh_link -ppython-skimage-doc /usr/share/twitter-bootstrap/files/css/bootstrap.min.css \
--- End Message ---