Advertisement
patryk

KCK - Lab 3.11

Nov 3rd, 2015
412
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.49 KB | None | 0 0
  1. from skimage import data, io, filters, morphology
  2. from matplotlib import pyplot as plt
  3.  
  4. IMAGE_LIST = ["samolot00.jpg", "samolot01.jpg", "samolot03.jpg", "samolot06.jpg", "samolot07.jpg", "samolot08.jpg"]
  5.  
  6.  
  7. def main():
  8.     for i in range(1,7):
  9.         plt.subplot(2,3,i)
  10.         image = data.imread(IMAGE_LIST[i - 1], as_grey=True)
  11.         edges = morphology.erosion(image)
  12.         edges = filters.canny(edges)
  13.         plt.axis('off')
  14.         plt.imshow(edges, cmap='gray')
  15.     plt.show()
  16.  
  17. if (__name__ == "__main__"): main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement