我正在尝试使用 https://github.com/adereth/adereth/apache-commons-commons-matrix-matrix < /a> to
通过Maven Repo访问Apache Commons数学的功能
。
我的主要指南是马特·阿德雷斯(Matt Adereth)
http:http:// adereth .github.io/blog/2013/11/08/core-dot-matrix-plus-apache-commons-math/
,从2013年开始!惊喜,惊喜,似乎有一些代码
腐烂。
MVN存储
- 库中的代码缺少扩展名
(扩展协议MP/PMATRIXMULTIPLY)
github repo中存在
https://github.com/ Adereth/Apache-Commons-Matrix/blob/ef1e2bccbee7f8b8f59fbfdfe7639c239c23f6c406f/src/src/apache_commons_matrix/core.clj#l192 ??
-
Matt的指南建议使用(m/set-current-implentation:apache-commons)
,但
clojure.core.matrix.implementations/nowle-implementations
具有
它的条目:Commons-Math-Math apache-commons-matrix.core
-
但(m/set-current-implementation:commons-math)
抛出
不同的错误:
错误加载core.matrix实现:apache-commons-matrix.core
#错误 {
:导致太多的论点要投掷,投掷期望一个可投掷的实例
:通过
[{:类型clojure.lang.compiler $ compilerexception
:消息语法错误编译抛出(apache_commons_matrix/core.clj:19:13)。
:data#:clojure.error {:stape:compile-syntax-check,:line 19,:第13列,:source apache_commons_matrix/core.clj,:symbol throw}
:at [clojure.lang.compiler Analyzeseq compiler.java 7132]}
的确,引用的行使用看起来像是一个不好的电话
clojure'(throw)
:
(throw(ex-info“ apache commons数学矩阵仅支持多达2个维度”){:请求形状dims})
任何试图使这种潜在有用的Interop工作的人吗?
I'm trying to use https://github.com/adereth/apache-commons-matrix to
access the functionality of Apache Commons Math, via the Maven repo
https://mvnrepository.com/artifact/org.apache.commons/commons-math3 .
My main guide is Matt Adereth's
http://adereth.github.io/blog/2013/11/08/core-dot-matrix-plus-apache-commons-math/
, from 2013!? Surprise, surprise, there seems to have been some code
rot. Several issues in particular:
-
The code in the mvn repo is missing an extension (extend-protocol mp/PMatrixMultiply)
present in the github repo here
https://github.com/adereth/apache-commons-matrix/blob/ef1e2bccbee7f8b8f5d9fbfdfe7639c23f6c406f/src/apache_commons_matrix/core.clj#L192 ?
-
Matt's guide suggests using (m/set-current-implementation :apache-commons)
, but
clojure.core.matrix.implementations/KNOWN-IMPLEMENTATIONS
has as
its entry :commons-math apache-commons-matrix.core
-
But (m/set-current-implementation :commons-math)
throws a
different error:
Error loading core.matrix implementation: apache-commons-matrix.core
#error {
:cause Too many arguments to throw, throw expects a single Throwable instance
:via
[{:type clojure.lang.Compiler$CompilerException
:message Syntax error compiling throw at (apache_commons_matrix/core.clj:19:13).
:data #:clojure.error{:phase :compile-syntax-check, :line 19, :column 13, :source apache_commons_matrix/core.clj, :symbol throw}
:at [clojure.lang.Compiler analyzeSeq Compiler.java 7132]}
indeed, the referenced line uses what looks like a bad call to
clojure' (throw)
:
(throw (ex-info "Apache Commons Math matrices only supports up to 2 dimensions") {:requested-shape dims})
anyone trying to make this potentially useful interop work?
发布评论