NetworkX 3.6
networkx 3.6
We're happy to announce the release of networkx 3.6!
New Features
- ENH: add normalize option for
subgraph_centralityand its_expversion (#8340).
API Changes
- Replace
random_lobsterwithrandom_lobster_graph(#8067). - Replace
maybe_regular_expanderwithmaybe_regular_expander_graph(#8050). - Rm networkx.algorithms.threshold.swap_d (#8213).
- Expire deprecation of compute_v_structures (#8281).
- Rm unused dissuade_hubs kwarg from forceatlas2 (#8293).
- Expire deprecation of link kwarg in node_link fns (#8282).
- DEP: Deprecate metric_closure (#8304).
Enhancements
- Improve error message for removed
random_treefunction (#8105). - Update approx current_flow betweenness to use k directly (#8007).
- Proposal: update semantics for nonisomorphic trees with order 0 or 1 (#8083).
- SCC benchmarks and use of
G._adjin Tarjan algorithm (#8064). - Performance improvement and tests for
edges_equal(#8077). - optimise
is_reachable()(#8112). - Optimise harmonic centrality (#8158).
- feat(drawing): add missing connection styles in
draw_networkx_edge_labelsanddisplay(#8108). - Optimizing Dijkstra's paths to target (~50x faster for graphs with multiple-hops shortest path) (#8023).
- Add
all_trianglesgenerator yielding all unique triangles in a graph (#8135). - refactor: simplify
k_factor(#8139). - feat: add directed star graph (#8151).
- Faster
intersection_arraycomputation for checking distance-regularity (#7181). - enh: short-circuit in
is_regularfor directed graphs (#8138). - Avoid re-exploring nodes in Kosaraju's SCC algorithm (#8056).
- trust rank implementation and testing (#8165).
- Add hyper_wiener_index function (#8184).
- Bidirectional dijkstra optimization: from 1.1x to 25x faster (#8206).
- Implement the algorithm to find the centroid(s) of a tree (#8089).
- Set length threshold in FR and use np.clip (#8145).
- Add panther++ (#4400).
- maint: use
nx.circulant_graphto generate Harary graphs (#8189). - ENH: add
directedkwarg toedges_equal(#8192). - Optimizing Dijkstra's path construction for all targets case (#8218).
- ENH: adds ISMAGS support for directed and multigraph with tests and refactor (#8274).
- Dispatch classes such as
nx.Graph(backend=...)(#7760). - ENH: Add is_perfect_graph using SPGT (follow-up to #8111) (#8318).
- Add benchmark suite for shortest path algorithms on weighted graphs (#8059).
- Adding Generalized Petersen Graph (#8147).
- ENH: add normalize option for
subgraph_centralityand its_expversion (#8340). - FEAT: Add a describe method for some basic info about graphs (#8338).
Bug Fixes
- Add Python 3.14 to testing matrix (#8096).
- Fix round-trip to and from pygraphviz.AGraph setting spurious graph attributes (#8121).
- Add input validation to
non_randomness()and clarify its behavior (#8057). - Ensure that backend names are valid Python identifiers (#8160).
- fix: resolve failure to pickle.loads(pickle.dumps(PlanarEmbedding())) (#8186).
- Add GEXF 1.3 to the recognized GEXF versions (#8196).
- BUG: Raise on directed graphs in
nx.find_cliques_recursive(#8211). - fix
optimize_edit_pathshandling of self-loops (#8207). - BUG: add check for isolated nodes in
degree_sequence_tree(#8235). - Mehlorn Steiner Tree (#8052).
- BUG/MAINT: fix edge betweenness centrality scaling when
k<Nand merge all b.c. rescale helper functions (#8256). - Fix node attributes on lattice graphs (#8311).
- BUG: allow graphs with nonstandard node labels in FISTA (#8332).
- Make dominance functions consistent with definitions (#8061).
- Pin last value to 1.0 in
cumulative_distributionto address floating-point errors (#8342).
Documentation
- Fix
min_weight_matching(#8062). - Update deploy-docs yml to use Python 3.12 when deploying the docs (#8102).
- DOC: Add missing params to bfs_layout docstring (#8086).
- Add input validation to
non_randomness()and clarify its behavior (#8057). - doc: improve docstring for hypercube_graph (#8012).
- Improved documentation for boundary_expansion function (#7905).
- DOC: Add docstring example count number of unique triangles (#8144).
- Add function bfs_labeled_edges to docs (#8149).
- Fix issues with urls in HITS reference docs (#8156).
- Correct the docs for
display()keywordnode_pos(#8153). - Adding Notes on Multi-Target Shortest Path Queries (#8169).
- 3d facebook plot example (#6893).
- trust rank implementation and testing (#8165).
- Improve docs for
all_neighbors()(#8166). - Adding shortest-paths documentation (#8187).
- Add Linux Foundation health score badge to README (#8219).
- DOC: Add docstring for
number_of_cliques(#8216). - DOC: add docstring for
degree_sequence_tree(#8236). - DOC: Add examples to contracted_nodes (#7856).
- DOC: fix wrong reference in
leidendocs (#8277). - Fix over-indentation of list in chordless_cycles docstring (#8288).
- Add iplotx to network drawing documentation (#8289).
- Fix sphinx build errors (#8303).
- DOC: Move deprecation procedure from contributing->dev guide (#8308).
- DOC: add gallery example for metric_closure (#8306).
- Cross-link Platonic graphs in See Also section (#8307).
- Add seealso crosslinks between lattice graphs (#8310).
- CI,DOC: Only run one parallel betweenness example (#8305).
- DOC: rework betweenness centrality docstrings (#8264).
- Rm 3D layout and animation from greedy_color example (#8315).
- DOC: Clarify node and edge removal behavior in tutorial (#8321).
- Improving connected module docs (#8267).
- Docs: add nx-neptune backend documentation (#8258).
- Improving shortest paths docs when there is no path between source and target (#8327).
- Adding floating point considerations to tutorial (#8324).
- Adding Dijkstra's algo specific doc (#8286).
- Minor documentation build improvements (#8329).
- Clarify the meaning of the cutoff parameter in some path-finding functions (#7487).
- Switch to the NumFOCUS Code of Conduct (#8320).
- Fix formatting for release docs (#8336).
- DOC: Add warning about special GEXF reserved keywords (#8343).
- Adding @amcandio as contributor (#8345).
- Fix sphinx warnings 3.6rc (#8352).
Maintenance
- Rm extraneous print from nx.display (#8084).
- Remove structuralholes.py from
needs_(num|sci)py(#8088). - Refactor image comparison tests (#8097).
- Update deploy-docs yml to use Python 3.12 when deploying the docs (#8102).
- Fix typo in extra name (#8103).
- MAINT: Support PEP 639 for license metadata (#8100).
- Use
scipy.sparsearray versions where applicable (#8080). - pass numpy seed by value not index (#8116).
- Maintenance for broadcasting.py (#8082).
- Bump the actions group across 1 directory with 6 updates (#8085).
- Revert dict comprehensions -> dict.fromkeys accidentally introduced in #8017 (#8018).
- refactor: improve
generate_adjlist(#8146). - MAINT: Weekly cron job to run dispatch test with an extensive matrix (#8154).
- Add benchmarks for multisrc_dijkstra over many small graphs (#8164).
- test: clean up
k_factortests (#8140). - Use
pytest.raisesas a context (#8170). - Testing sentinel-node trick (#8171).
- chore: make benchmarking and release requirements extras in
pyproject.toml(#8172). - Add benchmarks for is_regular (#8173).
- MAINT: use
matrix_powerfromscipy.sparseinnumber_of_walks(#8197). - MAINT: remove
try exceptfortomllibingenerate_requirements(#8198). - MAINT: Ignore graph hashing warnings in tests (#8205).
- STY: Variable rename proposal in bidirectional_dijkstra (#8210).
- MAINT: Rm print from threshold_graph (#8212).
- feat(api): update non-tree check in
_tree_centerand move totreesubpackage (#8174). - TST: add seed for
random_cographtest (#8228). - Update links for broken testing badge in README (#8234).
- Clarifying
@_dispatchable(name=(#8168). - MAINT/TST: increase non-
slowcoverage ink_components(#8239). - MAINT/TST: clean up tests for
degree_seq(#8257). - Use CircleCI for coverage workflow (#8178).
- Bump the actions group across 1 directory with 5 updates (#8261).
- BUG/MAINT: fix edge betweenness centrality scaling when
k<Nand merge all b.c. rescale helper functions (#8256). - DOC/MAINT: Use
itertools.pairwiseinpairwiseand add docstring (#8201). - Optimizing is_connected (#8266).
- Rm outdated codecov badge from README (#8272).
- CI: Move slow tests from coverage to dedicated run (#8273).
- Move coverage configuration to pyproject.toml (#8287).
- Making weakly connected logic consistent with connected logic (#8285).
- Bump scientific-python/circleci-artifacts-redirector-action from 1.2.0 to 1.3.1 in the actions group (#8309).
- CI: Add nicer rendering of env contents (#8301).
- CI: Install ffmpeg in circleci docs pipeline (#8291).
- Add/bump Python 3.14 to testing matrices (#8319).
- Rm 3D layout and animation from greedy_color example (#8315).
- MAINT: Remove unused sphinx extensions from conf.py (#8314).
- optimize _single_shortest_path function (#6337).
- Add autoflake and pyupgrade as manual pre-commit hooks (#7870).
- ignore autoflake and pyupgrade changes (#8333).
- Revert "ignore autoflake and pyupgrade changes" (#8334).
- Bump actions/upload-artifact from 4 to 5 in the actions group (#8335).
Other
- TST: improve coverage for
generators/deg_seq.py(#8226). - TST: test
max_iterinasyn_fluidc(#8224). - MAINT: clean up tests for
steiner_tree(#8259). - TST: add non-
slowcoverage for random graph generators (#8252). - TST: Add a nonslow test for
all_node_cutswith shortest augmenting path flow function (#8230). - TST/MAINT: add non-slow coverage for random generators (#8233).
- TST: add coverage for
isomorphvf2(#8251). - TST: ensure determinism in
nx_pylabdrawing tests (#8232). - TST: add
random_k_out_graphto tests to hittry exceptpath (#8231). - TST: add coverage for some branches in
internet_as_graphs.py(#8225). - TST: test
topo_sortskips visited nodes ingoldberg_radzik(#8279). - CI: Use tag protection rulesets to control releases (#8337).
Contributors
40 authors added to this release (alphabetically):
- @Aka2210
- @dean985
- @georako
- @georakom
- @ishrathtahaseen-9
- @rudyarthur
- @sourabh-sudesh-paradeshi
- Aditi Juneja (@Schefflera-Arboricola)
- Adriano Meligrana (@Tortar)
- akshita (@akshitasure12)
- Albert Koppelmaa (@albastardoto)
- Alejandro Candioti (@amcandio)
- Andrew Carbonetto (@acarbonetto)
- Anthony Labarre (@alabarre)
- Casper van Elteren (@cvanelteren)
- Colman Bouton (@LorentzFactor)
- Dan Schult (@dschult)
- dgpb (@dg-pb)
- Erik Welch (@eriknw)
- Fabio Zanini (@iosonofabio)
- Fei Pan (@fei0319)
- Florian2Richter (@Florian2Richter)
- Gilles Peiffer (@Peiffap)
- Gustavo Ataide (@gustavo-ataide)
- Hadrien Crassous (@Hadrien-Cr)
- Jarrod Millman (@jarrodmillman)
- Jeff Bradberry (@jbradberry)
- Jonathan Reimer (@jonathimer)
- Maninder Dhanauta (@Maninder-sd)
- Marcus Fedarko (@fedarko)
- Mauricio Souza de Alencar (@mdealencar)
- Michael Recachinas (@mrecachinas)
- Mridul Seth (@MridulS)
- Peter Cock (@peterjc)
- Ross Barnowski (@rossbar)
- Stefano Vallodoro (@ilvallod)
- Supreeth Mysore Venkatesh (@supreethmv)
- Till Hoffmann (@tillahoffmann)
- Yasser El Haddar (@YasserElHaddar16)
- Yasser El Haddar (@Yasserelhaddar)
24 reviewers added to this release (alphabetically):
- @Aka2210
- @dean985
- @georakom
- @ishrathtahaseen-9
- Aditi Juneja (@Schefflera-Arboricola)
- akshita (@akshitasure12)
- Alejandro Candioti (@amcandio)
- Anthony Labarre (@alabarre)
- Christian Clauss (@cclauss)
- Colman Bouton (@LorentzFactor)
- Dan Schult (@dschult)
- dgpb (@dg-pb)
- Erik Welch (@eriknw)
- Fei Pan (@fei0319)
- Gilles Peiffer (@Peiffap)
- Hiroki Hamaguchi (@HirokiHamaguchi)
- Jarrod Millman (@jarrodmillman)
- Jeff Bradberry (@jbradberry)
- Marcus Fedarko (@fedarko)
- Michael Recachinas (@mrecachinas)
- Mridul Seth (@MridulS)
- Ross Barnowski (@rossbar)
- Supreeth Mysore Venkatesh (@supreethmv)
- Yasser El Haddar (@YasserElHaddar16)
These lists are automatically generated, and may not be complete or may contain duplicates.