I wish to draw an image based on computed pixel values, as a means to visualize some data. Essentially, I wish to take a 2-dimensional matrix of color triplets and render it
I think you use PIL to generate an image file on the disk, and you later load it with an image reader software.
You should get a small speed improvement by rendering directly the picture in memory (you will save the cost of writing the image on the disk and then re-loading it). Have a look at this thread https://stackoverflow.com/questions/326300/python-best-library-for-drawing for how to render that image with various python modules.
I would personally try wxpython and the dc.DrawBitmap function. If you use such a module rather than an external image reader you will have many benefits: