File tree Expand file tree Collapse file tree 2 files changed +19
-2
lines changed
Expand file tree Collapse file tree 2 files changed +19
-2
lines changed Original file line number Diff line number Diff line change @@ -29,6 +29,11 @@ igraph_get_shortest_path_astar:
2929 # igraph_astar_heuristic_func_t not handled yet
3030 IGNORE : PythonCTypes, PythonCTypesTypedWrapper
3131
32+ igraph_empty :
33+ # Changed the default value of 'directed' to false. Can be removed when
34+ # the main igraph repo also changes the default
35+ PARAMS : OUT GRAPH graph, INTEGER n=0, BOOLEAN directed=False
36+
3237igraph_empty_attrs :
3338 # Not needed at all
3439 IGNORE : PythonCTypes, PythonCTypesTypedWrapper
Original file line number Diff line number Diff line change 3636# The rest of this file is generated by Stimulus
3737
3838
39- def empty (n : int = 0 , directed : bool = True ) -> Graph :
39+ def empty (n : int = 0 , directed : bool = False ) -> Graph :
4040 """Creates an empty graph with the given number of vertices.
4141
4242 Parameters:
4343 n: the number of vertices
4444 directed: whether the graph is directed
45+
46+ Returns:
47+ the newly created graph
4548 """
4649 # Prepare input arguments
4750 c_graph = _Graph ()
@@ -338,7 +341,16 @@ def is_same_graph(graph1: Graph, graph2: Graph) -> bool:
338341
339342
340343def create (edges : Iterable [int ], n : int = 0 , directed : bool = True ) -> Graph :
341- """Type-annotated wrapper for ``igraph_create``."""
344+ """Creates a graph from the given edge list.
345+
346+ Parameters:
347+ edges: the list of edges in the graph
348+ n: the number of vertices in the graph if it cannot be inferred from
349+ the maximum edge ID in the edge list
350+
351+ Returns:
352+ the newly created graph
353+ """
342354 # Prepare input arguments
343355 c_graph = _Graph ()
344356 c_edges = iterable_to_igraph_vector_int_t_view (edges )
You can’t perform that action at this time.
0 commit comments