-
-
Save mmeendez8/aa5b73d6d64cf5e1ceba31472a1ebf64 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| # Create mesh grid of values | |
| values = np.arange(-3, 4, .5) | |
| xx, yy = np.meshgrid(values, values) | |
| input_holder = np.zeros((1, 2)) | |
| # Matrix that will contain the grid of images | |
| container = np.zeros((28 * len(values), 28 * len(values))) | |
| for row in range(xx.shape[0]): | |
| for col in range(xx.shape[1]): | |
| input_holder[0, :] = [xx[row, col], yy[row, col]] | |
| artificial_image = sess.run(output, feed_dict={z: input_holder}) | |
| container[row * 28: (row + 1) * 28, col * 28: (col + 1) * 28] = np.squeeze(artificial_image) | |
| plt.imshow(container, cmap='gray') | |
| plt.savefig(os.path.join(results_folder, 'Test/Space_{}'.format(epoch))) | |
| plt.close() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment