Closed fayeshine closed 3 years ago
+1
I think MXNet and CNTK would be the interesting ones to have. You guys want to work on that?
Consider also using neon backend: https://github.com/NervanaSystems/neon It actually seems quite nice, compilation is lazy (no need to wait for graph to compile) and documentation at least so far seems to be quite decent. As a bonus it seems like this backend is the fastest so far at least with popular CV deep nets :D Here is a minimal example of neon that demonstrates some of its features:
from neon.backends import gen_backend, Autodiff
import numpy as np
# decide where to run (gpu/cpu)
be = gen_backend('cpu')
# create variables
x0, x1 = be.empty((2,2)), be.empty((2,2))
# construct computational graph
f = x0 * x0 + x0 * x1
# initialize variables
x0[:] = np.random.rand(2,2);
x1[:] = 0.0;
# return result as np array (could return variable of course)
print f.asnumpyarray()
# do autodifferentiation
ad = Autodiff(op_tree=f, be=be, next_error=None)
# compute the gradient w.r.t. some variables
print ad.get_grad_asnumpyarray([x0, x1])
Yeah, at least with neon backend I could try contributing, I am not sure however how soon that would happen. Lets say if no one else does it I do it (if neon backend is interesting), but I cannot promise anything w.r.t. time as I am already busy with all kinds of exciting things :D
I am not familiar with MXNet and CNTK though
Just looked for examples of CNTK usage in python, google did not reveal any so far. What Microsoft say is that python CNTK will be available in future releases. Thus it seems that it makes sense to consider MXNet only for extra backend as of now.
CNTK isn't available in python yet They probably will later this year
What would be more interesting would be to see if the new cuDNN RNN implementation can be ported into theano/tf and keras
@fchollet : from other issues it seems that neon backend is actually interesting. Do you know if someone is already working on it and if there are already any results?
Doesn't neon support GPU only in payed licenses?
Neon supports GPU in free license. Only supports multi-GPU in paid.
Ah, you are right - it was multi-gpu :)
I'll take a look at MXNet
We can and want to wrap the rnn implementation from cudnn. But we don't know when it will be done. Le 18 avr. 2016 05:28, "lemuriandezapada" notifications@github.com a écrit :
CNTK isn't available in python yet They probably will later this year
What would be more interesting would be to see if the new cuDNN RNN implementation can be ported into theano/tf and keras
— You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub https://github.com/fchollet/keras/issues/2370#issuecomment-211293802
Cross-referencing... CNTK backend. https://github.com/Microsoft/CNTK/issues/797
@fchollet More backend would be awesome. Do you have an estimated timeline when would the CNTK and MXNet be added into the keras backend? Thank you.
Hi! Curious as to whether anyone has followed up on integrating CNTK/other backends with Keras.
There's now a CNTK backend
My company Vertex.AI uses Keras internally for model development and we are actively working on OpenCL support: http://vertex.ai/blog/bringing-deep-learning-to-opencl
Is there such a thing as a "how to integrate a backend" document? Or a way to translate models / data from an "arbitrary" deep learning library into TensorFlow or CNTK? I'm thinking mostly about caffe
for now, but there are others out there.
We've just open sourced PlaidML which includes a new Keras backend with OpenCL support: http://vertex.ai/blog/announcing-plaidml
@fchollet Now that our source is open we'll see what we can do to make our integration with Keras cleaner.
@choongng I'm planning to test this over the weekend.
It would be nice to have an extension mechanism in keras that doesn't involve monkey patching (which is what @choongng and the rest of the Vertex.AI folks are doing) or submitting a pull request upstream. pytest and other projects support plugins via setuptools entry_points. Right now PlaidML monkey patching does not work in Python 3 so it would be nice to have a cleaner method. What do others think?
Tracking ticket for Keras2-MXNet backend https://github.com/keras-team/keras/issues/8697
could we support or do we plan to support more backends? Theano can only support multiple GPU using OpenCL but not CUDA, tensorflow seems slower than other framework using GPU for now.
Could we support Caffe, Leaf, MXNET, CNTK or Torch7?