transcranial / keras-js

Run Keras models in the browser, with GPU support using WebGL
https://transcranial.github.io/keras-js
MIT License
4.96k stars 501 forks source link

Implement training with keras.js? #73

Open Bondifrench opened 7 years ago

Bondifrench commented 7 years ago

Given that we know the derivatives for most activation functions, are you planning to implement backpropagation for training the models and not just do inference?

I know Javascript doesn't have the speed of C++, but depending of the size of datasets, Javascript performance can be quite good compared to Python.

dsanders11 commented 7 years ago

Seconded. I've got a project that was implemented with convnetjs because it needed to be run in a browser. It was trained on generated images for training data because no real-world data existed yet. The other benefit to in-browser training is that browsers are great at generating and rendering SVGs programmatically, which makes for a very convenient way to generate training data.

Unfortunately convnetjs is showing its age (no longer maintained) and doesn't have support for more recent developments in neural networks like ELU activation or BatchNormalization. Would be great to be able to switch to kera.js if the training capability was there.

vinthony commented 7 years ago

I think web browser DO NOT have the ability to training the large datasets and model in one web session by the limiting of memory. convjs is great but often dump in demos when the task is small (just a few layers). Python is good because the backend (matrix computation and etc..) is based on CUDA.

velociwabbit commented 6 years ago

I am trying to figure out how to train a model using keras.js are there any examples? They can be server side using node...

I have a distributed app that will have many people providing feedback so that the data can be continually trained. I am hoping that I can use keras.js for not just the finished models but also for the localized and global training components

Ideally a verb like train instead of predict could be implemented.