Unconstrained Neural Network

Neural network with L1 regularization and weight pruning for sparse predictions

← Back to index

Model overview

Unconstrained neural network classifier using L1 regularization during training followed by post-training weight pruning to achieve sparsity. Unlike parameter-constrained models, this classifier uses ALL available tags as input features, relying on the combination of L1 regularization and pruning to eliminate unimportant connections.

Architecture

The network uses a single hidden layer with 256 neurons:

Training procedure

  1. Train with L1 regularization (λ=0.0001) to encourage small weights
  2. Apply weight pruning (threshold=0.01) to zero out small weights
  3. The pruned model achieves significant sparsity with minimal performance loss
5 CV folds
62.54% Mean accuracy
0.5898 Mean F1
0.156952 Mean p-adic loss
44,358 Avg non-zero params
90.6% Sparsity

Cross-validation results

FoldAccuracyF1P-adic loss (mean)Non-zero paramsSparsity
064.19%0.60700.14650537,28992.1%
163.20%0.60960.12686338,10591.9%
260.77%0.56730.16886851,34689.1%
362.91%0.60020.15217837,97991.9%
461.62%0.56500.19034657,07087.9%

Comparison with other models

The unconstrained neural network achieves the best p-adic loss among all models by using more parameters (after pruning), while the L1 regularization and pruning ensure that only the most important connections are retained. This demonstrates the tradeoff between model complexity and prediction accuracy.