TL;DR. Dont read. Only useful for signal/image-processing/information theory people.
Can you solve Ax = b for x when number of rows are less than number of columns in A i.e there are more variables than equations? Such a system is called under-determined system. For examples, give me 3 numbers whose average is 3. Or solve x/3 + y/3 + z/3 = 3. You are right! There are many solutions to this problem!
One adds more constraints and hope for unique solution. Give me a solution which has minimum length (minimize L2-norm)? Answer is 3,3,3 (Generalized Inverse). Give me a solution which is most sparse (least number of non-zero entries)? Answer is 9,0,0 (or 0,0,9).
Many signals are sparse (in some domain). Images are sparse in Fourier/Wavelets domain; neural activity is sparse in time-domain, activity of programming is sparse in spatial-domain. Can we solve under-determined Ax = b for sparse x. Or formally,
minxL0(x), st Ax = bwhere L0 is the 0-norm i.e. number of non-zero entries.
This problem is hard to solve. L0 is not a convex-function. Probably one can use convex relaxation trick and replace the non-convex function with convex one.
minxL1(x), st Ax = bIt is now well-understood that under certain assumptions on A, we can recover
by solving this tractable convex-optimization problem rather than the
original NP hard problem. Greedy strategy based solvers works even faster though they are not proven to be as accurate as this one.
Skip it if formatting is not good.
If xN (size N) is S − sparse then an under-determined system AkNxN = bk -- where b is vector of k observations -- can be solved exactly given that A (measurement matrix) has following properties:
Lets there is a sparse signal x of length N. Its sparse. We take a dot-product of x with a random vector Ai of size N i.e. bi = Ai * x. We make k such measurements. We can put all k Ai into a matrix A and represent the process by a linear system:
$\begin{bmatrix} A_1 \\ A_2 \\ \vdots \\ A_k \end{bmatrix} * x =
\begin{bmatrix} b_1 \\ b_2 \\ \vdots \\ b_k \end{bmatrix} \qquad(1)$
Note that each Ai has the dimension 1 × N. We can rewrite eq. 1 as following:
Ax = b (2)
where dimension of A are k × N and k < <N. This is an under-determined system with the condition that x is sparse. Can we recover x (of size N) from b (of size k < < N)?
Figure fig. 1 shows a real system. Compressed sensing says that x can be recovered by solving the following linear program.
minx‖x‖1 given Ax = b (3)
Data for fig. 2 is generated by script ./compressed_sensing.py
and for fig. 3, data is generated by script ./magic_reconstruction.py
. Both of these scripts also generate similar figures.
Dependencies In addition to scipy
, numpy
, and matplotlib
, we also need pyCSalgo. It is available via pip: pip install pyCSalgo --user
.
Code is available at github
For step 4, we are using function l1eq_pd
from Python library pyCSalgo
. This is re-implementation of l1magic
routine written in Matlab by Candes. When k > >2S where S is the sparsity of x, we can recover x quite well. In practice, k ≥ 4S almost always gives exact result.
Solution
Figure 2: Solution by CS which is almost equal to the original signal.Restricted isometric property (RIP) of a matrix A is defined as the following.
Given δs ∈ (0, 1), for any sub-matrix As of A, and for any sparse vector y, if following holds
(1 − δs)‖y‖2 ≤ ‖Asy‖2 ≤ (1 + δs)‖y‖2To learn about compressed sensing, I recommend following articles
There are many many other great articles and papers on this subject. There are some dedicated web-pages also.
- Dilawar
Thank you Dilawar. I hope you don't mind if I add your content to
wncc-iitb.org/wiki
Even being long, it is a good start for people wanting to learn about this
Regards
Ayush
--
--
The website for the club is http://wncc-iitb.org/
To post to this group, send email to wncc...@googlegroups.com
---
You received this message because you are subscribed to the Google Groups "Web and Coding Club IIT Bombay" group.
To unsubscribe from this group and stop receiving emails from it, send an email to wncc_iitb+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Thank you Dilawar. I hope you don't mind if I add your content to
wncc-iitb.org/wiki