python-3.xneural-networkkeraspruning

Pruning in Keras


I'm trying to design a neural network using Keras with priority on prediction performance, and I cannot get sufficiently high accuracy by further reducing the number of layers and nodes per layer. I have noticed that very large portion of my weights are effectively zero (>95%). Is there a way to prune dense layers in hope of reducing prediction time?


Solution

  • Not a dedicated way :(

    There's currently no easy (dedicated) way of doing this with Keras.

    A discussion is ongoing at https://groups.google.com/forum/#!topic/keras-users/oEecCWayJrM.

    You may also be interested in this paper: https://arxiv.org/pdf/1608.04493v1.pdf.