mirror of
https://github.com/wassname/scikit-image.git
synced 2026-07-13 03:52:54 +08:00
Merge pull request #48 from cgohlke/patch-5
BUG: `TypeError: must use keyword argument for key function` on Python 3.
This commit is contained in:
@@ -61,7 +61,7 @@ def test_probabilistic_hough():
|
||||
sorted_lines = []
|
||||
for line in lines:
|
||||
line = list(line)
|
||||
line.sort(lambda x,y: cmp(x[0], y[0]))
|
||||
line.sort(key=lambda x: x[0])
|
||||
sorted_lines.append(line)
|
||||
assert([(25, 75), (74, 26)] in sorted_lines)
|
||||
assert([(25, 25), (74, 74)] in sorted_lines)
|
||||
|
||||
Reference in New Issue
Block a user