How do i calculate hessian matrix for an image?
122 views (last 30 days)
David Legland on 20 Mar 2013
Hi, you need to compute second derivatives in each direction, using something like:
[gx, gy] = gradient(double(img));
[gxx, gxy] = gradient(gx);
[gxy, gyy] = gradient(gy);
The coefficients of the hessian matrix for each pixel are given by gxx, gxy and gyy.