Cartesian Tensor Face Relighting

This code demonstrates the use of Cartesian Tensors (3rd order) for face image relighting.
Updated 16 Jun 2010

View License

tensorRelightingDemo.m demonstrates the use of the Cartesian Tensor basis for facial Apparent BRDF (ABRDF) estimation and subsequent relighting. Given a few images of a face under different point source illuminations, the included code for ABRDF estimation can interpolate and extrapolate them to generate new images.

Please cite the following paper if you find this code useful:
Ritwik Kumar, Angelos Barmpoutis, Arunava Banerjee, Baba C. Vemuri, “Non-Lambertian Reflectance Modeling and Shape Recovery of Faces using Tensor Splines”, IEEE Transactions on Pattern Analysis and Machine Intelligence (PAMI), 2009.

Note that in the above paper we propose a method that combines the Cartesian Tensors at each pixel with spatial Splines. The spline part of the paper is not included in this code, but even without it, the provided code can be used for relighting, although with a little reduced relighting quality when the number of input images is small.

Cite As

Ritwik Kumar (2024). Cartesian Tensor Face Relighting (, MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R14SP3
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes