Inverse Problems in Imaging

This page is for information related to the 4th year/CGVI course COMP0114 : Inverse Problems in Imaging.


Some students are suprised at the level of mathematics needed in this course. Here is a Self Test. Please try this and if you find it difficult, please discuss with me whether to take this module.


I have put some lecture notes from last year here (these are liable to change before this years course)
Here is a link to notes and code from Bangti Jin on Bayesian Methods.

Here are the slides from Felix Lucka on Total Variation Regularisation Methods in Inverse problems
Here are some refresher notes on Fourier Transforms and Sampling in case you're a bit rusty on this.

First Examples

Example of model fitting (over determined) modelfit.m
Example of model fitting (under determined) modelfit_under.m
Example of ill conditioned matrix inversion ip1.m This script runs a statistical model on the same problem iptoy.m
Second example inverts this matrix with a Gaussian prior with covariance C ip3.m.
Example call for this : ip3(0.2,0.05,[1 1; 1 -1]);

One dimensional blur of function in interval [0,1] linblur.m
Regularised inversion of linblur using Truncated SVD linsvd_truncsvd.m
Regularised inversion of linblur using Zero-Order Tikhonov linsvd_tk0.m

Here's the toy image deblurring example using Fourier Transforms ToyDeblur2D.m

Bias Variance

This code runIPtoyReg.m creates Bias-Variance for the 2x2 toy problem. It requires this function IptoyRegFunc.m to do the regularisation

Regularisation Parameter Selection

Here are some functions that calculate various regularisation parameter selection procedures for the 1 dimensional linear blurring example

  • Discrepency Principle DP.m
  • Miller Criterion Miller.m
  • Predictive Risk predrisk.m
  • Unbiased Predictive Risk Estimator UPRE.m
  • Generalised Cross-Validation GCV.m

    Here's an example how to use these compare_regselect_script.m
    Further example, that compares zero-order and first order Tikhonov compare_TK0TK1.m This example requires a first order finite difference derivative operator, such as the one produced by this function lindf.m

    Krylov methods

    Here is an example how to do the 1D debluring problem using Krylov Methods. This makes use of a custom built Conjugate Gradient Method, as well as comparison to Steepest Descent Method
    Here's these applied to the Toy Problem.

    Image Priors

    Here is the code demonstrating different priors based on the image gradient
    We can run these as a diffusion scheme to demonstrate Scale Space.
    Here we apply these to a denoising problem.
    Here is a demo of drawing from anisotropic priors in 1D.

    Nonlinear Optimisation

    Here are some examples for nonlinear optimisation of the Rosenbrock function. These make use of the following Line Search Function

  • Generic Steepest Descents and Rosenbrock Example
  • Generic Conjugate Gradients and Rosenbrock Example
  • Generic Damped Gauss Newton and Rosenbrock Example
  • Generic Levenburg-Marquardt and Rosenbrock Example

    Constrained Optimisation

  • Function for inequality constrained optimisation using active sets
    Example applied to a quadratic matrix function quadratic matrix function
  • Equality constrained Lp-norm minimisation. Function returning Lp-norm of a vector.
    2D example with single equality consraint : Lpmin.m


  • Examples of forward and adjoint Radon Transform
  • Demonstration of constructing the Backprojection filter explicitly
  • Display sinogram space
  • Show the convolution properties of unfiltered BackProjection
  • SVD of the Radon Transform
  • Reconstruction from Undersampled Data


  • Solving the 1D deblurring problem using Total Variation and quadratic programming
  • Solving the 1D deblurring problem using L1-norm of wavelet transform and quadratic programming

    Poisson noise

  • Example of adding Poisson noise to an image
  • Example of solving 1D deblurring from Poisson noise using Richardson-Lucy (MLEM in 1D).


    Here's a simple Wavelet Example on image denoising

    Sparsity Regularisation

    These examples are from Bangti Jin's lecture.
  • Iterative Shrinkage Test (ISTA)
  • Coordinate Descent
  • Iteratively Reweighted Least Squares.

    Stochastic Optimisation

    The basic tools are the Metropolis-Hasting Sampling Method and the Gibbs Sampling Method

    Here are some examples using each method

  • Simple unimodal Gaussian sampling using Metropolis-Hasting and Gibbs
  • Mixture of Gaussian sampling using Metropolis-Hasting and Gibbs
  • Highly non-linear function sampling using Metropolis-Hasting and Gibbs
  • Posterior sampling of regularised inverse problem using Metropolis-Hasting and Gibbs

    The Metropolis Hastings algorithm is easily turned into a Simulated Annealing method. Here is one way, and an example using the above non-linear function

    Here are Bangti Jin's examples on

  • Metropolis-Hastings 2D and
  • Hierarchical Gibbs
  • Gibbs sampling for a sparse prior


    Here's a simple Inpainting Example use Tikhonov priors and a PDE based approach.


    Useful list of software for compressive sampling
    A famous reference on painless congugate gradients
    A useful book

    Coursework 1 : Weeks 1-3

    These exercises are formally assesed.
    Hints for Coursework 1 Hand in date is 28-Jan-2019, 11.55p.m

    Coursework 2 : weeks 4-7

    The second coursework will be handed out in week 4 PDF format
    Test Images for use in CW2
  • boat (tiff format)
  • man (tiff format)
  • Cameraman (png format)
  • house (png format)

    Hand in date is Wednesday 27th February 2019, 11.55p.m
    Here are some hints for solution.

    Literature Study : Week 8

    The literature study exercise is described here.
    This is a study of this paper by Candes, Romberg and Tao, 2005 Hand in date is Monday 11-March-2019, 11.55p.m

    MiniProjects : Weeks 9-11

    The final coursework is a miniproject. It will be handed out in week 9
    The coursework has two parts. Part A is compulsory for everyone. Part B has a number of choices for advanced topics.
    Here is the description of part A
    Here is the description of Part B

    You will need data for this project. Here it is
    in Matlab format.
    and in Python format.
    Here are some hints for part A :
    in Matlab format.
    and in Python format.

    Past papers

  • GV08 2016