Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
from matplotlib import pyplot
from matplotlib import cm
import numpy
data = '010101010101010101011110111010101100001001101110110011000010001101110010011100001001100011000101110111100000010100101111001111011110001000101000010001110110111111001100101100101000011000011110110011000111001000101110001100100101010011010011011011110000011111111000010011001001111111101100000101011100011111000000000000000000'
data = list(data)
pyplot.imsave('datamatrix.png', numpy.array(data).reshape(18,18), cmap=cm.gray)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment