def d3write(fct, path, *args, **kwargs):
 formatter = PyDotFormatter(*args, **kwargs)
 graph = formatter(fct)
 graph.write_dot(path)

def d3write ( fct , path , * args , ** kwargs ) : formatter = PyDotFormatter ( * args , ** kwargs ) graph = formatter ( fct ) graph . write_dot ( path )
convert theano graph to pydot graph and write to dot file .