On the Random
Subset Sum Problem
and Neural Networks
Emanuele Natale
jointly with
A. Da Cunha & L. Viennot
11 January 2023
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/10120112/logo-i3s.png)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/9984848/logo-uca.png)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/9984836/logo-cnrs.png)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/10129439/pasted-from-clipboard.png)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/9984838/logo-inria.png)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/10129423/pasted-from-clipboard.png)
Deep Learning on the Edge
Turing test (1950)
Today
1st AI winter (1974–1980)
2nd AI winter (1974–1980)
"A hand lifts a cup"
Use of GPUs in AI (2011)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/10000827/comp.gif)
Today, most AI heavy lifting is done in the cloud due to the concentration of large data sets and dedicated compute, especially when it comes to the training of machine learning (ML) models. But when it comes to the application of those models in real-world inferencing near the point where a decision is needed, a cloud-centric AI model struggles. [...] When time is of the essence, it makes sense to distribute the intelligence from the cloud to the edge.
Neural Network Pruning
Blalock et al. (2020): iterated magnitude pruning still SOTA compression technique.
train
train
prune
prune
train
The Lottery Ticket Hypothesis
Frankle & Carbin (ICLR 2019):
Large random networks contains sub-networks that reach comparable accuracy when trained
train
sparse random network
sparse
bad network
..., train&prune
train&prune, ...,
large random network
sparse good network
train
sparse "ticket" network
sparse
good network
rewind
The Strong LTH
![](https://media2.giphy.com/media/7WNhbYMIcgYn7pCzHh/giphy.gif)
Ramanujan et al. (CVPR 2020) find a good subnetwork without changing weights (train by pruning!)
A network with random weights contains sub-networks that can approximate any given sufficiently-smaller neural network (without training)
Proving the SLTH
Pensia et al. (NeurIPS 2020)
Find combination of random weights close to \(w\)
Malach et al. (ICML 2020)
Find random weight
close to \(w\)
SLTH and the Random Subset-Sum Problem
Find combination of random weights close to \(w\):
Lueker '98: \(n=O(\log \frac 1{\epsilon})\)
RSSP. For which \(n\) does the following holds?
Given \(X_1,...,X_n\) i.i.d. random variables, with prob. \(1-\epsilon\) for each \(z\in [-1,1]\) there is \(S\subseteq\{1,...,n\}\) such that \[z-\epsilon\leq\sum_{i\in S} X_i \leq z+\epsilon.\]
SLTH for Convolutional Neural Networks
![](https://media4.giphy.com/media/i4NjAwytgIRDW/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/10121051/pasted-from-clipboard.png)
Theorem (da Cunha et al., ICLR 2022).
Given \(\epsilon,\delta>0\), any CNN with \(k\) parameters and \(\ell\) layers, and kernels with \(\ell_1\) norm at most 1, can be approximated within error \(\epsilon\) by pruning a random CNN with \(O\bigl(k\log \frac{k\ell}{\min\{\epsilon,\delta\}}\bigr)\) parameters and \(2\ell\) layers with probability at least \(1-\delta\).
Reducing Energy: the Hardware Way
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/9995372/Screenshot_2022-11-11_at_16-29-28_hardware-movidius-ncs-gen2-16x9.png.rendition.intel.web.720.405.png__WEBP_Image_720___405_pixels_.png)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/9995680/Screenshot_2022-11-11_at_18-59-54_IBM_s_new_AIU_artificial_intelligence_chip_IBM_Research_Blog.png)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/9996687/Screenshot_2022-11-12_at_11-24-01_Chip-comparison-01-uai-1032x1032.jpg__WEBP_Image_1032___1032_pixels____Scaled__89__.png)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/9997093/Screenshot_2022-11-12_at_18-25-59_MM1076-M.2-M-key-card.jpg.webp__WEBP_Image_1000___550_pixels_.png)
Resistive Crossbar Device
Analog MVM via crossbars of programmable resistances
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/10004090/crossbar_drawing.png)
Problem: Making precise programmable resistances is hard
Cfr. ~10k flops for digital 100x100 MVM
"Résistance équivalente modulable
à partir de résistances imprécises"
INRIA Patent deposit FR2210217
Leverage noise itself
to increase precision
RSS
Theorem
Programmable
effective resistance
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/10005529/rss_module_drawing.png)
Random Subset Sum Theory
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/10005529/rss_module_drawing.png)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/2027770/images/10005725/Screenshot_from_2022-11-15_22-11-56.png)
bits of precision for any target value are linear w.r.t. number of resistances
Worst case among
2.5k instances
Thank you
HCERES 2023
By Emanuele Natale
HCERES 2023
- 105