clone a graph