I’ve read that I can add L1 loss in the network. But in this case, it is too complicated. Can anybody suggest me how to add L1 layer at some part of the network?
I’m not familiar with Torch7 either. However, I think the L1Penalty refers to L1 regularization, not to the L1 loss function.
If we thinking about machine learning as learning some function, L1 regularization is used as a way to prevent overfitting by “smoothing” the function. In particular, it penalizes for the the overall magnitude of weights.