Created
January 25, 2015 12:12
-
-
Save shakes76/150d2722b291c1ccb409 to your computer and use it in GitHub Desktop.
Test script for the imageio PGM read member
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
""" | |
Test Read PGM member | |
Created on Sun Jan 25 21:52:38 2015 | |
@author: shakes | |
""" | |
import imageio | |
image, depth = imageio.readPGM("lena.pgm") | |
frtSpace, depth = imageio.readPGM("frtSpace.pgm") | |
#Plot | |
import matplotlib.pyplot as plt | |
#plot images | |
fig, ax = plt.subplots(nrows=1, ncols=2, figsize=(16, 5)) | |
plt.gray() | |
ax[0].imshow(image) | |
ax[0].axis('off') | |
ax[0].set_title('Image') | |
ax[1].imshow(frtSpace) | |
ax[1].axis('off') | |
ax[1].set_title('FRT of Lena') | |
plt.show() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment