Python interface for igraph
Added Graph.Prufer()
to construct a graph from a Prüfer sequence.
Added Graph.Bipartite_Degree_Sequence()
to construct a bipartite graph from a bidegree sequence.
Fixed import of graph-tool
graphs for vertex properties where each property has a vector value.
Graph.Adjacency()
now accepts Matrix
instances and other sequences as an input, it is not limited to lists-of-lists-of-ints any more.
Graph.__invalidate_cache()
for debugging and benchmarking purposes.loops=...
argument of Graph.is_bigraphical()
.python-igraph
is now tested in Python 3.12.
Added weights=...
keyword argument to Graph.layout_kamada_kawai()
.
matplotlib
plotting infrastructure underwent major surgery and is now able to show consistent vertex and edge drawings at any level of zoom, including with animations, and for any aspect ratio.vertex_size=25
is a reasonable size for igraph.plot
.edge_loop_size
argument in igraph.plot
.matplotlib
backend when plotting a graph, igraph.plot
now does not return the Axes
anymore. Instead, it returns a container artist called GraphArtist
, which contains as children the elements of the graph plot: a VertexCollection
for the vertices, and EdgeCollection
for the edges, and so on. These objects can be used to modify the plot after the initial rendering, e.g. inside a Jupyter notebook, to fine tune the appearance of the plot. While documentation on specific graphic elements is still scant, more descriptive examples will follow in the future.Fixed drawing order of vertices in the Plotly backend (#691).
Fixed plotting of null graphs with the Matplotlib backend.
Yes, the version number is correct - igraph 0.10.7 has never made it to PyPI. It is tagged in the repository, but it has never been released officially. The changelog below lists the changes between igraph 0.10.6 and 0.10.8.
Added is_bigraphical()
to test whether a pair of integer sequences can be the degree sequence of some bipartite graph.
Added weights=...
keyword argument to Graph.radius()
and Graph.eccentricity()
.
Graph.distances()
, Graph.get_shortest_path()
and Graph.get_shortest_paths()
now allow the user to select the algorithm to be used explicitly.
The C core of igraph was updated to version 0.10.7.
Graph.distances()
now uses Dijkstra's algorithm when there are zero weights but no negative weights. Earlier versions switched to Bellman-Ford or Johnson in the presence of zero weights unnecessarily.
Fixed a bug in EdgeSeq.select(_incident=...)
for undirected graphs.
Fixed a memory leak in Graph.distances()
when attempting to use Johnson's algorithm with mode != "out"
The C core of igraph was updated to version 0.10.6.
Graph.Incidence()
is now deprecated in favour of Graph.Biadjacency()
as it constructs a bipartite graph from a bipartite adjacency matrix. (The previous name was a mistake). Future versions might re-introduce Graph.Incidence()
to construct a graph from its incidence matrix.
Graph.get_incidence()
is now deprecated in favour of Graph.get_biadjacency()
as it returns the bipartite adjacency matrix of a graph and not its incidence matrix. (The previous name was a mistake). Future versions might re-introduce Graph.get_incidence()
to return the incidence matrix of a graph.
Reverted the change in 0.10.5 that prevented adding vertices with integers as vertex names. Now we show a deprecation warning instead, and the addition of vertices with integer names will be prevented from version 0.11.0 only.
Fixed a minor memory leak in Graph.decompose()
.
The default vertex size of the Plotly backend was fixed so the vertices are now visible by default without specifying an explicit size for them.
The plot()
function now takes a backend
keyword argument that can be used to specify the plotting backend explicitly.
The VertexClustering
object returned from Graph.community_leiden()
now contains an extra property named quality
that stores the value of the internal quality function optimized by the algorithm.
Graph.Adjacency()
and Graph.Weighted_Adjacency()
now supports loops="once"
, loops="twice"
and loops="ignore"
to control how loop edges are handled in a more granular way. loops=True
and loops=False
keep on working as in earlier versions.
Added Graph.get_shortest_path()
as a convenience function for cases when only one shortest path is needed between a given source and target vertices.
Added Graph.get_shortest_path_astar()
to calculate the shortest path between two vertices using the A-star algorithm and an appropriate heuristic function.
Added Graph.count_automorphisms()
to count the number of automorphisms of a graph and Graph.automorphism_group()
to calculate the generators of the automorphism group of a graph.
The VertexCover
constructor now allows referring to vertices by names instead of IDs.
resolution
parameter is now correctly taken into account when calling Graph.modularity()
VertexClustering.giant()
now accepts the null graph. The giant component of a null graph is the null graph according to our conventions.
Graph.layout_reingold_tilford()
now accepts vertex names in the roots=...
keyword argument.
The plotting of curved directed edges with the Cairo backend is now fixed; arrowheads were placed at the wrong position before this fix.
Graph.community_leading_eigenvector_naive()
method. Not a breaking change because it was already removed from the C core a long time ago so the function in the Python interface did not do anything useful either.Graph.vertex_coloring_greedy()
to calculate a greedy vertex coloring for the graph.VertexDendrogram
instances, both in the Cairo and the Matplotlib backends.cutoff
and normalized
arguments of Graph.closeness()
did not function correctly.The C core of igraph was updated to version 0.10.3.
UMAP layout now exposes the computation of the symmetrized edge weights via umap_compute_weights()
. The layout function, Graph.layout_umap()
, can now be called either on a directed graph with edge distances, or on an undirected graph with edge weights, typically computed via umap_compute_weights()
or precomputed by the user. Moreover, the sampling_prob
argument was faulty and has been removed. See PR #613 for details.
The resolution_parameter
argument of Graph.community_leiden()
was renamed to resolution
for sake of consistency. The old variant still works with a deprecation warning, but will be removed in a future version.
Graph.Data_Frame()
now handles the Int64
data type from pandas
, thanks to @Adriankhl. See PR #609 for details.
Graph.layout_lgl()
root
argument is now optional (as it should have been).
The VertexClustering
class now handles partial dendrograms correctly.
python-igraph
is now tested in Python 3.11.Graph.modularity_matrix()
to calculate the modularity matrix of a graph.Graph.get_k_shortest_paths()
, thanks to @sombreslames. See PR #577 for details.setup.py
script now also accepts environment variables instead of command line arguments to configure several aspects of the build process (i.e. whether a fully static extension is being built, or whether it is allowed to use pkg-config
to retrieve the compiler and linker flags for an external igraph
library instead of the vendored one). The environment variables are named similarly to the command line arguments but in uppercase, dashes replaced with underscores, and they are prefixed with IGRAPH_
(i.e. --use-pkg-config
becomes IGRAPH_USE_PKG_CONFIG
).Graph.decompose()
that was accidentally introduced in 0.10.0 during the transition to igraph_graph_list_t
in the C core.Clustering.sizes()
now works correctly even if the membership vector contains None
items.Graph.modularity()
and Graph.community_multilevel()
now correctly expose the resolution
parameter.Graph.is_chordal()
that decreased the reference count of Python's built-in True
and False
constants unnecessarily.