unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Vinicius Monego <monego@posteo.net>
To: 50956@debbugs.gnu.org
Cc: Vinicius Monego <monego@posteo.net>
Subject: [bug#50956] [PATCH 2/3] gnu: Add python-skorch.
Date: Sat,  2 Oct 2021 03:41:16 +0000	[thread overview]
Message-ID: <20211002034117.64876-2-monego@posteo.net> (raw)
In-Reply-To: <20211002034117.64876-1-monego@posteo.net>

* gnu/packages/machine-learning.scm (python-skorch): New variable.
---
 gnu/packages/machine-learning.scm | 42 +++++++++++++++++++++++++++++++
 1 file changed, 42 insertions(+)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 281c88d6f8..fd3e6b2090 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -1050,6 +1050,48 @@ number of threads used in the threadpool-backed of common native libraries used
 for scientific computing and data science (e.g. BLAS and OpenMP).")
     (license license:bsd-3)))
 
+(define-public python-skorch
+  (package
+    (name "python-skorch")
+    (version "0.10.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "skorch" version))
+       (sha256
+        (base32 "196hr0q5nw1nzckwanfv27myasayfdxxhx80iv9whm7675rzj44r"))))
+    (build-system python-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (replace 'check
+           (lambda* (#:key inputs outputs tests? #:allow-other-keys)
+             (when tests?
+               (add-installed-pythonpath inputs outputs)
+               (invoke "python" "-m" "pytest" "--pyargs" "skorch" "-k"
+                       (string-append
+                        ;; Errors because of missing weight and pickle files.
+                        "not test_load_cuda_params_to_cpu"
+                        " and not test_pickle_load"))))))))
+    (propagated-inputs
+     `(("python-numpy" ,python-numpy)
+       ("python-scikit-learn" ,python-scikit-learn)
+       ("python-scipy" ,python-scipy)
+       ("python-tabulate" ,python-tabulate)
+       ("python-tqdm" ,python-tqdm)))
+    (native-inputs
+     `(("python-flaky" ,python-flaky)
+       ("python-pandas" ,python-pandas)
+       ("python-pytest" ,python-pytest)
+       ("python-pytest-cov" ,python-pytest-cov)
+       ("python-pytorch" ,python-pytorch)))
+    (home-page "https://github.com/skorch-dev/skorch")
+    (synopsis "Scikit-learn compatible neural network library for PyTorch")
+    (description "Skorch is a scikit-learn compatible neural network library
+that wraps PyTorch.  It allows to build and train PyTorch models using a
+scikit-learn-like API.")
+    (license license:bsd-3)))
+
 (define-public python-pynndescent
   (package
     (name "python-pynndescent")
-- 
2.30.2





  reply	other threads:[~2021-10-02  3:44 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-02  3:39 [bug#50956] [PATCH 0/3] Add Optuna Vinicius Monego
2021-10-02  3:41 ` [bug#50956] [PATCH 1/3] gnu: Add python-cma Vinicius Monego
2021-10-02  3:41   ` Vinicius Monego [this message]
2021-10-02  3:41   ` [bug#50956] [PATCH 3/3] gnu: Add python-optuna Vinicius Monego
2021-10-13  2:00 ` [bug#50956] [PATCH v2 1/4] gnu: Add python-scikit-optimize Vinicius Monego
2021-10-13  2:00   ` [bug#50956] [PATCH v2 2/4] gnu: Add python-cma Vinicius Monego
2021-10-13  2:00   ` [bug#50956] [PATCH v2 3/4] gnu: Add python-skorch Vinicius Monego
2021-10-13  2:00   ` [bug#50956] [PATCH v2 4/4] gnu: Add python-optuna Vinicius Monego

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20211002034117.64876-2-monego@posteo.net \
    --to=monego@posteo.net \
    --cc=50956@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).