Imported python plankton codec from c-neutrino.