converted to DiGraph