aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRicardo Wurmus <ricardo.wurmus@mdc-berlin.de>2019-05-16 14:35:59 +0200
committerRicardo Wurmus <rekado@elephly.net>2019-05-16 16:07:06 +0200
commite865e0b959a91b72d4d9193110ee44e24e1929be (patch)
treef98cfd9d60bafdb744ffd80fef230662b62b8025
parentfbeb92d7607dc1dc6c3a34a536352636274a69de (diff)
downloadguix-e865e0b959a91b72d4d9193110ee44e24e1929be.tar
guix-e865e0b959a91b72d4d9193110ee44e24e1929be.tar.gz
gnu: Add python-leidenalg.
* gnu/packages/graph.scm (python-leidenalg): New variable.
-rw-r--r--gnu/packages/graph.scm31
1 files changed, 31 insertions, 0 deletions
diff --git a/gnu/packages/graph.scm b/gnu/packages/graph.scm
index 738ba6c455..36d0467175 100644
--- a/gnu/packages/graph.scm
+++ b/gnu/packages/graph.scm
@@ -415,3 +415,34 @@ CPUFLAGS = ~{~a ~}~%"
(description "Faiss is a library for efficient similarity search and
clustering of dense vectors. This package provides Python bindings to the
Faiss library.")))
+
+(define-public python-leidenalg
+ (package
+ (name "python-leidenalg")
+ (version "0.7.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (pypi-uri "leidenalg" version))
+ (sha256
+ (base32
+ "15fwld9hdw357rd026mzcwpah5liy4f33vc9x9kwy37g71b2rjf1"))))
+ (build-system python-build-system)
+ (arguments '(#:tests? #f)) ; tests are not included
+ (native-inputs
+ `(("pkg-config" ,pkg-config)))
+ (inputs
+ `(("igraph" ,igraph)))
+ (propagated-inputs
+ `(("python-igraph" ,python-igraph)))
+ (home-page "https://github.com/vtraag/leidenalg")
+ (synopsis "Community detection in large networks")
+ (description
+ "Leiden is a general algorithm for methods of community detection in
+large networks. This package implements the Leiden algorithm in C++ and
+exposes it to Python. Besides the relative flexibility of the implementation,
+it also scales well, and can be run on graphs of millions of nodes (as long as
+they can fit in memory). The core function is @code{find_partition} which
+finds the optimal partition using the Leiden algorithm, which is an extension
+of the Louvain algorithm, for a number of different methods.")
+ (license license:gpl3+)))