I have a neural network model trained on the mnist dataset.
If I add to the loss function a l1 regularization term I get many parameters near 0.
But if I set manually those parameters to 0 the model performs worse and I have to train the model a little more to get the same performance.
How can I train all parameters except those equal to 0?
Thank you.