abee870ada10589e698c7b3f60877fa7529fcf2b
Previous code computed scalar norms and multiplied by W, giving gradients that scaled with total weight magnitude rather than the correct per-element derivatives: L1: gradient is λ·sign(W), not λ·‖W‖₁·W L2: gradient is 2λ·W, not λ·‖W‖₂²·W Also removed the combined (l1+l2)*W term which incorrectly mixed the two. weight_decay (correct L2 form λW) is kept as a separate term. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
GRBM
Paper
https://medium.com/@rtdcunha/gaussian-bernoulli-restricted-boltzmann-machines-4a68b8765485 https://journals.plos.org/plosone/article/file?id=10.1371/journal.pone.0171015&type=printable
Code
https://github.com/DSL-Lab/GRBM/tree/main
CRBM
Paper
https://www.ee.nthu.edu.tw/hchen/pubs/iee2003.pdf
Regularization
https://benihime91.github.io/blog/machinelearning/deeplearning/python3.x/tensorflow2.x/2020/10/08/adamW.html https://medium.com/analytics-vidhya/l1-vs-l2-regularization-which-is-better-d01068e6658c https://jamesmccaffreyblog.com/2019/05/09/the-difference-between-neural-network-l2-regularization-and-weight-decay
Languages
Jupyter Notebook
96.9%
Python
3.1%