mirror of
https://github.com/wassname/scikit-image.git
synced 2026-06-29 11:01:19 +08:00
Fix 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