mirror of
https://github.com/wassname/scikit-image.git
synced 2026-07-07 10:40:36 +08:00
used plt.subplots everywhere
This commit is contained in:
@@ -29,9 +29,9 @@ image[230:280, 60:110] = 1
|
||||
coords = corner_peaks(corner_harris(image), min_distance=5)
|
||||
coords_subpix = corner_subpix(image, coords, window_size=13)
|
||||
|
||||
plt.gray()
|
||||
plt.imshow(image, interpolation='nearest')
|
||||
plt.plot(coords[:, 1], coords[:, 0], '.b', markersize=3)
|
||||
plt.plot(coords_subpix[:, 1], coords_subpix[:, 0], '+r', markersize=15)
|
||||
plt.axis((0, 350, 350, 0))
|
||||
f, ax = plt.subplots()
|
||||
ax.imshow(image, interpolation='nearest', cmap=plt.cm.gray)
|
||||
ax.plot(coords[:, 1], coords[:, 0], '.b', markersize=3)
|
||||
ax.plot(coords_subpix[:, 1], coords_subpix[:, 0], '+r', markersize=15)
|
||||
ax.axis((0, 350, 350, 0))
|
||||
plt.show()
|
||||
|
||||
Reference in New Issue
Block a user