Compute the L1 or L2 penalty added to the loss from your weights and regularization strength, and compare Lasso sparsity with Ridge shrinkage.
L1 產生稀疏權重,L2 使權重平滑。