The Hessian matrix has a wide range of applications in image processing, such as edge detection, feature point detection, etc. This paper proposes an image enhancement algorithm based on the Hessian matrix. First, the Hessian matrix is obtained by convolving the derivative of the Gaussian function. Then use the Hessian matrix to enhance the linear structure in the image. Experimental results show that the method proposed in this paper has strong robustness and accuracy.

Hessian matrix has a wide range of applications in image processing [

Performing Taylor expansion on the unary function f(x) at x0, the following formula can be obtained.

Among them, the remainder is the Peano remainder, and the part of the second derivative is mapped to the two-dimensional and multi-dimensional space as the Hessian matrix.

In a two-dimensional image, assuming that the function of the image pixel value relative to the coordinates (x, y) is f(x, y), then expand f(x + dx, y + dy)) at f(x0, y0) to get as follows:

The second matrix in the third term on the right side of the above formula is the Hessian matrix in two-dimensional space; therefore, we conclude that the Hessian matrix is the second derivative of a certain point in the space. To summarize further, the Hessian matrix in the multidimensional space can be expressed as:

As we all know, the second derivative represents the change law of the derivative. If the function is a curve and the curve has a second derivative, then the second derivative represents the curvature of the curve. The greater the curvature, the more curved the curve. By analogy, the second derivative of a point in the multidimensional space represents the speed at which the gradient drops at that point. Taking a two-dimensional image as an example, the first-order derivative is the grayscale change of the image, that is, the grayscale gradient, and the second-order derivative is the degree of grayscale gradient change. The larger the second derivative, the larger the gray gradient change.

But in a two-dimensional image, the Hessian matrix is a two-dimensional positive definite matrix with two eigenvalues and two corresponding eigenvectors. These two eigenvalues represent the anisotropy of the image in the direction pointed by the two eigenvectors. If an ellipse is composed of eigenvectors and eigenvalues, then this ellipse marks the anisotropy of the image change. So in a two-dimensional image, what kind of structure is the most isotropic and what kind of structure is more anisotropic? Obviously, the isotropy of the circle is the strongest, and the structure with the stronger linearity is more anisotropic.

The characteristics that the eigenvalues should have are shown in

λ1 | λ2 | Structure | Image feature |
---|---|---|---|

−High | −High | Spot | The foreground is bright |

+High | +High | Spot | The foreground is dark |

Low | −High | Linear | The foreground is bright |

Low | +High | Linear | The foreground is dark |

The Hessian matrix has many applications. The ellipse formed by the eigenvalues of the matrix and the eigenvector represents the anisotropy of the image, and this anisotropic image processing is applied. Taking a two-dimensional image as an example, the point structure in the image is isotropic, while the linear structure is anisotropic. Therefore, the Hessian matrix can be used to enhance the linear structure in the image and filter out point-like structures and noise points. Similarly, it can also be used to find the point structure in the image and filter out other information.

Of course, when using the Hessian matrix, there is no need to perform Taylor expansion on the image, only the elements in the matrix need to be directly obtained. Generally, the second derivative of a digital image uses the following formula:

However, this method has poor robustness and is susceptible to interference from local signals in the image. It can even be said that this derivation method is controversial. You can also use the following formula to calculate the second derivative:

In addition to the above two expression methods, the second derivative can also be expressed in other ways. Different methods often get different values, because this method only contains the information of three points including itself. not enough. According to the linear scale space theory (LOG), the derivative of a function is equal to the convolution of the derivative of the function and the Gaussian function. The formula is as follows:

Since the Gaussian template can contain the information of all points in the surrounding rectangle, there will be no errors. Therefore, when using the image to obtain the elements in the hessian matrix, the image can be convolved with the second derivative of the Gaussian function. The second-order partial derivative formula of Gaussian function is as follows:

When writing a program, you need to convolve the image on three templates in advance to generate a “graph” of three partial derivatives, and then index the partial derivatives of the corresponding positions each time as needed.

Use the algorithm in this paper to carry out an image quality enhancement experiment on a frame of ordinary pictures.

As can be seen from

This paper proposes an image enhancement algorithm based on Hessian matrix. The simulation experiment results show that the linear structure of some images is enhanced, and the linear structure of some images is weakened. The effect of linear result enhancement is related to the size of the derivation window. However, in the same image, the thickness of the linear structure is different, and the same window size cannot be applied to all windows. The multi-template method may be able to solve the above problem, that is, convolve a point with Gaussian templates of multiple scales, and then select the most anisotropic result as the output of the point.

Thanks to Hunan First Normal University for providing experimental sites and equipment.