def pydot_layout(G,prog='neato',root=None, **kwds):
    import pydotplus
    P=to_pydot(G)
    if root is not None :
        P.set("root",make_str(root))

    D=P.create_dot(prog=prog)

    if D=="":  # no data returned
        print("Graphviz layout with %s failed"%(prog))
        print()
        print("To debug what happened try:")
        print("P=pydot_from_networkx(G)")
        print("P.write_dot(\"file.dot\")")
        print("And then run %s on file.dot"%(prog))
        return

    Q=pydotplus.graph_from_dot_data(D)

    node_pos={}
    for n in G.nodes():
        pydot_node = pydotplus.Node(make_str(n)).get_name()
        node=Q.get_node(pydot_node)

        if isinstance(node,list):
            node=node[0]
        pos=node.get_pos()[1:-1] # strip leading and trailing double quotes
        if pos != None:
            xx,yy=pos.split(",")
            node_pos[n]=(float(xx),float(yy))
    return node_pos

# fixture for nose tests
Correctly recognizes that the first sql statment does not create
dataset/ETHPy150Open networkx/networkx/networkx/drawing/nx_pydot.py/pydot_layout--crossover with--dataset/ETHPy150Open coursera/dataduct/dataduct/database/sql/tests/test_sql_script.py/TestSqlScript.test_creates_view_failure_not_first_statement