mirror of
https://github.com/wassname/scikit-image.git
synced 2026-06-28 02:47:01 +08:00
examples: Avoid python3-specific syntax.
from __future__ import ... is ineffective when the example script is exec-ed by sphinx, resulting in a SyntaxError when running under python2. Fixes gh-649.
This commit is contained in:
@@ -194,12 +194,12 @@ refs = {
|
||||
|
||||
# classify rotated textures
|
||||
print('Rotated images matched against references using LBP:')
|
||||
print('original: brick, rotated: 30deg, match result: ', end='')
|
||||
print(match(refs, rotate(brick, angle=30, resize=False)))
|
||||
print('original: brick, rotated: 70deg, match result: ', end='')
|
||||
print(match(refs, rotate(brick, angle=70, resize=False)))
|
||||
print('original: grass, rotated: 145deg, match result: ', end='')
|
||||
print(match(refs, rotate(grass, angle=145, resize=False)))
|
||||
print('original: brick, rotated: 30deg, match result: ',
|
||||
match(refs, rotate(brick, angle=30, resize=False)))
|
||||
print('original: brick, rotated: 70deg, match result: ',
|
||||
match(refs, rotate(brick, angle=70, resize=False)))
|
||||
print('original: grass, rotated: 145deg, match result: ',
|
||||
match(refs, rotate(grass, angle=145, resize=False)))
|
||||
|
||||
# plot histograms of LBP of textures
|
||||
fig, ((ax1, ax2, ax3), (ax4, ax5, ax6)) = plt.subplots(nrows=2, ncols=3,
|
||||
|
||||
Reference in New Issue
Block a user