From: Foo Chuan Wei <chuanwei.foo@hotmail.com>
To: 51072@debbugs.gnu.org
Subject: [bug#51072] [PATCH] gnu: Add Weka
Date: Thu, 7 Oct 2021 08:42:10 +0000 [thread overview]
Message-ID: <PU1PR01MB2155201726E55A5FC0EE82DF8DB19@PU1PR01MB2155.apcprd01.prod.exchangelabs.com> (raw)
* gnu/packages/machine-learning.scm (weka): New public variable.
---
gnu/packages/machine-learning.scm | 40 +++++++++++++++++++++++++++++++
1 file changed, 40 insertions(+)
diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 029422677a..98412894b0 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -40,6 +40,7 @@
#:use-module (guix download)
#:use-module (guix svn-download)
#:use-module (guix build-system cmake)
+ #:use-module (guix build-system copy)
#:use-module (guix build-system gnu)
#:use-module (guix build-system ocaml)
#:use-module (guix build-system python)
@@ -65,6 +66,7 @@
#:use-module (gnu packages graphviz)
#:use-module (gnu packages gstreamer)
#:use-module (gnu packages image)
+ #:use-module (gnu packages java)
#:use-module (gnu packages libffi)
#:use-module (gnu packages linux)
#:use-module (gnu packages llvm)
@@ -2934,3 +2936,41 @@ Note: currently this package does not provide GPU support.")
"Hmmlearn is a set of algorithms for unsupervised learning and inference
of Hidden Markov Models.")
(license license:bsd-3)))
+
+(define-public weka
+ (package
+ (name "weka")
+ (version "3.9.5")
+ (source (origin
+ (method url-fetch)
+ (uri "mirror://sourceforge/weka/weka-3-9/3.9.5/weka-3-9-5.zip")
+ (sha256
+ (base32
+ "0scnqk4zysdp9hv7w2rgz3pwkqirszj8pfv94drkhlnyc9cz9kf6"))))
+ (build-system copy-build-system)
+ (native-inputs `(("unzip" ,unzip)))
+ (inputs `(("jre" ,icedtea)))
+ (arguments '(#:install-plan '(("." "share/weka/"))
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'install 'make-wrapper
+ (lambda* (#:key inputs outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (wrapper (string-append out "/bin/weka")))
+ (mkdir-p (string-append out "/bin"))
+ (with-output-to-file wrapper
+ (lambda _
+ (display
+ (string-append
+ "#!/bin/sh\n\n"
+ (assoc-ref inputs "jre") "/bin/java -jar "
+ out "/share/weka/weka.jar \"$@\"\n"))))
+ (chmod wrapper #o555))
+ #t)))))
+ (synopsis "Machine learning algorithms for data mining tasks")
+ (description
+ "Weka is a collection of machine learning algorithms in Java.
+It contains tools for data preparation, classification, regression,
+clustering, association rules mining, and visualization.")
+ (home-page "https://www.cs.waikato.ac.nz/ml/weka/")
+ (license license:gpl3+)))
base-commit: ce83883f3d8bf6e6d25091acd018a8236a5754e1
--
2.25.1
next reply other threads:[~2021-10-07 9:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-07 8:42 Foo Chuan Wei [this message]
2022-10-30 15:34 ` [bug#51072] [PATCH] gnu: Add Weka Maxime Devos
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=PU1PR01MB2155201726E55A5FC0EE82DF8DB19@PU1PR01MB2155.apcprd01.prod.exchangelabs.com \
--to=chuanwei.foo@hotmail.com \
--cc=51072@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 external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.