From patchwork Mon Mar 21 17:39:42 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Aurora X-Patchwork-Id: 37982 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id E025227BBEA; Mon, 21 Mar 2022 17:48:12 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-3.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL, SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id ABFF827BBE9 for ; Mon, 21 Mar 2022 17:48:12 +0000 (GMT) Received: from localhost ([::1]:40324 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nWM8Z-0004AL-SQ for patchwork@mira.cbaines.net; Mon, 21 Mar 2022 13:48:11 -0400 Received: from eggs.gnu.org ([209.51.188.92]:51278) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nWM1f-00006P-6L for guix-patches@gnu.org; Mon, 21 Mar 2022 13:41:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:44222) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nWM1e-0005b2-JI for guix-patches@gnu.org; Mon, 21 Mar 2022 13:41:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nWM1e-0006Qq-Ff for guix-patches@gnu.org; Mon, 21 Mar 2022 13:41:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#54507] [PATCH 1/2] gnu: openfst: Add 1.7.3 for kaldi Resent-From: Aurora Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 21 Mar 2022 17:41:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 54507 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 54507@debbugs.gnu.org Cc: Aurora X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.164788441424655 (code B ref -1); Mon, 21 Mar 2022 17:41:02 +0000 Received: (at submit) by debbugs.gnu.org; 21 Mar 2022 17:40:14 +0000 Received: from localhost ([127.0.0.1]:38119 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nWM0s-0006Pb-4d for submit@debbugs.gnu.org; Mon, 21 Mar 2022 13:40:14 -0400 Received: from lists.gnu.org ([209.51.188.17]:40390) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nWM0q-0006PT-AG for submit@debbugs.gnu.org; Mon, 21 Mar 2022 13:40:12 -0400 Received: from eggs.gnu.org ([209.51.188.92]:51080) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nWM0o-00088i-2B for guix-patches@gnu.org; Mon, 21 Mar 2022 13:40:11 -0400 Received: from knopi.disroot.org ([178.21.23.139]:57346) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nWM0m-0005Qo-F3 for guix-patches@gnu.org; Mon, 21 Mar 2022 13:40:09 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id 51BEE40072; Mon, 21 Mar 2022 18:40:06 +0100 (CET) X-Virus-Scanned: SPAM Filter at disroot.org Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id EHyiYvK3Vz9T; Mon, 21 Mar 2022 18:40:05 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1647884404; bh=Hntxk3k1yCqF+WS5Dh4oaVoktJP9D7PE2uWokyqXc3E=; h=From:To:Cc:Subject:Date; b=iCJ49NyZmOOhJcCzpCfXP0TExS+rqiP8WvbduWFpTeqhq+hud1JM64iKLQMQVTXoD Mb/hI/f4/jryV2Tz+ybZYx+Jj66AhbMuFOz+J3wTftjulwPhamk/WSGwPdnxf44KGn mRpGQUoqON8NICCsLAUIKBKwi1+mPeCLq/d4Z5k20a5D6bXn/v3TDrgK4aEUPBJTNW wxAg8gBU0Rf1sfRpi2B2fAe5qaztUyNLaXKMu8f7gjkrsdhsJAF05Mdp+vnghN6X1L udVjxMHBrzcVvYjudNXt5mbzjrBq2M2yDJDYX4wbW1Fpreu2zTMfw14ETNrhBkQgic oJjtPcSTXfTSQ== Date: Mon, 21 Mar 2022 17:39:42 +0000 Message-Id: <20220321173942.2206-1-rind38@disroot.org> Mime-Version: 1.0 Received-SPF: pass client-ip=178.21.23.139; envelope-from=rind38@disroot.org; helo=knopi.disroot.org X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" Reply-to: Aurora X-ACL-Warn: , Aurora via Guix-patches X-Patchwork-Original-From: Aurora via Guix-patches via From: Aurora X-getmail-retrieved-from-mailbox: Patches Kaldi is currently broken with openfst versions newer than 1.7.3 as it changed some of its function signatures. Once Kaldi is patched/fixed, this should be removed. Reference Issues: - https://github.com/kaldi-asr/kaldi/issues/4131 - https://github.com/kaldi-asr/kaldi/issues/4393 --- gnu/packages/machine-learning.scm | 13 +++++++++++++ 1 file changed, 13 insertions(+) base-commit: a1632d59529909ab3733772f203e7ea64809b85e diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm index afac56f..ec70980 100644 --- a/gnu/packages/machine-learning.scm +++ b/gnu/packages/machine-learning.scm @@ -585,6 +585,19 @@ sample proximities between pairs of cases.") optimizing, and searching weighted finite-state transducers (FSTs).") (license license:asl2.0))) +;; This is a temporary addition to bypass upstream issues with the kaldi +;; package. +(define-public openfst-1.7.3 + (package (inherit openfst) + (version "1.7.3") + (source (origin + (method url-fetch) + (uri (string-append "http://www.openfst.org/twiki/pub/FST/" + "FstDownload/openfst-" version ".tar.gz")) + (sha256 + (base32 + "038a60w7y8qnbxmcrsim9rafz9mihsny8xv50jpzlr7rl166pp5q")))))) + (define-public shogun (package (name "shogun") From patchwork Mon Mar 21 17:42:49 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Aurora X-Patchwork-Id: 37983 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id CFA1B27BBEA; Mon, 21 Mar 2022 17:48:44 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-3.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL, SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 2FA7C27BBE9 for ; Mon, 21 Mar 2022 17:48:44 +0000 (GMT) Received: from localhost ([::1]:41062 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nWM95-0004hH-Am for patchwork@mira.cbaines.net; Mon, 21 Mar 2022 13:48:43 -0400 Received: from eggs.gnu.org ([209.51.188.92]:51982) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nWM4Y-0001PT-N5 for guix-patches@gnu.org; Mon, 21 Mar 2022 13:44:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:44238) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nWM4Y-0005xV-Ef for guix-patches@gnu.org; Mon, 21 Mar 2022 13:44:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nWM4Y-0006Wv-Cq for guix-patches@gnu.org; Mon, 21 Mar 2022 13:44:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#54507] [PATCH 2/2] gnu: kaldi: Update to 498b25d, add vector fix patch, bypass tests References: <20220321173942.2206-1-rind38@disroot.org> In-Reply-To: <20220321173942.2206-1-rind38@disroot.org> Resent-From: Aurora Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 21 Mar 2022 17:44:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 54507 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 54507@debbugs.gnu.org Cc: Aurora Received: via spool by 54507-submit@debbugs.gnu.org id=B54507.164788458524996 (code B ref 54507); Mon, 21 Mar 2022 17:44:02 +0000 Received: (at 54507) by debbugs.gnu.org; 21 Mar 2022 17:43:05 +0000 Received: from localhost ([127.0.0.1]:38129 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nWM3c-0006V5-Qf for submit@debbugs.gnu.org; Mon, 21 Mar 2022 13:43:05 -0400 Received: from knopi.disroot.org ([178.21.23.139]:43394) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nWM3X-0006US-C3 for 54507@debbugs.gnu.org; Mon, 21 Mar 2022 13:43:03 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id 7D0E8400BE; Mon, 21 Mar 2022 18:42:58 +0100 (CET) X-Virus-Scanned: SPAM Filter at disroot.org Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id RjZ2eMElPqqY; Mon, 21 Mar 2022 18:42:56 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1647884575; bh=mXcYEMgWwM+Y1jd2QJaxt4d0sLXiMW41idLMpIvR3E0=; h=From:To:Cc:Subject:Date; b=JMel0ChL2hUHpXTC3b5dhLVLoyTRU5ARKem39qNEhxYJL9y7yWaBjWy4LyG+NwaZO G2tdwsz2FrNJ0FUuMLi5ToeSX8UlSlERKvosof+Bpg5LLxz+ALUBFnmxvbkxd5PMcF shaA8q8It/kIFrrpGlBRalDAUC2dHWUwGlwzb1QX0j+wEZecB1t1Ms2G7LQzEc6sWR 22Z54x2auGfz6Sl+NK8bfgBxVLxKxTA8HB8oh3ZjCMSdDgdSM97tXKMpqJK0kmbpYl +weGf/4k5jRbjKmhb958EgvqWsk7fjyBB1YBZxIKRWepWQ78eIqyiUuRormEIncKVQ bmj33iKWb8yIA== Date: Mon, 21 Mar 2022 17:42:49 +0000 Message-Id: <20220321174249.2408-1-rind38@disroot.org> Mime-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" Reply-to: Aurora X-ACL-Warn: , Aurora via Guix-patches X-Patchwork-Original-From: Aurora via Guix-patches via From: Aurora X-getmail-retrieved-from-mailbox: Patches The patch is in the process of being upstreamed: https://github.com/kaldi-asr/kaldi/pull/4713 Either kaldi's tests are broken or openblas has reintroduced a bug: - https://github.com/kaldi-asr/kaldi/pull/4421 More testing & fixes required upstream. --- gnu/packages/machine-learning.scm | 10 ++- ...or-casts-by-using-explicit-namespace.patch | 89 +++++++++++++++++++ 2 files changed, 96 insertions(+), 3 deletions(-) create mode 100644 gnu/packages/patches/kaldi-Fix-vector-casts-by-using-explicit-namespace.patch diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm index ec70980..ba6a439 100644 --- a/gnu/packages/machine-learning.scm +++ b/gnu/packages/machine-learning.scm @@ -1549,8 +1549,9 @@ discrete, and conditional dimensions.") ;; There have been no proper releases yet. (define-public kaldi - (let ((commit "d4791c0f3fc1a09c042dac365e120899ee2ad21e") - (revision "2")) + (let ((commit "498b25db122ec68a96aee154b9d829030adfae4c") + (revision "1") + (openfst openfst-1.7.3)) ;; Temporary bypass for upstream issues (package (name "kaldi") (version (git-version "0" revision commit)) @@ -1562,7 +1563,8 @@ discrete, and conditional dimensions.") (file-name (git-file-name name version)) (sha256 (base32 - "07k80my6f19mhrkwbzhjsnpf9871wmrwkl0ym468i830w67qyjrz")))) + "06wapq8xkr2xwkj10z70w20437kqjkf6v705z68h78zrgrj9dzj9")) + (patches (search-patches "kaldi-Fix-vector-casts-by-using-explicit-namespace.patch")))) (build-system gnu-build-system) (arguments `(#:test-target "test" @@ -1586,6 +1588,8 @@ discrete, and conditional dimensions.") "gst-plugin/Makefile") (("../../tools/portaudio/install") (assoc-ref inputs "portaudio"))) + (substitute* "matrix/Makefile" ;; temporary test bypass + (("matrix-lib-test sparse-matrix-test") "")) ;; This `configure' script doesn't support variables passed as ;; arguments, nor does it support "prefix". diff --git a/gnu/packages/patches/kaldi-Fix-vector-casts-by-using-explicit-namespace.patch b/gnu/packages/patches/kaldi-Fix-vector-casts-by-using-explicit-namespace.patch new file mode 100644 index 0000000..5bae584 --- /dev/null +++ b/gnu/packages/patches/kaldi-Fix-vector-casts-by-using-explicit-namespace.patch @@ -0,0 +1,89 @@ +--- + src/onlinebin/online-audio-server-decode-faster.cc | 2 +- + src/onlinebin/online-gmm-decode-faster.cc | 4 ++-- + src/onlinebin/online-server-gmm-decode-faster.cc | 4 ++-- + src/onlinebin/online-wav-gmm-decode-faster.cc | 4 ++-- + 4 files changed, 7 insertions(+), 7 deletions(-) + +diff --git a/src/onlinebin/online-audio-server-decode-faster.cc b/src/onlinebin/online-audio-server-decode-faster.cc +index ca4bfeb88..e5faf9530 100644 +--- a/src/onlinebin/online-audio-server-decode-faster.cc ++++ b/src/onlinebin/online-audio-server-decode-faster.cc +@@ -308,7 +308,7 @@ int32 main(int argc, char *argv[]) { + } else { + std::vector word_ids; + if (decoder.PartialTraceback(&out_fst)) { +- GetLinearSymbolSequence(out_fst, static_cast *>(0), ++ GetLinearSymbolSequence(out_fst, static_cast *>(0), + &word_ids, + static_cast(0)); + for (size_t i = 0; i < word_ids.size(); i++) { +diff --git a/src/onlinebin/online-gmm-decode-faster.cc b/src/onlinebin/online-gmm-decode-faster.cc +index 46904dbc5..74f381658 100644 +--- a/src/onlinebin/online-gmm-decode-faster.cc ++++ b/src/onlinebin/online-gmm-decode-faster.cc +@@ -166,7 +166,7 @@ int main(int argc, char *argv[]) { + std::vector word_ids; + decoder.FinishTraceBack(&out_fst); + fst::GetLinearSymbolSequence(out_fst, +- static_cast *>(0), ++ static_cast *>(0), + &word_ids, + static_cast(0)); + PrintPartialResult(word_ids, word_syms, partial_res || word_ids.size()); +@@ -181,7 +181,7 @@ int main(int argc, char *argv[]) { + std::vector word_ids; + if (decoder.PartialTraceback(&out_fst)) { + fst::GetLinearSymbolSequence(out_fst, +- static_cast *>(0), ++ static_cast *>(0), + &word_ids, + static_cast(0)); + PrintPartialResult(word_ids, word_syms, false); +diff --git a/src/onlinebin/online-server-gmm-decode-faster.cc b/src/onlinebin/online-server-gmm-decode-faster.cc +index 80973bf07..9840c0f88 100644 +--- a/src/onlinebin/online-server-gmm-decode-faster.cc ++++ b/src/onlinebin/online-server-gmm-decode-faster.cc +@@ -179,7 +179,7 @@ int main(int argc, char *argv[]) { + if (dstate & (decoder.kEndFeats | decoder.kEndUtt)) { + decoder.FinishTraceBack(&out_fst); + fst::GetLinearSymbolSequence(out_fst, +- static_cast *>(0), ++ static_cast *>(0), + &word_ids, + static_cast(0)); + SendPartialResult(word_ids, word_syms, partial_res || word_ids.size(), +@@ -188,7 +188,7 @@ int main(int argc, char *argv[]) { + } else { + if (decoder.PartialTraceback(&out_fst)) { + fst::GetLinearSymbolSequence(out_fst, +- static_cast *>(0), ++ static_cast *>(0), + &word_ids, + static_cast(0)); + SendPartialResult(word_ids, word_syms, false, +diff --git a/src/onlinebin/online-wav-gmm-decode-faster.cc b/src/onlinebin/online-wav-gmm-decode-faster.cc +index fe7c6d6b9..ca482934d 100644 +--- a/src/onlinebin/online-wav-gmm-decode-faster.cc ++++ b/src/onlinebin/online-wav-gmm-decode-faster.cc +@@ -196,7 +196,7 @@ int main(int argc, char *argv[]) { + std::vector word_ids; + decoder.FinishTraceBack(&out_fst); + fst::GetLinearSymbolSequence(out_fst, +- static_cast *>(0), ++ static_cast *>(0), + &word_ids, + static_cast(0)); + PrintPartialResult(word_ids, word_syms, partial_res || word_ids.size()); +@@ -220,7 +220,7 @@ int main(int argc, char *argv[]) { + std::vector word_ids; + if (decoder.PartialTraceback(&out_fst)) { + fst::GetLinearSymbolSequence(out_fst, +- static_cast *>(0), ++ static_cast *>(0), + &word_ids, + static_cast(0)); + PrintPartialResult(word_ids, word_syms, false); +-- +2.30.2 +