diff options
author | Sharlatan Hellseher <sharlatanus@gmail.com> | 2024-06-14 07:56:41 +0100 |
---|---|---|
committer | Sharlatan Hellseher <sharlatanus@gmail.com> | 2024-06-30 10:11:19 +0100 |
commit | 48e9b346db938fb3865e608bb5a8971a652e7475 (patch) | |
tree | 9292946eb92ba68df44ad5adcff319981c29b8e2 /gnu/packages/python-science.scm | |
parent | c8e4b2740bc1fb9f880ce80a2c7b28c75f1b5022 (diff) | |
download | guix-48e9b346db938fb3865e608bb5a8971a652e7475.tar.gz guix-48e9b346db938fb3865e608bb5a8971a652e7475.zip |
gnu: Add python-fast-histogram.
* gnu/packages/python-science.scm (python-fast-histogram): New variable.
Change-Id: Ibecdd87db9c132052a8eca76c01108c4f6e624c4
Diffstat (limited to 'gnu/packages/python-science.scm')
-rw-r--r-- | gnu/packages/python-science.scm | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm index 200d0d7fc3..57b852c2bd 100644 --- a/gnu/packages/python-science.scm +++ b/gnu/packages/python-science.scm @@ -1545,6 +1545,38 @@ region of practical equivalence (rope), or that the second classifier has higher scores.") (license license:expat))) +(define-public python-fast-histogram + (package + (name "python-fast-histogram") + (version "0.14") + (source + (origin + (method url-fetch) + (uri (pypi-uri "fast_histogram" version)) + (sha256 + (base32 "1sk9xa85cgm4sylzblwv3qr2dmm0ic06zkwxqa2xlazjiawp629r")))) + (build-system pyproject-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-before 'check 'build-extensions + (lambda _ + (invoke "python" "setup.py" "build_ext" "--inplace")))))) + (propagated-inputs (list python-numpy)) + (native-inputs (list python-hypothesis python-pytest)) + (home-page "https://github.com/astrofrog/fast-histogram") + (synopsis "Fast simple 1D and 2D histograms") + (description + "The fast-histogram mini-package aims to provide simple and fast +histogram functions for regular bins that don't compromise on performance. It +doesn't do anything complicated - it just implements a simple histogram +algorithm in C and keeps it simple. The aim is to have functions that are fast +but also robust and reliable. The result is a 1D histogram function here that +is 7-15x faster than @code{numpy.histogram}, and a 2D histogram function that +is 20-25x faster than @code{numpy.histogram2d}.") + (license license:bsd-3))) + (define-public python-fastcluster (package (name "python-fastcluster") |