CN114612345A - Light source detection method based on image processing - Google Patents

Light source detection method based on image processing Download PDF

Info

Publication number
CN114612345A
CN114612345A CN202210346884.0A CN202210346884A CN114612345A CN 114612345 A CN114612345 A CN 114612345A CN 202210346884 A CN202210346884 A CN 202210346884A CN 114612345 A CN114612345 A CN 114612345A
Authority
CN
China
Prior art keywords
gray
value
image
pixel point
light source
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202210346884.0A
Other languages
Chinese (zh)
Other versions
CN114612345B (en
Inventor
邹志祥
时宗胜
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Centch Electronics Shanghai Co ltd
Original Assignee
Jiangsu Tongfang Internet Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Jiangsu Tongfang Internet Technology Co ltd filed Critical Jiangsu Tongfang Internet Technology Co ltd
Priority to CN202210346884.0A priority Critical patent/CN114612345B/en
Publication of CN114612345A publication Critical patent/CN114612345A/en
Application granted granted Critical
Publication of CN114612345B publication Critical patent/CN114612345B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/70Denoising; Smoothing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10052Images from lightfield camera
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30168Image quality inspection

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Image Processing (AREA)

Abstract

The invention relates to a light source detection method based on image processing; acquiring corresponding gray level images of a shot object under light sources of different degrees; dividing each gray image into a plurality of gray image blocks, and calculating the mutation degree of each pixel point in each gray image block so as to obtain an estimated noise point in each gray image block; replacing the gray value of the estimated noise point by using the gray replacement value to obtain an estimated image block corresponding to each gray image block; further acquiring singular value thresholds corresponding to the gray image blocks; denoising each gray image block based on a singular value threshold to obtain a denoised image block corresponding to each gray image block; splicing the denoising image blocks to obtain denoising images corresponding to the gray level images; and judging the number of noise points in each gray level image according to the denoised image and the corresponding gray level image, calculating a judgment index corresponding to each image information according to the number of the noise points, and judging the light source corresponding to the maximum judgment index as the optimal light source. The invention can accurately detect the light source.

Description

Light source detection method based on image processing
Technical Field
The invention relates to the field of image processing, in particular to a light source detection method based on image processing.
Background
In the process of shooting or video shooting, the object to be shot is polished to improve the brightness and contrast of the image, reduce noise points in the image and enable the final imaging result to be better, wherein the imaging effect of the object to be shot under light sources with different intensities is different.
In the preliminary preparation work of photography, a photographer usually takes a sample, and detects whether a corresponding light source is an optimal light source according to the shooting experience, that is, whether an image shot under the light source is an image with the least noise points; however, such detection results are random, i.e., the accuracy of each detection result cannot be ensured; therefore, it is desirable to provide an accurate light source detection method.
Disclosure of Invention
In order to solve the above technical problems, an object of the present invention is to provide a light source detection method based on image processing, which adopts the following technical solutions:
acquiring corresponding image information of a shot object under light sources of different degrees, and performing graying processing on the image information to obtain a grayscale image;
dividing each gray image into a plurality of gray image blocks with the size of m multiplied by m, calculating the mutation degree of each pixel point in each gray image block, and marking the pixel point with the mutation degree larger than the noise threshold value as an estimated noise point;
replacing the gray value of the estimated noise point in the gray image block by using the gray replacement value to obtain an estimated image block corresponding to each gray image block;
acquiring a singular value threshold corresponding to each gray image block according to the gray image block and the corresponding estimated image block;
performing singular value decomposition denoising operation on each gray image block based on the singular value threshold value to obtain a denoised image block corresponding to each gray image block;
splicing the denoising image blocks to obtain denoising images corresponding to the gray level images;
judging the number of noise points in each gray level image according to the denoised image and the corresponding gray level image; and calculating a judgment index corresponding to each image information according to the number of the noise points, wherein the light source corresponding to the maximum judgment index is the optimal light source.
Further, the degree of mutation is:
Figure BDA0003576805780000011
wherein ,δiThe degree of mutation of the pixel point i,
Figure BDA0003576805780000012
the gray value of the pixel point i under the light source of the v-th degree;
Figure BDA0003576805780000013
the gray value of the pixel point t under the light source of the v-th degree is shown, and the pixel point t is positioned right above the pixel point i;
Figure BDA0003576805780000021
the gray value of the pixel point u under the light source of the v-th degree is the gray value, and the pixel point u is positioned right below the pixel point i;
Figure BDA0003576805780000022
the gray value of the pixel point l under the light source of the v-th degree is shown, and the pixel point l is positioned at the left of the pixel point i;
Figure BDA0003576805780000023
the gray value of the pixel point r under the light source of the v-th degree is that the pixel point r is positioned at the right side of the pixel point i.
Further, the gray replacement value comprises a first replacement value and a second replacement value; obtaining a first coefficient according to the difference value between the gray value of the estimated noise point and the first replacement value; obtaining a second coefficient according to the difference value between the gray value of the estimated noise point and the second replacement value; and comparing the first coefficient with the second coefficient, wherein if the first coefficient is greater than the second coefficient, the first replacement value is the gray level replacement value of the estimated noise point, and if the first coefficient is less than the second coefficient, the second replacement value is the gray level replacement value of the estimated noise point.
Further, the first replacement value is:
Figure BDA0003576805780000024
wherein ,
Figure BDA0003576805780000025
in order to estimate the gray value of the noise point o under the light source of the v-th degree, N is the total number of pixel points in the gray image,
Figure BDA0003576805780000026
j is the total number of the gray images which are acquired again under the light source of the v degree, wherein the gray value of the pixel point corresponding to the position of the estimated noise point o in the c gray image acquired again under the light source of the v degree is the gray value of the pixel point.
Further, the second replacement value is:
Figure BDA0003576805780000027
wherein ,
Figure BDA0003576805780000028
to estimate the gray value of the noise point o under the light source of the v-th degree,
Figure BDA0003576805780000029
the gray value of the pixel point a under the light source of the v-th degree is the gray value, and the pixel point a is positioned right above the estimated noise point o;
Figure BDA00035768057800000210
the gray value of the pixel point b under the light source of the v-th degree is the gray value, and the pixel point b is positioned right below the estimated noise point o;
Figure BDA00035768057800000211
the gray value of the pixel point e under the light source of the v-th degree is the gray value, and the pixel point e is positioned at the left of the estimated noise point o;
Figure BDA00035768057800000212
the gray value of the pixel point f under the light source of the v-th degree is that the pixel point f is positioned at the right side of the estimated noise point o.
Further, the singular value threshold value obtaining method includes: calculating the noise variance of each gray image block and the corresponding estimation image block, and determining a singular value threshold according to the noise variance;
the noise variance is:
Figure BDA00035768057800000213
wherein ,τ2In order to be the variance of the noise,
Figure BDA00035768057800000214
is a matrix corresponding to a block of gray-scale images, AxIn order to estimate the matrix corresponding to the image block,
Figure BDA00035768057800000215
is Frobenius norm.
Further, the method for judging the noise point comprises the following steps: calculating the absolute value of the difference value between the gray value of each pixel point in the de-noised image and the gray value of each corresponding pixel point in the gray image to obtain a difference image, judging the gray value of each pixel point in the difference image and the size of a threshold value, and marking the pixel point of which the gray value is greater than the threshold value as a noise point.
Further, the method for obtaining the threshold value comprises the following steps:
Figure BDA0003576805780000031
wherein ,
Figure BDA0003576805780000032
in the formula ,hgAnd w is the difference value of the gray value of the estimated noise point and the gray value of the corresponding pixel point in the de-noised image, and the number of the estimated noise points.
The embodiment of the invention at least has the following beneficial effects:
according to the method, the singular value threshold corresponding to each gray level image block is calculated through the estimated image blocks, then, singular value decomposition denoising operation is carried out on each gray level image block according to the singular value threshold to obtain a denoised image block, a denoised image corresponding to the gray level image is obtained, the number of noise points is calculated according to the denoised image and the corresponding gray level image, finally, the judgment index corresponding to each gray level image is calculated according to the number of the noise points, and the light source corresponding to the maximum judgment index is the optimal light source. When the estimation image block is calculated, the gray value of the estimation noise point is replaced by the first replacement value and the second replacement value, so that the replacement result is more accurate, the obtained estimation image block is more accurate, and the accuracy of the detection result of the light source is higher.
According to the invention, through processing the gray level images under different degrees of light sources, the detection result of the corresponding light source is more accurate, the problem of randomness of the detection result in the prior art is solved, and meanwhile, a large amount of labor cost is saved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions and advantages of the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and other drawings can be obtained by those skilled in the art without creative efforts.
Fig. 1 is a flowchart of a method of an embodiment of a light source detection method based on image processing according to the present invention.
Detailed Description
To further illustrate the technical means and effects of the present invention adopted to achieve the predetermined objects, the following detailed description of the light source detection method based on image processing according to the present invention, its specific implementation, structure, features and effects will be given with reference to the accompanying drawings and preferred embodiments. In the following description, different "one embodiment" or "another embodiment" refers to not necessarily the same embodiment. Furthermore, the particular features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs.
Referring to fig. 1, a flowchart illustrating steps of a method for detecting a light source based on image processing according to an embodiment of the present invention is shown, where the method includes the following steps:
step 1, acquiring corresponding image information of a shot object under light sources of different degrees, and performing graying processing on the image information to obtain a grayscale image.
Specifically, light sources with different degrees are arranged to polish a shot object, and a camera is used for collecting image information; wherein, the ratio of the long-edge pixels to the wide-edge pixels in the control image information is 1: 1.
In this embodiment, a weighted average method is used to perform graying processing on image information to obtain a grayscale image, and as another embodiment, a maximum value method, a component method, an average value method, or the like may be used.
And 2, dividing each gray image into a plurality of gray image blocks with the size of m multiplied by m, calculating the mutation degree of each pixel point in each gray image block, and marking the pixel point with the mutation degree larger than the noise threshold value as an estimated noise point.
The degree of mutation was:
Figure BDA0003576805780000041
wherein ,δiThe degree of mutation of the pixel point i,
Figure BDA0003576805780000042
the gray value of the pixel point i under the light source of the v-th degree;
Figure BDA0003576805780000043
the gray value of the pixel point t under the light source of the v-th degree is the gray value of the pixel point t, and the pixel point t is positioned right above the pixel point i;
Figure BDA0003576805780000044
the gray value of the pixel point u under the light source of the v-th degree is the gray value, and the pixel point u is positioned right below the pixel point i;
Figure BDA0003576805780000045
the gray value of the pixel point l under the light source of the v-th degree is shown, and the pixel point l is positioned at the left of the pixel point i;
Figure BDA0003576805780000046
the gray value of the pixel point r under the light source of the v-th degree is that the pixel point r is positioned at the right side of the pixel point i.
In this embodiment, the noise threshold is set to 200, and during the specific operation process, the noise threshold can be adjusted by the implementer according to the actual situation. The larger the mutation degree of the pixel point is, the higher the possibility that the pixel point is an estimated noise point is.
Specifically, the size of the grayscale image block is 1/10 of the size of the grayscale image, and in the actual operation process, an implementer can adjust the size of the grayscale image block according to the situation; the size of the gray-scale image block influences the denoising precision and the calculated amount in the subsequent singular value decomposition denoising process, and if the gray-scale image block is too large, too few similar blocks are searched in the singular value decomposition denoising process, so that the denoising precision is reduced; and if the gray image block is too small, too many similar blocks are searched in the singular value decomposition denoising process, so that the calculated amount is greatly increased, and further, the denoising result is inaccurate, and therefore, a proper gray image block needs to be selected.
The gray-scale image blocks in the present embodiment include a gray-scale image block including an estimated noise point and a gray-scale image block not including an estimated noise point.
And 3, replacing the gray value of the estimated noise point in the gray image block by using the gray replacement value to obtain an estimated image block corresponding to each gray image block.
The gray scale replacement value comprises a first replacement value and a second replacement value; obtaining a first coefficient according to the difference value between the gray value of the estimated noise point and the first replacement value; obtaining a second coefficient according to the difference value between the gray value of the estimated noise point and the second replacement value; and comparing the first coefficient with the second coefficient, wherein if the first coefficient is greater than the second coefficient, the first replacement value is the gray level replacement value of the estimated noise point, and if the first coefficient is less than the second coefficient, the second replacement value is the gray level replacement value of the estimated noise point o.
The first alternative value is:
Figure BDA0003576805780000051
wherein ,
Figure BDA0003576805780000052
in order to estimate the gray value of the noise point o under the light source of the v-th degree, N is the total number of pixel points in the gray image,
Figure BDA0003576805780000053
j is the total number of the gray images which are acquired again under the light source of the v degree, wherein the gray value of the pixel point corresponding to the position of the estimated noise point o in the c gray image acquired again under the light source of the v degree is the gray value of the pixel point.
It should be noted that, noise related to illumination is mainly poisson noise, so the noise considered in this embodiment is poisson noise, and because poisson noise satisfies poisson distribution, that is, in a plurality of images acquired under light sources of the same degree, the position of a certain noise point in the plurality of images does not remain unchanged all the time, if a pixel point with a coordinate (x, y) in one of the images is a noise point, a pixel point with a coordinate (x, y) in the remaining other images is not a noise point, this embodiment determines a first replacement value by using this characteristic of poisson noise, and the first replacement value is determined by using the characteristic of poisson noise in the above formula
Figure BDA0003576805780000054
Representing the probability that the pixel point with the coordinate (x, y) in one image is the noise point,
Figure BDA0003576805780000055
and (3) representing the probability that the pixel point with the coordinate (x, y) in the rest other images is a non-noise point.
The second alternative value is:
Figure BDA0003576805780000056
wherein ,
Figure BDA0003576805780000057
to estimate the gray value of the noise point o under the light source of the v-th degree,
Figure BDA0003576805780000058
the gray value of the pixel point a under the light source of the v-th degree is the gray value, and the pixel point a is positioned right above the estimated noise point o;
Figure BDA0003576805780000059
the gray value of the pixel point b under the light source of the v-th degree is the gray value, and the pixel point b is positioned right below the estimated noise point o;
Figure BDA00035768057800000510
the gray value of the pixel point e under the light source of the v-th degree is the gray value, and the pixel point e is positioned at the left of the estimated noise point o;
Figure BDA00035768057800000511
the gray value of pixel point f under the light source of the v-th degree is that pixel point f is located on the right of the estimated noise point o.
In this embodiment, if there are other estimated noise points in the 4-neighborhood pixel points of the estimated noise point o, but the noise threshold is not selected to screen out the other estimated noise points, at this time, the calculated second replacement value becomes large, and the second coefficient becomes small, so that the replacement value corresponding to the large coefficient is selected as the gray level replacement value of the estimated noise point o in this embodiment, which reduces the error, and makes the replacement result of the estimated noise point o more accurate.
And 4, acquiring singular value thresholds corresponding to the gray image blocks according to the gray image blocks and the corresponding estimated image blocks.
Specifically, the singular value threshold value obtaining method includes: and calculating the noise variance of the gray image block and the corresponding estimation image block, and determining a singular value threshold according to the noise variance.
The noise variance is:
Figure BDA0003576805780000061
wherein ,τ2In order to be the variance of the noise,
Figure BDA0003576805780000062
is a matrix corresponding to a block of gray-scale images, AxIn order to estimate the matrix corresponding to the image block,
Figure BDA0003576805780000063
is Frobenius norm.
Further, it can be known from the well-known theorem that: for an arbitrary real matrix Y, if the rank of matrix X is k, then there will be:
Figure BDA0003576805780000064
wherein ,
Figure BDA0003576805780000065
is Frobenius norm, lambdai(i ═ 1, 2, 3 … n) is the singular value of matrix Y.
Thus, the relationship obtainable by the above theorem is:
Figure BDA0003576805780000066
if and only if
Figure BDA0003576805780000067
The equation holds true. A. the0In order to de-noise an image block,
Figure BDA0003576805780000068
matrices corresponding to blocks of grey-scale images
Figure BDA0003576805780000069
After the k-th singular value of (1) is fully returned to 0, performing inverse transformation on the matrix; therefore, the temperature of the molten metal is controlled,
Figure BDA00035768057800000610
can be approximated as a denoised image block, based on which the noise square tau is solved2And
Figure BDA00035768057800000611
determining the value of k according to the minimum value of the difference, and recording k as the singular value threshold of the gray-scale image block corresponding to the estimated noise point.
It should be noted that, since it has been described in step 2 that the grayscale image blocks include grayscale image blocks including estimated noise points and grayscale image blocks not including estimated noise points, in this embodiment, the grayscale image blocks including estimated noise points have corresponding estimated image blocks and singular value thresholds, and the grayscale image blocks not including estimated noise points have no corresponding estimated image blocks and singular value thresholds.
And 5, performing singular value decomposition denoising operation on each gray image block based on a singular value threshold to obtain a denoised image block corresponding to each gray image block.
In the embodiment, before singular value decomposition denoising is performed, similar blocks corresponding to all gray level image blocks are searched by using a block matching algorithm; the conditions for similar blocks are: firstly, recording the gray value of an estimated noise point as 0 in a matrix corresponding to a gray image block, recording the position to obtain a new matrix, then, carrying out global search on the gray image to find out a matrix which is not equal to the gray value of the new matrix except the 0 position and has the same gray value at other positions, and judging that the image block corresponding to the matrix is a similar block of the gray image block; the block matching algorithm is a known technique, and is not described in detail herein.
Specifically, the singular value decomposition denoising process includes: matrix corresponding to gray image blocks
Figure BDA00035768057800000612
Performing singular value decomposition, i.e.
Figure BDA00035768057800000613
wherein ,U,VTIs an orthogonal matrix, and Λ is
Figure BDA00035768057800000614
The singular values are arranged in the singular value matrix from large to small, the singular values in the singular value matrix after the singular value threshold k obtained in the step 4 are all returned to 0, and then the singular value matrix is obtained
Figure BDA00035768057800000615
Matrix subjected to singular value decomposition and denoising
Figure BDA00035768057800000616
Similarly, the same operation is performed on the matrixes corresponding to the similar blocks to obtain a matrix set
Figure BDA00035768057800000617
(n ═ 1, 2, 3 … n,) n is the total number of similar blocks; then the matrix of the corresponding denoised image block of the gray level image block is:
Figure BDA0003576805780000071
in the formula ,A0In order to denoise the matrix corresponding to the image block,
Figure BDA0003576805780000072
is composed of
Figure BDA0003576805780000073
The matrix after the singular value decomposition and denoising is carried out,
Figure BDA0003576805780000074
and carrying out singular value decomposition and denoising on the matrix corresponding to the z-th similar block.
In step 4 of this embodiment, it is pointed out that the grayscale image block without the estimated noise point has no corresponding singular value threshold, and therefore, the grayscale image block without the estimated noise point does not need to perform singular value decomposition denoising operation; the embodiment takes the gray image block without the estimated noise point as the corresponding de-noised image block.
It should be noted that the estimated image block is related to selection of the singular value threshold, in this embodiment, only the gray value of the estimated noise point is replaced by the gray value replacement value to obtain the estimated image block, and then the singular value threshold is determined, and the singular value threshold is not subjected to adaptive analysis, so that the singular value threshold causes that a part of noise points are not detected and a phenomenon that the denoised image block is inaccurate occurs, and therefore, the denoised image block can be more accurately obtained by selecting the similar block.
And 6, splicing the denoising image blocks to obtain a denoising image corresponding to each gray level image.
Specifically, the splicing method comprises the following steps: and finding out each de-noised image block corresponding to each gray level image, and splicing each de-noised image block according to the coordinate position to obtain a de-noised image corresponding to the gray level image.
Step 7, judging the number of noise points in each gray level image according to the denoised image and the corresponding gray level image; and calculating the judgment indexes corresponding to the gray images according to the number of the noise points, wherein the light source corresponding to the maximum judgment index is the optimal light source.
The method for judging the noise point comprises the following steps: calculating the absolute value of the difference value between the gray value of each pixel point in the de-noised image and the gray value of each corresponding pixel point in the gray image to obtain a difference image, judging the gray value of each pixel point in the difference image and the size of a threshold, and marking the pixel point of which the gray value is greater than the threshold as a noise point.
The threshold values in the above are:
Figure BDA0003576805780000075
wherein ,
Figure BDA0003576805780000076
in the formula ,hgAnd e is the difference value of the gray value of the estimated noise point and the gray value of the corresponding pixel point in the de-noised image, and e is the number of the estimated noise points.
Further, in order to obtain the number of final noise points in the grayscale image more clearly, the grayscale value of the final noise point is recorded as 255, and the grayscale value of the non-final noise point is recorded as 0; and further obtaining a binary image corresponding to the difference image. In practical operation, the implementer may record the gray scale value of the final noise point as any integer value from 1 to 255.
Specifically, the method for acquiring the judgment index comprises the following steps: and calculating the ratio of the number of the noise points to the total number of the pixel points in the corresponding gray level image to obtain a noise point ratio, and obtaining a judgment index corresponding to each image information according to the sum of the reciprocal of the noise point ratio and the signal-to-noise ratio of the corresponding image information.
The signal-to-noise ratio in the image reflects the noise power of an image, the higher the illumination intensity is, the higher the signal-to-noise ratio is, and the fewer the number of noise points is; the larger the signal-to-noise ratio is, the larger the judgment index is, and the smaller the signal-to-noise ratio is, the smaller the judgment index is.
It should be noted that: the precedence order of the above embodiments of the present invention is only for description, and does not represent the merits of the embodiments. And specific embodiments thereof have been described above. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing may also be possible or may be advantageous.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the invention, and any modifications, equivalents, improvements and the like that fall within the spirit and principle of the present invention are intended to be included therein.

Claims (8)

1. A light source detection method based on image processing is characterized by comprising the following steps:
acquiring corresponding image information of a shot object under light sources of different degrees, and performing graying processing on the image information to obtain a grayscale image;
dividing each gray image into a plurality of gray image blocks with the size of m multiplied by m, calculating the mutation degree of each pixel point in each gray image block, and marking the pixel point with the mutation degree larger than the noise threshold value as an estimated noise point;
replacing the gray value of the estimated noise point in the gray image block by using the gray replacement value to obtain an estimated image block corresponding to each gray image block;
acquiring a singular value threshold corresponding to each gray image block according to the gray image block and the corresponding estimated image block;
performing singular value decomposition denoising operation on each gray image block based on the singular value to obtain a denoised image block corresponding to each gray image block;
splicing the denoising image blocks to obtain denoising images corresponding to the gray level images;
judging the number of noise points in each gray level image according to the denoised image and the corresponding gray level image; and calculating a judgment index corresponding to each image information according to the number of the noise points, wherein the light source corresponding to the maximum judgment index is the optimal light source.
2. The light source detection method based on image processing according to claim 1,
the mutation degree is:
Figure FDA0003576805770000011
wherein ,δiThe degree of the mutation of the pixel point i,
Figure FDA0003576805770000012
the gray value of the pixel point i under the light source of the v-th degree;
Figure FDA0003576805770000013
the gray value of the pixel point t under the light source of the v-th degree is shown, and the pixel point t is positioned right above the pixel point i;
Figure FDA0003576805770000014
the gray value of the pixel point u under the light source of the v-th degree is the gray value, and the pixel point u is positioned right below the pixel point i;
Figure FDA0003576805770000015
the gray value of the pixel point l under the light source of the v-th degree is shown, and the pixel point l is positioned at the left of the pixel point i;
Figure FDA0003576805770000016
the gray value of the pixel point r under the light source of the v-th degree is that the pixel point r is positioned at the right side of the pixel point i.
3. The light source detection method based on image processing according to claim 1,
the gray scale replacement value comprises a first replacement value and a second replacement value; obtaining a first coefficient according to the difference value between the gray value of the estimated noise point and the first replacement value; obtaining a second coefficient according to the difference value between the gray value of the estimated noise point and the second replacement value; and comparing the first coefficient with the second coefficient, wherein if the first coefficient is greater than the second coefficient, the first replacement value is the gray level replacement value of the estimated noise point, and if the first coefficient is less than the second coefficient, the second replacement value is the gray level replacement value of the estimated noise point.
4. The light source detection method based on image processing according to claim 3,
the first alternative value is:
Figure FDA0003576805770000017
wherein ,
Figure FDA0003576805770000021
in order to estimate the gray value of the noise point o under the light source of the v-th degree, N is the total number of pixel points in the gray image,
Figure FDA0003576805770000022
j is the total number of the gray images which are acquired again under the light source of the v degree, wherein the gray value of the pixel point corresponding to the position of the estimated noise point o in the c gray image acquired again under the light source of the v degree is the gray value of the pixel point.
5. The light source detection method based on image processing according to claim 3,
the second replacement value is:
Figure FDA0003576805770000023
wherein ,
Figure FDA0003576805770000024
to estimate the gray value of the noise point o under the light source of the v-th degree,
Figure FDA0003576805770000025
the gray value of the pixel point a under the light source of the v-th degree is the gray value of the pixel point a, and the pixel point a is positioned right above the estimated noise point o;
Figure FDA0003576805770000026
the gray value of the pixel point b under the light source of the v-th degree is the gray value, and the pixel point b is positioned right below the estimated noise point o;
Figure FDA0003576805770000027
the gray value of the pixel point e under the light source of the v-th degree is the gray value, and the pixel point e is positioned at the left of the estimated noise point o;
Figure FDA0003576805770000028
the gray value of the pixel point f under the light source of the v-th degree is that the pixel point f is positioned at the right side of the estimated noise point o.
6. The method according to claim 1, wherein the singular value threshold is obtained by: calculating the noise variance of each gray image block and the corresponding estimation image block, and determining a singular value threshold according to the noise variance;
the noise variance is:
Figure FDA0003576805770000029
wherein ,τ2In order to be the variance of the noise,
Figure FDA00035768057700000210
is a matrix corresponding to a block of gray-scale images, AxIn order to estimate the matrix corresponding to the image block,
Figure FDA00035768057700000211
is Frobenius norm.
7. The light source detection method based on image processing according to claim 1, wherein the method for judging the noise point is: calculating the absolute value of the difference value between the gray value of each pixel point in the de-noised image and the gray value of each corresponding pixel point in the gray image to obtain a difference image, judging the gray value of each pixel point in the difference image and the size of a threshold value, and marking the pixel point of which the gray value is greater than the threshold value as a noise point.
8. According toThe light source detection method based on image processing as claimed in claim 1, wherein the threshold value is obtained by:
Figure FDA00035768057700000212
wherein ,
Figure FDA00035768057700000213
in the formula ,hgAnd w is the difference value of the gray value of the estimated noise point and the gray value of the corresponding pixel point in the de-noised image, and the number of the estimated noise points.
CN202210346884.0A 2022-04-01 2022-04-01 Light source detection method based on image processing Active CN114612345B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210346884.0A CN114612345B (en) 2022-04-01 2022-04-01 Light source detection method based on image processing

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210346884.0A CN114612345B (en) 2022-04-01 2022-04-01 Light source detection method based on image processing

Publications (2)

Publication Number Publication Date
CN114612345A true CN114612345A (en) 2022-06-10
CN114612345B CN114612345B (en) 2023-05-09

Family

ID=81866055

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210346884.0A Active CN114612345B (en) 2022-04-01 2022-04-01 Light source detection method based on image processing

Country Status (1)

Country Link
CN (1) CN114612345B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115035114A (en) * 2022-08-11 2022-09-09 高密德隆汽车配件制造有限公司 Method for monitoring state of hay grinder based on image processing
CN116630425A (en) * 2023-07-21 2023-08-22 长春市天之城科技有限公司 Intelligent food detection system based on X rays
CN116664453A (en) * 2023-07-31 2023-08-29 山东中泳电子股份有限公司 PET (polyethylene terephthalate) plate detection method for swimming touch plate
CN117269193A (en) * 2023-09-26 2023-12-22 迈沐智能科技(南京)有限公司 Intelligent detection method for apparent mass of synthetic leather

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5438408A (en) * 1991-06-07 1995-08-01 Sympatec Gmbh System-Partikel-Technik Measuring device and method for the determination of particle size distributions by scattered light measurements
GB0203423D0 (en) * 1998-02-02 2002-04-03 Mann William S G Means and apparatus for acquiring, processing, and combining multiple exposures of the same scene or objects to different illuminations
JP2006094000A (en) * 2004-09-22 2006-04-06 Konica Minolta Photo Imaging Inc Image processing method, image processing apparatus, and image processing program
US20100303372A1 (en) * 2007-07-26 2010-12-02 Omron Corporation Digital image processing and enhancing system and method with function of removing noise
CN104504700A (en) * 2014-12-19 2015-04-08 成都品果科技有限公司 Method and system for obtaining noise horizontal curve of image sensor
US20150235350A1 (en) * 2014-02-18 2015-08-20 Signal Processing, Inc. Method for Image Denoising
CN105513120A (en) * 2015-12-11 2016-04-20 浙江传媒学院 Adaptive rendering method based on weight local regression
CN109410134A (en) * 2018-09-30 2019-03-01 南京信息工程大学 A kind of self-adaptive solution method based on image block classification
CN109493299A (en) * 2018-11-14 2019-03-19 杭州雄迈集成电路技术有限公司 A method of eliminating point light source illumination effect
CN110288512A (en) * 2019-05-16 2019-09-27 成都品果科技有限公司 Illumination for image synthesis remaps method, apparatus, storage medium and processor
CN110895792A (en) * 2019-10-12 2020-03-20 南方科技大学 Image splicing method and device
CN110930332A (en) * 2019-11-22 2020-03-27 河北工程大学 Artificial intelligence-based digital holographic image denoising method

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5438408A (en) * 1991-06-07 1995-08-01 Sympatec Gmbh System-Partikel-Technik Measuring device and method for the determination of particle size distributions by scattered light measurements
GB0203423D0 (en) * 1998-02-02 2002-04-03 Mann William S G Means and apparatus for acquiring, processing, and combining multiple exposures of the same scene or objects to different illuminations
JP2006094000A (en) * 2004-09-22 2006-04-06 Konica Minolta Photo Imaging Inc Image processing method, image processing apparatus, and image processing program
US20100303372A1 (en) * 2007-07-26 2010-12-02 Omron Corporation Digital image processing and enhancing system and method with function of removing noise
US20150235350A1 (en) * 2014-02-18 2015-08-20 Signal Processing, Inc. Method for Image Denoising
CN104504700A (en) * 2014-12-19 2015-04-08 成都品果科技有限公司 Method and system for obtaining noise horizontal curve of image sensor
CN105513120A (en) * 2015-12-11 2016-04-20 浙江传媒学院 Adaptive rendering method based on weight local regression
CN109410134A (en) * 2018-09-30 2019-03-01 南京信息工程大学 A kind of self-adaptive solution method based on image block classification
CN109493299A (en) * 2018-11-14 2019-03-19 杭州雄迈集成电路技术有限公司 A method of eliminating point light source illumination effect
CN110288512A (en) * 2019-05-16 2019-09-27 成都品果科技有限公司 Illumination for image synthesis remaps method, apparatus, storage medium and processor
CN110895792A (en) * 2019-10-12 2020-03-20 南方科技大学 Image splicing method and device
CN110930332A (en) * 2019-11-22 2020-03-27 河北工程大学 Artificial intelligence-based digital holographic image denoising method

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
EMMA R. HILL, ET.AL: "Identification and removal of laser-induced noise in photoacoustic imaging using singular value decomposition" *
PLENIO M B, ET.AL: "Entangled light from white noise" *

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115035114A (en) * 2022-08-11 2022-09-09 高密德隆汽车配件制造有限公司 Method for monitoring state of hay grinder based on image processing
CN116630425A (en) * 2023-07-21 2023-08-22 长春市天之城科技有限公司 Intelligent food detection system based on X rays
CN116630425B (en) * 2023-07-21 2023-09-22 长春市天之城科技有限公司 Intelligent food detection system based on X rays
CN116664453A (en) * 2023-07-31 2023-08-29 山东中泳电子股份有限公司 PET (polyethylene terephthalate) plate detection method for swimming touch plate
CN116664453B (en) * 2023-07-31 2023-10-20 山东中泳电子股份有限公司 PET (polyethylene terephthalate) plate detection method for swimming touch plate
CN117269193A (en) * 2023-09-26 2023-12-22 迈沐智能科技(南京)有限公司 Intelligent detection method for apparent mass of synthetic leather

Also Published As

Publication number Publication date
CN114612345B (en) 2023-05-09

Similar Documents

Publication Publication Date Title
CN114612345A (en) Light source detection method based on image processing
CN110210560B (en) Incremental training method, classification method and device, equipment and medium of classification network
CN115633259B (en) Automatic regulation and control method and system for intelligent camera based on artificial intelligence
CN116452598B (en) Axle production quality rapid detection method and system based on computer vision
CN112819772A (en) High-precision rapid pattern detection and identification method
CN110766657B (en) Laser interference image quality evaluation method
CN117557820B (en) Quantum dot optical film damage detection method and system based on machine vision
CN112508800A (en) Attention mechanism-based highlight removing method for surface of metal part with single gray image
JP2019508921A (en) Focus detection
CN109903245B (en) Non-uniform correction method for infrared image
CN114782329A (en) Bearing defect damage degree evaluation method and system based on image processing
CN115511907B (en) Scratch detection method for LED screen
CN115239661A (en) Mechanical part burr detection method and system based on image processing
CN113313179A (en) Noise image classification method based on l2p norm robust least square method
CN117853510A (en) Canny edge detection method based on bilateral filtering and self-adaptive threshold
CN117392464A (en) Image anomaly detection method and system based on multi-scale denoising probability model
CN114529742A (en) Image similarity determining method, device and equipment and computer readable storage medium
CN108876845B (en) Fresnel pattern center determining method and device
CN115240070A (en) Crack detection method
CN112446428B (en) Image data processing method and device
CN113920391A (en) Target counting method based on generated scale self-adaptive true value graph
CN117409275B (en) Multi-angle radar image processing method
CN112801903A (en) Target tracking method and device based on video noise reduction and computer equipment
CN116310276B (en) Target detection method, target detection device, electronic equipment and storage medium
CN110910332A (en) Dynamic fuzzy processing algorithm of visual SLAM system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right

Effective date of registration: 20230414

Address after: 201400 Room 2617, Building 2, No. 469 Fengjin Road, Fengxian District, Shanghai

Applicant after: CENTCH ELECTRONICS (SHANGHAI) Co.,Ltd.

Address before: No. 188, Fangdu Avenue, Sanxing Town, Haimen District, Nantong City, Jiangsu Province, 226112

Applicant before: Jiangsu Tongfang Internet Technology Co.,Ltd.

TA01 Transfer of patent application right
GR01 Patent grant
GR01 Patent grant