Bioprinter Documentation


Bioprinter is a Python module to produce living art. It transforms an image into files that a liquid dispenser can use to print the image to a plate using pigmented yeast or bacteria.

Here are two examples of bio-art:


Dolly drawn with baker yeast (white), violacein-producing yeast (black), and carotene-producing yeast (orange)


England flag drawn with 3 different strains of the bacterium E. coli.

Bioprinter is released on Github under the MIT licence (¢ Edinburgh Genome Foundry), everyone is welcome to contribute !

Bioprinter was written at the Edinburgh Genome Foundry by Zulko after an original idea and Matlab code by Mike Shen at the Boeke Lab (Mike’s project on Github).


If you have PIP installed:

(sudo) pip install ez_setup bioprinter

Or unzip the source code in a directory and type in a terminal:

sudo python install


In the same folder as your code, place an image. It can have any resolution, but keep in mind that the width/height ratio of the plate it is printed on is 1.5. Make sure that a specific color is used to mark the un-pigmented background of the image, here we use blue:


Then write the following code in

from bioprinter import bioprint

    bg_color=[0, 0, 255], # blue background represents empty wells
    pigments_wells={"A1": [0, 0, 0],  # black yeast in source well A1
                    "A2": [250, 120, 10],  # orange yeast in well A2
                    "A3": [255, 255, 255]},  # white yeast in well A3

Execute in a terminal with python This will produce a dolly.csv file as well as a preview image of the final printing (so that you can check if the image looks good at this low resolution).


Prepare a source plate with the right pigmented yeasts in wells A1, A2, A3, use an agar plate as the destination plate, and feed dolly.csv to the Labcyte Echo. Once the printing is finished, incubate 2 days at 30C (it would be one day at 37C for bacteria). Enjoy the result !

Reference manual

bioprinter.bioprint(image_filename, output_filename, bg_color, pigments_wells, resolution=(192, 128), transfer_volume=2.5, pigment_well_capacity=25000, transfer_rate=150, quantified_image_filename=None)[source]

Generate a CSV that can be used in the Echo to print the given picture.



The path the image file to be printed. Can be virtually any size and file format, but make sure the image is well adapted to low resolution yeast printing. If the picture is higher than wide it will be automatically rotated 90 degrees so as to maximize its resolution on the plate (the image aspect ratio is conserved).


The name of the CSV file written by the function, that will then be fed to the Echo.


A triplet (R,G,B) of 0-255 integers indicating which color of the original image represents the background (no pigment)


A dictionary of well names and the corresponding pigments. For instance {“A1”: [0,10,20], “B1”:...}. Only one well per pigment is currently supported.


Resolution (width, height) of the printing plate. You must define a plate with these exact same characteristics using the Echo software. Default is (192, 128) (twice the resolution of a 1536-well plate). The aspect ratio of the original image is always automatically conserved.


How many microliters of liquid should be used for each pixel. The default, 2.5, works very well and is also the lowest possible value on our Echo.


Volume in microliters that one pigments well can dispense. The function raises an error if the total number of pixels for one color exceeds the content of one pigment well, i.e. if

transfer_volume * number_pixels > well_capacity


Average number of droplet transfers per second, used only to give an estimate of the time required for printing.


If a path is provided, the quantified picture will be saved as an image file under this name.