You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
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?
The text was updated successfully, but these errors were encountered:
It would be useful interop! I'm not using apache commons matrix library myself, but happy to merge core.matrix PRs if needed to help make it work if anyone wants to try updating the implementation.
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 herehttps://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)
, butclojure.core.matrix.implementations/KNOWN-IMPLEMENTATIONS
has asits entry
:commons-math apache-commons-matrix.core
But
(m/set-current-implementation :commons-math)
throws adifferent error:
indeed, the referenced line uses what looks like a bad call to
clojure'
(throw)
:anyone trying to make this potentially useful interop work?
The text was updated successfully, but these errors were encountered: