#NEWLINE# def get_writer( data , basename , filetype ) : #NEWLINE# #INDENT# if ( data == 'png' ) : #NEWLINE# #INDENT# from depixel import io_png #NEWLINE# return io_png . PixelDataPngWriter ( data , basename ) #NEWLINE# #UNINDENT# if ( filetype == 'svg' ) : #NEWLINE# #INDENT# from depixel import io_svg #NEWLINE# return io_svg . PixelDataSvgWriter ( data , basename ) #NEWLINE# #UNINDENT# raise NotImplementedError ( ( "I don't recognise '%s' as a file type." % ( filetype , ) ) )