diff options
Diffstat (limited to 'gnu/packages/python-science.scm')
-rw-r--r-- | gnu/packages/python-science.scm | 183 |
1 files changed, 179 insertions, 4 deletions
diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm index d85b7267da..c514e0ab46 100644 --- a/gnu/packages/python-science.scm +++ b/gnu/packages/python-science.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2015, 2016, 2018, 2020-2025 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch> ;;; Copyright © 2016 Ben Woodcroft <donttrustben@gmail.com> -;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com> +;;; Copyright © 2016,2024 Hartmut Goebel <h.goebel@crazy-compilers.com> ;;; Copyright © 2016, 2021-2025 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016-2020, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr> @@ -37,6 +37,7 @@ ;;; Copyright © 2025 Nguyễn Gia Phong <mcsinyx@disroot.org> ;;; Copyright © 2025 Jake Forster <jakecameron.forster@gmail.com> ;;; Copyright © 2025 Ghislain Vaillant <ghislain.vaillant@inria.fr> +;;; Copyright © 2025 Janneke Nieuwenhuizen <janneke@gnu.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -1336,6 +1337,28 @@ computing in Python. It extends both the @code{concurrent.futures} and numerical software for solving convex second-order cone programs (SOCPs).") (license license:gpl3))) +(define-public python-efficient-apriori + (package + (name "python-efficient-apriori") + (version "2.0.6") + (source + (origin + (method url-fetch) + (uri (pypi-uri "efficient_apriori" version)) + (sha256 + (base32 "0vmdp8qkir7jrmwgpzajssyxh6q78m0q16pr1v657vla9x5wxn2s")))) + (build-system pyproject-build-system) + (arguments + (list + #:test-flags + #~(list "--doctest-modules" "-vv" "efficient_apriori"))) + (native-inputs (list python-setuptools python-pytest)) + (home-page "https://github.com/tommyod/Efficient-Apriori") + (synopsis "An efficient Python implementation of the Apriori algorithm.") + (description "An efficient Python implementation of the Apriori algorithm, +which uncovers hidden structures in categorical data") + (license license:expat))) + (define-public python-fast-histogram (package (name "python-fast-histogram") @@ -2929,6 +2952,11 @@ logic, also known as grey logic.") '(list "--pyargs" "skmisc") #:phases #~(modify-phases %standard-phases + (add-after 'unpack 'fix-pytest-config + (lambda _ + ;; Drop test coverage requirements. + (substitute* "pyproject.toml" + (("--cov(-[^ ]*)?=[^ ]*") "")))) (add-after 'unpack 'fix-version (lambda _ (call-with-output-file "skmisc/_version.py" @@ -2944,15 +2972,13 @@ logic, also known as grey logic.") (propagated-inputs (list meson-python python-numpy python-numpydoc - python-spin - python-twine)) + python-spin)) (native-inputs (list gfortran pkg-config python-cython-3 python-meson-python python-numpy python-pytest - python-pytest-cov python-setuptools python-wheel)) (home-page "https://has2k1.github.io/scikit-misc/stable") @@ -3409,6 +3435,66 @@ its software deployment plugins.") Snakemake and its storage plugins.") (license license:expat))) +(define-public python-snakemake-executor-plugin-slurm-jobstep + (package + (name "python-snakemake-executor-plugin-slurm-jobstep") + (version "0.3.0") + (home-page "https://github.com/snakemake/snakemake-executor-plugin-slurm-jobstep") + (source + (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0ly15ywmbfcm5z7jy7dxiidpw3immsdd2k80vrm4pza721irxcar")))) + (build-system pyproject-build-system) + (arguments + (list #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "python3" "tests/tests.py"))))))) + (native-inputs (list python-poetry-core + snakemake)) + (synopsis "Snakemake executor plugin: slurm-jobstep") + (description "A Snakemake executor plugin for running srun jobs inside of +SLURM jobs (meant for internal use by python-snakemake-executor-plugin-slurm).") + (license license:expat))) + +(define-public python-snakemake-executor-plugin-slurm + (package + (name "python-snakemake-executor-plugin-slurm") + (version "1.7.0") + (home-page "https://github.com/snakemake/snakemake-executor-plugin-slurm/") + (source + (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0x7ghrkvmxqbcjl69hxp5axa1av3s0mdc0i9xjg8qjnd3hgd82r3")))) + (build-system pyproject-build-system) + (arguments + (list #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "python3" "tests/tests.py"))))))) + (native-inputs (list python-pandas + python-poetry-core + python-pytest + python-snakemake-executor-plugin-slurm-jobstep + snakemake)) + (synopsis "Snakemake executor plugin: slurm") + (description "A Snakemake executor plugin for running SLURM jobs.") + (license license:expat))) + (define-public python-sparse (package (name "python-sparse") @@ -5689,6 +5775,95 @@ well as key metadata and SIRENE database containing data on all French compagnies.") (license license:expat))) +(define-public python-dvc-objects + (package + (name "python-dvc-objects") + (version "5.1.1") + (home-page "https://github.com/iterative/dvc-objects") + (source + (origin + (method url-fetch) + (uri (pypi-uri "dvc_objects" version)) + (sha256 + (base32 "1amx5z8k2v2hbsajg0dcd5dxmmlv9bnbchpas95s8sj86cm8yc4y")))) + (build-system pyproject-build-system) + (propagated-inputs (list python-fsspec + python-funcy-1.14)) + (native-inputs + (list python-mypy + python-pytest + python-pytest-asyncio + python-pytest-benchmark + python-pytest-cov + python-pytest-mock + python-pytest-sugar + python-reflink + python-setuptools + python-setuptools-scm + python-wheel)) + (synopsis "Filesystem and object-db level abstractions for DVC") + (description "Dvc objects provides a filesystem and object-db level +abstractions to use in dvc and dvc-data.") + (license license:asl2.0))) + +(define-public python-dvc-data + (package + (name "python-dvc-data") + (version "3.16.12") + (home-page "https://github.com/iterative/dvc-data") + (source (origin + (method url-fetch) + (uri (pypi-uri "dvc_data" version)) + (sha256 + (base32 + "156iwdn7v5jhwbpwz92n28qiasgcbmcqv9vxg8xbvdfxzlzw0b7r")))) + (build-system pyproject-build-system) + (propagated-inputs + (list python-attrs + python-dictdiffer + python-diskcache + python-dvc-objects + python-fsspec + python-funcy-1.14 + python-orjson + python-pygtrie + python-sqltrie + python-tqdm)) + (native-inputs + (list python-click + python-pytest + python-pytest-benchmark + python-pytest-cov + python-pytest-mock + ;; python-pytest-servers is not packaged in Guix yet + python-setuptools + python-setuptools-scm + python-typer + python-wheel)) + (arguments + (list + #:test-flags + ;; TODO: package python-pytest-server with its transitive dependencies + #~(list "--ignore=tests/hashfile/test_db.py" + "--ignore=tests/hashfile/test_db_index.py" + "--ignore=tests/hashfile/test_obj.py" + "--ignore=tests/index/test_build.py" + "--ignore=tests/index/test_checkout.py" + "--ignore=tests/index/test_fs.py" + "--ignore=tests/index/test_index.py" + "--ignore=tests/index/test_storage.py") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-pyproject + (lambda _ + ;; setuptools cannot handle both license and license-files + (substitute* "pyproject.toml" + (("^license = .*") "license = {text = \"Apache-2.0\"}\n") + (("^license-files = .*") ""))))))) + (synopsis "DVC's data management subsystem") + (description "Dvc data is DVC's data management subsystem.") + (license license:asl2.0))) + (define-public python-pyqtgraph (package (name "python-pyqtgraph") |