-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BIDMat as sbt libraryDependencies #29
Comments
Bump -- this is a problem for adoption. |
There's a lot of work to make that work. We need to host BIDMat/BIDMach in a repo with all its native code dependencies compiled for each platform, which isnt too hard because we know how to build it. But we also need to get all of BIDMat's dependencies (and their native code) reliably hosted as well. That's the rubbing point. We know this is important, we're just trying to budget our resources wisely on all of our priorities. |
Thank you for a response! Have you ruled out bintray? I hear it's a bit easier to put stuff there than in Sonatype. |
Its not so much a problem to push a jar to sonatype. We need a mavenized jcuda for 0.7.0a which wasnt there until recently. I see its there now so it would be a good time to do this... |
Any update regarding this issue? In between, are there any documents on how to manually include BIDMat and/or BIDMach (along with its/their dependency) as libraries in a sbt project? |
@tangyuq Do you mean how to include the libraries of BIDMach/BIDMat? You can do this by writing "import BIDMach._" and "import BIDMach.dependencies" (the same for BIDMat), and then in the root folder directory type in "./sbt package". Then it should be OK. Hope it helps. |
I have my own sbt project, say under the folder MyPractice.
name := "MyPractice" version := "0.1" scalaVersion := "2.11.8" //scalaVersion := "2.10.3" //for some reason 2.10.3 will report missing dependency on cuda libraries as I am using CPU only version resolvers += "Typesafe Repo" at "http://repo.typesafe.com/typesafe/releases/" //...other dependency
object BasicBIDMat {
error java.lang.UnsatisfiedLinkError: edu.berkeley.bid.CBLAS.sgemm(IIIIIIF[FI[FIF[FI)V Am I missing anything? Running the same two lines from ./bidmat, there are no errors. I've copied the whole bidmat script to my project to start sbt (only replace the last step with sbt) to set up the same environment as bidmat hoping that this can resolve the linking errors. It would nice if there is an explicit list of setting to make this work. For example,
ps. If this post contains too much information, please feel free to delete it. |
After some struggle, I resolved the issue by adding the following two lines for initialization before calling any major BIDMat operations: It would nice to document these steps to include BIDMat as dependency in a standalone project ( it is possible that I might have missed such document somewhere). |
Before the official public package of BIDMat becomes available, in case it is useful for others, here is my little note on how to manually include BIDMat as dependency in a stand-alone sbt project (e.g. $YourProject) in the Linux environment:
|
We now have support for BIDMat/BIDMach as maven dependencies. That's designed to make it easy to build with Apache Spark. sbt doesnt pick up the dependency correctly however. If you have any idea how to fix this please let us know. An sbt dependency of: Will correctly find the BIDMat pom, but when it looks for the BIDMat jar it incorrectly resolves it to: But our maven repository is set up with this path: And if we change the artifact id to "BIDMat_2.11", we get the still-mismatched jar path: There may be some way to make both maven and sbt happy with some overrides in the maven directory hierarchy, but for now only maven is working. |
Another problem is that bintray recently (starting on 8/15/2016) to reject maven artifacts with underscores "_" in the path names. So there is no way to deploy and artifact with BIDMat_2.11 in the path name. |
From my experiments it seems like it is because Organization name is the same as Module name. If I'd manualy replace
with
the link resolves correctly without 2_11 in it. Perhaps you could change your organization name? |
sbt is the default way for dependency management in scala, even though BIDMat uses sbt itself it seems not to be possible to have BIDMat as an sbt reference.
Expected behaviour
libraryDependencies += "edu.berkeley.bid" %% "BIDMat" % "1.0.2"
is not working.The text was updated successfully, but these errors were encountered: