import hashlib
from avatar import create_avatar
import sys

hash = hashlib.md5(sys.argv[1]).hexdigest()

# Creates a BMP file of 256x256 pixels (see docstring of create_avatar)
f = open("dog.bmp", "wb")
f.write(create_avatar(128, int(hash, 16)))
f.close()
