Subject: [bug#69441] [PATCH] gnu: Add python-mord.

From: Ekaitz Zarraga <[email-masked]>
Date: Wed, 28 Feb 2024 14:38:35 +0100

LoL I forgot to attach.

On 2024-02-28 14:24, Ekaitz Zarraga wrote:
> I made a minor change and rebased to current `master`.

From ddba870c692e17ef25f98ce660072c67184d6e49 Mon Sep 17 00:00:00 2001
Message-ID: <[email-masked]>
From: Spencer King <[email-masked]>
Date: Tue, 27 Feb 2024 22:03:12 +0000
Subject: [PATCH] gnu: Add python-mord.

* gnu/packages/machine-learning.scm (python-mord): New variable.

Change-Id: I1a495fece72a0b998a69cb518544ed8835b12a40
---
 gnu/packages/machine-learning.scm | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 6e94e21f3e..e758132d31 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -26,6 +26,7 @@
 ;;; Copyright © 2024 Sharlatan Hellseher <[email-masked]>
 ;;; Copyright © 2024 David Pflug <[email-masked]>
 ;;; Copyright © 2024 Timothee Mathieu <[email-masked]>
+;;; Copyright © 2024 Spencer King <[email-masked]>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1782,6 +1783,29 @@ (define-public python-scikit-learn-extra
 citation number.")
       (license license:bsd-3))))
 
+(define-public python-mord
+  (package
+    (name "python-mord")
+    (version "0.7")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "mord" version))
+       (sha256
+        (base32 "1cvv9b9w69v0inq0zgcw0vmkiq3zn9q9r6clkynpzjik9rrh405n"))))
+    (build-system pyproject-build-system)
+    ;; v0.7 does not provide any test cases
+    ;; v0.6 relies on deprecated scikit-learn functionality
+    (arguments `(#:tests? #f))
+    (inputs (list python-numpy python-scipy python-scikit-learn))
+    (home-page "https://pypi.org/project/mord/")
+    (synopsis "Ordinal regression models for scikit-learn")
+    (description
+     "This package provides a collection of ordinal regression models for
+machine learning in Python.  They are intended to be used with scikit-learn
+and are compatible with its API.")
+    (license license:bsd-3)))
+
 (define-public python-thinc
   (package
     (name "python-thinc")

base-commit: f29f80c194d0c534a92354b2bc19022a9b70ecf8
-- 
2.41.0