If you have a smaller image, you can include it in your program as a base64 encoded string. This way you don't have to worry about an image file to go with your code. In your program you can then decode it back to the familiar bytes of an image and use it. This code snippet should work with Python2 and Python3 versions.
Python2/Python3 Base64 Encoded Image
'''Base64encJPEG.py
create a base64 image string
changes the bytes of an image file into printable char combinations
that you can include in your program
tested with Python 2.7.3 and Python 3.3.0 by vegaseat 11nov2012
'''
import base64
# pick an image file you have in the working directory
# or give full path
img_file = "Btn_rainbow.jpg"
b64 = base64.encodestring(open(img_file,"rb").read())
try:
# Python2
print("rainbow_jpg_b64='''\\\n" + b64 + "'''")
except TypeError:
# Python3
print("rainbow_jpg_b64='''\\\n" + b64.decode("utf8") + "'''")
"""copy and paste from here ...
rainbow_jpg_b64='''\
/9j/4AAQSkZJRgABAQEAyADIAAD/2wBDAAEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEB
AQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQH/2wBDAQEBAQEBAQEBAQEBAQEBAQEBAQEB
AQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQH/wAARCAAoACgDASIA
AhEBAxEB/8QAHwAAAQUBAQEBAQEAAAAAAAAAAAECAwQFBgcICQoL/8QAtRAAAgEDAwIEAwUFBAQA
AAF9AQIDAAQRBRIhMUEGE1FhByJxFDKBkaEII0KxwRVS0fAkM2JyggkKFhcYGRolJicoKSo0NTY3
ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqDhIWGh4iJipKTlJWWl5iZmqKjpKWm
p6ipqrKztLW2t7i5usLDxMXGx8jJytLT1NXW19jZ2uHi4+Tl5ufo6erx8vP09fb3+Pn6/8QAHwEA
AwEBAQEBAQEBAQAAAAAAAAECAwQFBgcICQoL/8QAtREAAgECBAQDBAcFBAQAAQJ3AAECAxEEBSEx
BhJBUQdhcRMiMoEIFEKRobHBCSMzUvAVYnLRChYkNOEl8RcYGRomJyg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V8NTnhqOLlWpyrRr4rFOVZOrKLnCVOLhGPucycn//2Q==
'''
"""
Gribouillis 1,391 Programming Explorer Team Colleague
ZZucker 342 Practically a Master Poster
HiHe 174 Junior Poster
HiHe 174 Junior Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.