summary refs log tree commit diff
path: root/gnu/packages
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2022-01-31 16:06:39 +0100
committerRicardo Wurmus <rekado@elephly.net>2022-01-31 16:07:40 +0100
commit7fc8a6faf6269fd6417e3ed4794504f66899432b (patch)
tree6ae035ea7609098eeeb87c63b25000463d4e6a6e /gnu/packages
parent9686c828ed330a23357a8fd53e62ef9cdb7288ef (diff)
downloadguix-7fc8a6faf6269fd6417e3ed4794504f66899432b.tar.gz
gnu: Add scvelo.
* gnu/packages/bioinformatics.scm (scvelo): New variable.
Diffstat (limited to 'gnu/packages')
-rw-r--r--gnu/packages/bioinformatics.scm63
1 files changed, 63 insertions, 0 deletions
diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index 9eefc64184..92a299634f 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -15582,6 +15582,69 @@ aligner.")
     ;; bwa itself is licenced under GNU General Public License v3.0.
     (license license:mpl2.0)))
 
+(define-public scvelo
+  (package
+    (name "scvelo")
+    (version "0.2.4")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "scvelo" version))
+       (sha256
+        (base32 "0h5ha1459ljs0qgpnlfsw592i8dxqn6p9bl08l1ikpwk36baxb7z"))))
+    (build-system python-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         ;; Numba needs a writable dir to cache functions.
+         (add-before 'check 'set-numba-cache-dir
+           (lambda _
+             (setenv "NUMBA_CACHE_DIR" "/tmp")))
+         (replace 'check
+           (lambda* (#:key outputs tests? #:allow-other-keys)
+             (when tests?
+               ;; The discovered test file names must match the names of the
+               ;; compiled files, so we cannot run the tests from
+               ;; /tmp/guix-build-*.
+               (with-directory-excursion
+                   (string-append (assoc-ref outputs "out")
+                                  "/lib/python3.9/site-packages/scvelo/core/tests/")
+                 (invoke "pytest" "-v"))))))))
+    (propagated-inputs
+     (list python-anndata
+           python-hnswlib
+           python-isort
+           python-igraph
+           python-loompy
+           python-louvain
+           python-matplotlib
+           python-numba
+           python-numpy
+           python-pandas
+           python-scanpy
+           python-scikit-learn
+           python-scipy
+           python-umap-learn
+           pybind11))
+    (native-inputs
+     (list python-black
+           python-flake8
+           python-hypothesis
+           python-pre-commit
+           python-pytest
+           python-setuptools-scm
+           python-wheel))
+    (home-page "https://scvelo.org")
+    (synopsis "RNA velocity generalized through dynamical modeling")
+    (description "ScVelo is a scalable toolkit for RNA velocity analysis in
+single cells.  RNA velocity enables the recovery of directed dynamic
+information by leveraging splicing kinetics. scVelo generalizes the concept of
+RNA velocity by relaxing previously made assumptions with a stochastic and a
+dynamical model that solves the full transcriptional dynamics.  It thereby
+adapts RNA velocity to widely varying specifications such as non-stationary
+populations.")
+    (license license:bsd-3)))
+
 (define-public scregseg
   (package
     (name "scregseg")