projects / proj-la-002
Next task →
Projects/Linear Algebra/Compressed sensing with OMP and basis pursuit — real sparse-matrix workload
Level 4 · advanced · ~11 h

Compressed sensing with OMP and basis pursuit — real sparse-matrix workload

Recover sparse signals from 20% Gaussian measurements using orthogonal matching pursuit and L1 minimization, and map the recovery phase transition. Run on a real sparse matrix and report memory footprint together with accuracy.
Add to portfolio →

Problem statement

  • 01Recover sparse signals from 20% Gaussian measurements using orthogonal matching pursuit and L1 minimization, and map the recovery phase transition. Run on a real sparse matrix and report memory footprint together with accuracy.

Real-world motivation

  • 01L1 convex relaxation and greedy pursuit solve the same inverse problem with very different computational and statistical behavior. The real sparse-matrix workload setting forces concrete choices about data, scale and evaluation.

Learning objectives

  • 01Implement OMP from scratch
  • 02Solve the L1 problem with an ADMM solver
  • 03Compare recovery thresholds
  • 04Report peak resident memory in MB alongside the baseline metrics.

Technical architecture

  • 01measurement matrix with normalized columns
  • 02greedy residual correlation loop
  • 03ADMM with soft thresholding

Mathematical foundations

  • 01$\min_x\lVert x\rVert_1$ subject to $Ax=y$
  • 02OMP selection $j=\arg\max_i|a_i^\top r|$

Dataset and sources

  • 01SuiteSparse sparse matrices
  • 02MovieLens-100K user-item matrix

Step-by-step tasks

  • 01Frame the task and freeze the real sparse-matrix workload evaluation protocol with a fixed random seed.
  • 02Implementation 1: Implement OMP with QR re-orthogonalization
  • 03Implementation 2: Implement ADMM with rho=1 and 200 iterations
  • 04Implementation 3: Sweep measurement ratio m/n
  • 05Verification 1: Verify exact recovery for a 1-sparse vector
  • 06Verification 2: Check ADMM primal residual decreases
  • 07Run the ablation grid and report peak resident memory in MB over three independent trials.

Implementation requirements

  • 01Implement OMP with QR re-orthogonalization
  • 02Implement ADMM with rho=1 and 200 iterations
  • 03Sweep measurement ratio m/n
  • 04Log all hyperparameters and the random seed for the real sparse-matrix workload run.

Testing requirements

  • 01Verify exact recovery for a 1-sparse vector
  • 02Check ADMM primal residual decreases
  • 03Measure peak resident memory in MB over at least three seeds.

Evaluation metrics

  • 01reconstruction SNR
  • 02support F1
  • 03runtime
  • 04peak resident memory in MB

Expected outputs

  • 01phase-transition heatmap
  • 02example reconstructions

Common failure modes

  • 01coherent measurement matrices cause OMP misselection
  • 02ADMM converges slowly for small rho
  • 03real matrices have heavy-tailed row degrees that break uniform sampling

Stretch goals

  • 01add LASSO with cvxpy
  • 02test structured sparsity with group LASSO
  • 03compare CSR and COO layouts and explain cache effects

Research extensions

  • 01derive the restricted isometry constant for Bernoulli matrices
  • 02study greedy versus convex recovery near the threshold

GitHub submission requirements

  • 01A repository whose README states the real sparse-matrix workload protocol and the exact command to reproduce it.
  • 02Source for the scratch implementation, a test file, and a results table with uncertainty estimates.
  • 03A two-page report explaining failures on SuiteSparse sparse matrices and what the ablation revealed.

Completion rubric

  • 01OMP and ADMM correct
  • 02phase transition measured
  • 03coherence effect explained
  • 04Extra credit: compare CSR and COO layouts and explain cache effects

Submit when every rubric item is satisfied and your repository contains runnable code plus a reproduction command.