Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

GPU programming on Clojure? [closed]

I'm wondering what if any GPU integration libraries exist for Clojure?

I've seen examples of this that involve hand-rolling OpenCL code, but I'm specifically I'm looking for something similar to Anacoda accelerate, which translates Numpy Python expressions to CUDA code relatively seamlessly.

I'm open to either OpenCL or Cuda approaches.

like image 809
Allyl Isocyanate Avatar asked Mar 10 '14 22:03

Allyl Isocyanate


3 Answers

here is a project that recently started on github https://github.com/JulesGosnell/clumatra. Its seems more like an experiment and its quite impressive!

like image 183
Shlomi Avatar answered Nov 02 '22 07:11

Shlomi


There is a Google Summer of Code project proposal to add a GPU matrix implementation to core.matrix:

  • http://dev.clojure.org/display/community/Project+Ideas

Once completed, this project would allow large vector/matrix expressions to be optimised and executed on GPUs.

Disclaimer: I'm a possible mentor for this project.

like image 3
mikera Avatar answered Nov 02 '22 08:11

mikera


clojureCL was released a few months after this question was posted. It looks like it offers a more idiomatic interpretation of the standard interface, but it is not a tool that would transform Clojure math / vector operations into OpenCL operations (I think that that is what the OP is looking for?)

[ClojureCL] brings a lot of power, but do not expect it to be an easy ride if you’ve never programmed anything on the GPU or embedded devices. With ClojureCL, it is not [as] difficult as in C (OpenCL Hello World in C is a hundred lines of source code, in ClojureCL it’s only a few), ...

The good news is that you can use any OpenCL book to learn ClojureCL, and we even provide ClojureCL code for the examples used in the OpenCL in Action book.

like image 2
Dan Ross Avatar answered Nov 02 '22 07:11

Dan Ross