ConvnetJS demo: Image "Painting"

This demo that treats the pixels of an image as a learning problem: it takes the (x,y) position on a grid and learns to predict the color at that point using regression to (r,g,b). It's a bit like compression, since the image information is encoded in the weights of the network, but almost certainly not of practical kind :)

Note that the entire ConvNetJS definition is shown in textbox below and it gets eval()'d to create the network, so feel free to fiddle with the parameters and hit "reload". I found that, empirically and interestingly, deeper networks tend to work much better on this task given a fixed parameter budget.

Report questions/bugs/suggestions to @karpathy.



Choose your own image:

Original Image
Neural Network output


Learning rate:
The learning rate should probably be decreased over time (slide left) to let the network better overfit the training data. It's nice to not have to worry about overfitting.


You can upload your own image above (click Choose File), or you can click on any of the images below to load them.


Go back to ConvNetJS