Fingerprint image acquisition method, fingerprint identification method, electronic equipment and storage medium
By controlling the light source in the under-screen fingerprint module to make the brightness code value conform to the gradient distribution, the problem of poor quality of the under-screen fingerprint image is solved, and the fingerprint unlocking rate and recognition accuracy are improved.
Patent Information
- Application Number
- CN202411191037.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-27
- Publication Date
- 2025-01-10
AI Technical Summary
The quality of fingerprint images collected by existing under-screen fingerprint modules is affected by the low brightness of the lens RI and peripheral edges, resulting in a decrease in fingerprint unlocking rate.
By controlling the light source, the brightness code value of the fingerprint acquisition area conforms to the gradient distribution, gradually increases from the center to the edge of the fingerprint acquisition area, improving the brightness of the edge position, and ensuring high-quality fingerprint image acquisition.
It improves the quality of the under-screen fingerprint image, improves the fingerprint unlocking rate, reduces interference with low peripheral brightness, and achieves higher fingerprint recognition accuracy.
Smart Images

Figure CN119296144A_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present invention relate to the field of image processing technology, and in particular to a fingerprint image acquisition method, a fingerprint recognition method, an electronic device and a storage medium. Background Art
[0002] At present, with the widespread application of fingerprint recognition technology, most electronic devices such as mobile phones and tablets are equipped with fingerprint modules (for example, under-screen fingerprint modules) to realize the collection of fingerprint images. However, the quality of fingerprint images collected by under-screen fingerprint modules is currently affected by the relative illumination (RI) of the lens. The low brightness around the fingerprint collection area leads to poor image quality around the collected fingerprint image, which ultimately leads to a decrease in the fingerprint unlocking rate. Summary of the invention
[0003] Embodiments of the present invention provide a fingerprint image acquisition method, a fingerprint recognition method, an electronic device and a storage medium to improve the image quality of an under-screen fingerprint image, thereby improving the fingerprint unlocking rate.
[0004] A first aspect of an embodiment of the present invention provides a fingerprint image acquisition method, which is applied to an electronic device, wherein the electronic device has a display screen and a fingerprint module located below the display screen, and the display screen includes a fingerprint acquisition area. The method includes:
[0005] In response to a touch operation on the fingerprint collection area, controlling the light source to light up so that the first brightness code values of multiple position points of the fingerprint collection area conform to a gradual distribution, wherein the gradual distribution means that the first brightness code value gradually increases along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area;
[0006] The fingerprint module is controlled to collect images in the fingerprint collection area to obtain a fingerprint image.
[0007] A second aspect of an embodiment of the present invention provides a fingerprint recognition method, which is applied to an electronic device, wherein the electronic device has a display screen and a fingerprint module located below the display screen, and the display screen includes a fingerprint collection area. The method includes:
[0008] Obtaining a fingerprint image, wherein the fingerprint image is obtained according to the fingerprint image acquisition method described in the first aspect of the embodiment of the present invention;
[0009] Extracting features from the fingerprint image to obtain fingerprint features;
[0010] According to the fingerprint feature, a recognition result of the fingerprint image is obtained.
[0011] A third aspect of an embodiment of the present invention provides a fingerprint image acquisition device, which is applied to an electronic device, wherein the electronic device has a display screen and a fingerprint module located below the display screen, the display screen includes a fingerprint acquisition area, and the device includes:
[0012] A region control module, configured to control the light source to light up in response to a touch operation on the fingerprint collection region, so that the first brightness code values of multiple position points in the fingerprint collection region conform to a gradual distribution, wherein the gradual distribution means that the first brightness code value gradually increases along the direction from the center of the fingerprint collection region to the edge of the fingerprint collection region;
[0013] The image acquisition module is used to control the fingerprint module to acquire images in the fingerprint acquisition area to obtain a fingerprint image.
[0014] A fourth aspect of an embodiment of the present invention provides a fingerprint recognition device, which is applied to an electronic device, wherein the electronic device has a display screen and a fingerprint module located below the display screen, wherein the display screen includes a fingerprint collection area, and the device includes:
[0015] An image acquisition module, used to obtain a fingerprint image, wherein the fingerprint image is obtained according to the fingerprint image acquisition method described in the first aspect of the embodiment of the present invention;
[0016] A feature extraction module, used to extract features from the fingerprint image to obtain fingerprint features;
[0017] The fingerprint recognition module is used to obtain the recognition result of the fingerprint image according to the fingerprint feature.
[0018] A fifth aspect of an embodiment of the present invention provides an electronic device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes, the steps of the fingerprint image acquisition method described in the first aspect of the embodiment of the present invention and / or the steps of the fingerprint recognition method described in the second aspect of the embodiment of the present invention are implemented.
[0019] A sixth aspect of an embodiment of the present invention provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the computer program implements the steps of the fingerprint image acquisition method described in the first aspect of the embodiment of the present invention, and / or implements the steps of the fingerprint recognition method described in the second aspect of the embodiment of the present invention.
[0020] In the fingerprint image acquisition method provided by the embodiment of the present invention, in response to a touch operation on a fingerprint acquisition area, the electronic device first controls the light source to light up so that the first brightness code value at the edge position of the fingerprint acquisition area of the display screen is higher than the first brightness code value at the center position to meet the gradient distribution, thereby improving the brightness at the edge position of the fingerprint acquisition area, and then controls the fingerprint module to perform image acquisition on the fingerprint acquisition area that meets the gradient distribution, so that the image acquisition is no longer affected by the low brightness around the fingerprint acquisition area, and a high-quality fingerprint image is acquired, thereby improving the image quality of the fingerprint image under the screen, and further improving the fingerprint unlocking rate. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments of the present invention will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative labor.
[0022] Figure 1 is a flow chart of a fingerprint image acquisition method according to an embodiment of the present invention;
[0023] Figure 2 It is a raw fingerprint image under different light spots proposed by an embodiment of the present invention;
[0024] Figure 3 is a schematic diagram of a first brightness code value for an R color channel proposed by an embodiment of the present invention;
[0025] Figure 4 is a schematic diagram of a first brightness code value for multiple color channels proposed by an embodiment of the present invention;
[0026] Figure 5 is a flow chart of a fingerprint recognition method according to an embodiment of the present invention;
[0027] Figure 6 is a schematic diagram of a fingerprint image acquisition device provided by an embodiment of the present invention;
[0028] Figure 7 Schematic diagram of a fingerprint recognition device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0029] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.
[0030] A first aspect of an embodiment of the present invention provides a fingerprint image acquisition method, referring to Figure 1, shows a flow chart of a fingerprint image acquisition method according to an embodiment of the present invention. The fingerprint image acquisition method proposed in the embodiment of the present invention can be applied to electronic devices, such as mobile phones, tablets, smart watches, door locks, fingerprint identifiers and other electronic devices. And the electronic device has a display screen and a fingerprint module located below the display screen, and the display screen includes a fingerprint acquisition area. Among them, the display screen can be a touch screen, and the fingerprint module can be located below the display screen, that is, the fingerprint module can be an under-screen fingerprint module. The fingerprint image acquisition method provided in the embodiment of the present invention may include the following steps:
[0031] S101, in response to a touch operation on the fingerprint collection area, controlling a light source to light up so that first brightness code values of multiple position points in the fingerprint collection area conform to a gradient distribution, wherein the gradient distribution means that the first brightness code value gradually increases along a direction from a center of the fingerprint collection area to an edge of the fingerprint collection area.
[0032] In an embodiment of the present invention, when the electronic device is in a locked screen state or when the display screen displays an interface requiring fingerprint recognition (for example, an interface for making payments or logging into an account based on the fingerprint recognition result), the user can touch the fingerprint collection area on the display screen with a finger, and the electronic device controls the light source to light up in response to the touch operation on the fingerprint collection area, so that the first brightness code values of multiple position points in the fingerprint collection area conform to the gradient distribution. For example, the touch operation in this embodiment can be the user pressing or touching the fingerprint collection area of the display screen.
[0033] Specifically, the light source may be turned on to display a light spot pattern in the fingerprint collection area, and the first brightness code values corresponding to multiple position points in the fingerprint collection area in the displayed light spot pattern conform to a gradual distribution. The gradual distribution of this embodiment means that the first brightness code value gradually increases from the center of the fingerprint collection area to the edge of the fingerprint collection area. In this embodiment, the first brightness code value is the brightness code value corresponding to the position point of the fingerprint collection area, and the brightness code value represents the brightness.
[0034] S102, controlling the fingerprint module to collect images in the fingerprint collection area to obtain a fingerprint image.
[0035] In the embodiment of the present invention, the fingerprint module is a device specifically used for fingerprint collection, and the fingerprint module is controlled to collect images of fingerprint collection areas where the first brightness code values of multiple position points conform to the gradient distribution to obtain fingerprint images.
[0036] In an embodiment of the present invention, in response to a touch operation on a fingerprint collection area, the electronic device first controls the light source to light up so that the first brightness code value at the edge position of the fingerprint collection area of the display screen is higher than the first brightness code value at the center position to comply with the gradient distribution, thereby increasing the brightness at the edge position of the fingerprint collection area, and then controls the fingerprint module to perform image collection on the fingerprint collection area that complies with the gradient distribution, so that the image collection is no longer affected by the low brightness around the fingerprint collection area, and a high-quality fingerprint image is collected, thereby improving the image quality of the fingerprint image under the screen, and further increasing the fingerprint unlocking rate.
[0037] In combination with the above embodiments, in one implementation, the present invention further provides a fingerprint image acquisition method. In the method, the light source includes at least one of the following: display pixels inside the display screen, and multiple external light sources integrated on the fingerprint module.
[0038] In an embodiment of the present invention, the light source may be a display pixel inside a display screen. When the display pixel inside the display screen is lit as a light source, a light spot pattern is generated in the fingerprint collection area on the display screen, so that the first brightness code values of multiple position points corresponding to the fingerprint collection area in the displayed light spot pattern conform to a gradient distribution.
[0039] Furthermore, the light source may be a plurality of external light sources integrated on the fingerprint module, and different external light sources may have the same or different colors, and the external light sources are arranged at different positions of the fingerprint module to illuminate different positions in the fingerprint collection area, so that when the light source is turned on, the first brightness code values of the plurality of position points in the fingerprint collection area conform to the gradient distribution. Optionally, the external light source may be a light emitting diode (LED).
[0040] In combination with the above embodiments, in one implementation, an embodiment of the present invention further provides a fingerprint image acquisition method. In this method, the above step S101 of "in response to the touch operation on the fingerprint acquisition area, controlling the light source to light up so that the first brightness code values of multiple position points in the fingerprint acquisition area conform to the gradient distribution" may specifically include the following sub-steps:
[0041] S1011, in response to a touch operation on the fingerprint collection area, read pre-stored target brightness code value information.
[0042] In the embodiment of the present invention, in response to the touch operation on the fingerprint collection area, the electronic device may first read the pre-stored target brightness code value information, and the target brightness code value information is used to obtain information of the first brightness code value that realizes the fingerprint collection area conforming to the gradient distribution. It can be understood that the target brightness code value information represents the first brightness code values of multiple position points in the fingerprint collection area along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area.
[0043] In an optional embodiment, the target brightness code value information may be first brightness code value information related to multiple position points in the fingerprint collection area along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area; the target brightness code value information may also be related information for obtaining the first brightness code values of multiple position points in the fingerprint collection area along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area.
[0044] S1012: Based on the target brightness code value information, control the light source to light up so that the first brightness code values of the plurality of position points in the fingerprint collection area conform to a gradient distribution.
[0045] In the embodiment of the present invention, after reading the target brightness code value information corresponding to the fingerprint collection area, the light source can be lit based on the target brightness code value information to display a light spot pattern that conforms to the gradient distribution in the fingerprint collection area, so that the first brightness code values of multiple position points in the fingerprint collection area conform to the gradient distribution, thereby improving the brightness of the edge position of the fingerprint collection area, so that image collection is no longer disturbed by the low brightness around the fingerprint collection area, and high-quality fingerprint image collection is achieved.
[0046] Furthermore, due to the RI problem of the lens, the amount of light entering the edge is theoretically positively correlated with the fourth power of the cosine of the CRA (Chief Ray Angle). Therefore, in order to achieve better fingerprint image imaging requirements, RI correction needs to be performed on this basis. Based on this, combined with the above embodiments, in one implementation, an embodiment of the present invention further provides a fingerprint image acquisition method. In this method, in addition to the above steps, the following steps may also be included:
[0047] S201, obtaining second brightness code values of a plurality of pixel points in an original fingerprint image corresponding to an original fingerprint collection area, wherein the original fingerprint image is obtained by the fingerprint module performing image collection on the original fingerprint collection area.
[0048] In an embodiment of the present invention, the fingerprint module can perform image acquisition on the original fingerprint acquisition area to obtain an original fingerprint image. The original fingerprint acquisition area is a fingerprint acquisition area without optimized initial gradient distribution control. The original fingerprint image includes multiple pixels, and the second brightness code value corresponding to each of the multiple pixels in the original fingerprint image can be obtained for the multiple pixels in the original fingerprint image. The second brightness code value of this embodiment is the brightness code value corresponding to the pixel of the original fingerprint image.
[0049] S202: Determine and store the target brightness code value information according to the second brightness code values of the plurality of pixels in the original fingerprint image.
[0050] In the embodiment of the present invention, after obtaining the second brightness code values corresponding to each of the multiple pixel points in the original fingerprint image, the light spot pattern at the edge corresponding to the original fingerprint collection area can be subjected to gain processing: based on the second brightness code values of the multiple pixel points in the original fingerprint image, the first brightness code values of the position points corresponding to each of the multiple pixel points in the original fingerprint collection area are adjusted, and the target brightness code value information is determined and stored. The larger the second brightness code value of a pixel point in the original fingerprint image, the smaller the first brightness code value of the position point corresponding to the pixel point in the target code value information.
[0051] In an optional embodiment, the adjustment principle may be: the larger the second brightness code value of a pixel point in the original fingerprint image, the lower the first brightness code value of the position point corresponding to the pixel point is, until the brightness of the collected fingerprint image is uniform (for example, the overall brightness is uniform), and the relevant information of the code values of multiple position points in the direction from the center to the edge of the adjusted fingerprint collection area is obtained, and the target brightness code value information is generated and stored.
[0052] like Figure 2 As shown, Figure 2 is a raw fingerprint image under different light spots proposed by an embodiment of the present invention. Figure 2 The left picture in the figure is a raw fingerprint image under a pure white spot (icon), that is, the original fingerprint image. Figure 2 The right picture in the figure is the raw fingerprint image under the gradient spot (icon) after being optimized by the method of this embodiment. Figure 2 It can be seen that the average brightness code value of the right image is significantly improved compared to the left image. Therefore, the quality of the corresponding collected fingerprint image will also be improved accordingly.
[0053] In another optional example, when adjusting the original fingerprint collection area, the minimum code value in the original fingerprint collection area can be determined, and then the minimum code value is kept unchanged, and the code value whose difference with the minimum code value is higher than the preset difference is reduced, and the code value whose difference with the minimum code value is not higher than the preset difference is increased, until the brightness of the collected fingerprint image is uniform.
[0054] In addition, it should be noted that if the light spot pattern corresponding to the fingerprint collection area is white, the corresponding RGB value is 255, 255, 255. If the color of the light spot pattern needs to be adjusted, the RGB value of the light spot pattern can only be reduced.
[0055] Further, in combination with the above embodiments, in one implementation, in order to solve the problem of storing target brightness code value information corresponding to the fingerprint collection area that conforms to the gradient distribution, if each position point in the fingerprint collection area stores a first brightness code value, a large memory space is required, and the problem of incomplete storage of full-size brightness code value information may occur due to insufficient memory. The above step S202 may specifically include sub-steps S2021 to S2023:
[0056] S2011, reading a pre-stored reference value and brightness code value adjustment amount array, wherein the brightness code value adjustment amount array includes N brightness code value adjustment amounts corresponding to the N position point groups in a one-to-one manner.
[0057] In the embodiment of the present invention, the multiple position points in the fingerprint collection area can be divided into N position point groups, the number of position points in each position point group can be the same or different, and the first brightness code value of each position point in a position point group is the same. In an optional example, the position point groups can be divided based on the distance between the position point and the center of the fingerprint collection area, and the distance between each position point in a position point group and the center of the fingerprint collection area is equal.
[0058] In the embodiment of the present invention, a brightness code value adjustment amount array is pre-stored, and the brightness code value adjustment amount array includes multiple brightness code value adjustment amounts and position point groups corresponding to each brightness code value adjustment amount, wherein the nth brightness code value adjustment amount is obtained according to the second brightness code value of a group of pixel points corresponding to the nth position point group in the original fingerprint image, and the smaller the second brightness code value of a group of pixel points in the nth position point group (i.e., the lower the brightness), the larger the corresponding adjustment amount; the brightness code value adjustment amount is the brightness code value change amount of the first brightness code value adjustment for the position point, and the N brightness code value adjustment amounts included in the brightness code value adjustment amount array correspond to the N position point groups one by one. When the first brightness code value adjustment is performed according to the original fingerprint collection area, the brightness code value adjustment amount array pre-stored for the original fingerprint collection area and the pre-stored reference value corresponding to the original fingerprint collection area can be read.
[0059] The pre-stored reference value in this embodiment is the first brightness code value of the reference position point in the original fingerprint collection area. In an optional implementation, the reference position point in the original fingerprint collection area may be the center point of the original fingerprint collection area.
[0060] S2012: Obtain a first brightness code value corresponding to the nth position point group according to the nth brightness code value adjustment amount and the reference value, where n is a natural number from 1 to N.
[0061] In this embodiment, after obtaining N brightness code value adjustment amounts, the first brightness code value corresponding to the nth position point group can be obtained according to the nth brightness code value adjustment amount among the N brightness code value adjustment amounts and the reference value, where the value of n is a natural number from 1 to N.
[0062] For example, the first position point group, the second position point group and the third position point group are respectively: the center point of the fingerprint collection area (i.e., the first position point group coincides with the reference position point), the position points of the adjacent outer circle of the center point of the fingerprint collection area (i.e., the second position point group is adjacent to the reference position point), and the position points of the adjacent outer circle of the center point of the fingerprint collection area (i.e., the third position point group is a position point group separated from the reference position point by one group). The second brightness code values corresponding to the first position point group, the second position point group and the third position point group in the original fingerprint image gradually increase. The smaller it is (that is, the brightness gradually decreases), therefore, the brightness code value adjustment amounts corresponding to the first position point group, the second position point group and the third position point group can be set to 0, 10, and 20 respectively. When the reference value is 100, the first brightness code value corresponding to the first position point group is 100+0; the brightness code value adjustment amount corresponding to the second position point group is 10, and the first brightness code value corresponding to the second position point group is 100+10; the brightness code value adjustment amount corresponding to the third position point group is 20, and the first brightness code value corresponding to the third position point group is 100+20.
[0063] S2013: Take the N first brightness code values corresponding to the N position point groups as the target brightness code value information and store them.
[0064] In the embodiment of the present invention, the target brightness code value information is the first brightness code value information related to multiple position points in the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area. Specifically, the N first brightness code values corresponding to each of the N position point groups can be obtained through the above steps, and then the N first brightness code values corresponding to each of the N position point groups are used as the target brightness code value information and stored.
[0065] In an embodiment of the present invention, the first brightness code value is no longer stored for each position point, but multiple position points are divided into multiple position point groups, and the first brightness code value of each position point in each position point group is the same, so that the first brightness code value corresponding to each position point group is stored in the form of a position point group, which greatly saves storage resources and achieves the purpose of realizing a fingerprint collection area with a gradient distribution in a local highlight mode with a small memory, thereby achieving high-quality fingerprint imaging. In combination with the above embodiments, in one implementation, in order to solve the problem of storing target brightness code value information corresponding to the fingerprint collection area that conforms to the gradient distribution, if a first brightness code value is stored for each position point in the fingerprint collection area, a larger memory space is required, and the problem of incomplete storage of full-size brightness code value information may occur due to insufficient memory. The above step S202 may specifically include sub-steps S202-1 and S202-2:
[0066] S202-1, reading the coefficients of the pre-stored polynomial for adjusting the brightness code value.
[0067] In the embodiment of the present invention, the coefficients of the polynomial for adjusting the brightness code value can be obtained and stored based on the second brightness code values of two pixels corresponding to the same position point in the original fingerprint image and the target fingerprint image. Then, when determining the target brightness code value information, the coefficients of the pre-stored polynomial corresponding to the original fingerprint collection area are read first.
[0068] In an optional implementation, the polynomial can be a linear function or a multi-time function. For example, the polynomial is: y(x) = anx n +an-1x n-1 +…+a1x+a0, where x is the location information of the location point, which represents the location value of the location point from the center of the fingerprint collection area; y(x) is the first brightness code value of the location point; an, an-1,…, a1, a0 are constants, that is, the coefficients of the polynomial.
[0069] The target fingerprint image of this embodiment may be an image whose brightness uniformity meets the target condition, wherein the brightness uniformity is the average brightness of all pixels in the image, and the target condition is that the image meets the brightness uniformity condition.
[0070] S202-2, taking the coefficients of the polynomial and the position information of the multiple position points in the fingerprint collection area as the target brightness code value information and storing them.
[0071] In this embodiment, the target brightness code value information is information related to the first brightness code values of multiple positions in the fingerprint collection area along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area. Specifically, the coefficients of the polynomial and the position information of the multiple positions in the fingerprint collection area can be used as the target brightness code value information and stored. After the target brightness code value information is read later, the first brightness code values of the multiple positions in the fingerprint collection area can be calculated based on the coefficients of the polynomial in the target brightness code value information and the position information of the multiple positions in the fingerprint collection area.
[0072] For example, for a fingerprint collection area with a pixel radius of 100, the corresponding number of pixels is 31416 pixels. If one pixel stores an 8-bit value, the storage space required is 8 bits (i.e., 1 byte), and a total of 31416 bytes are required. The polynomial fitted for the fingerprint collection area in this embodiment is: y=2x+125, where x is the distance from the position point to the center point, and y represents the first brightness code value corresponding to the position point; in this embodiment, it is actually only necessary to store the polynomial coefficients: 2 and 125, and the position information: radius 100, so a total of only 24 bits, i.e., 3 bits, are required. Compared with the method of storing the corresponding first brightness code value at each position point, the storage space is saved by 10,000 times, which greatly saves space, and realizes the reading and realization of the target brightness code value information that conforms to the gradient distribution in the highlight mode, thereby achieving the purpose of improving the image quality of the fingerprint image.
[0073] In combination with the above embodiments, in one implementation, in order to solve the problem of storing target brightness code value information corresponding to the fingerprint collection area that conforms to the gradient distribution, if each position point in the fingerprint collection area stores a first brightness code value, a large memory space is required, and the problem of storing the full-size brightness code value information may be caused by insufficient memory. The above step S202 may specifically include sub-steps S202.1 and S202.2:
[0074] S202.1, read a pre-stored target brightness code value set.
[0075] In this embodiment, a target brightness code value set is pre-stored, and the target brightness code value set is the related first brightness code value information of multiple position points obtained after adjusting the second brightness code values of multiple pixel points in the original fingerprint image. When determining the target brightness code value information, the pre-stored target brightness code value set corresponding to the fingerprint collection area is first read. Among them, the target brightness code value set includes M target brightness code values and M position point information, and the M target brightness code values correspond to the M position points in the multiple position points in the fingerprint collection area one by one, and M is a natural number, which is less than the number of the multiple position points in the fingerprint collection area, that is, M is greater than 1 and less than the total number of the multiple position points in the fingerprint collection area.
[0076] S202.2, storing the target brightness code value set as the target brightness code value information.
[0077] In an embodiment of the present invention, the target brightness code value information is the first brightness code value information related to multiple position points in the fingerprint collection area along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area. Specifically, the target brightness code value set can be used as the target brightness code value information and stored. So that after the target brightness code value information is read later, based on the M target brightness code values corresponding to each of the M position points in the target brightness code value information, the target brightness code value of the position point between the two adjacent position points can be determined by the target brightness code value of each two adjacent position points in the M position points (for example, by the linear difference method), thereby calculating the first brightness code values of the multiple position points in the fingerprint collection area.
[0078] In the embodiment of the present invention, the first brightness code value is no longer stored for each position point, but the first brightness code values of some position points are stored, and the first brightness code values of multiple position points are determined based on the first brightness code values of some position points, thereby greatly saving storage resources and achieving the purpose of realizing a gradually distributed fingerprint collection area in a local highlight mode with a small memory, thereby achieving high-quality fingerprint imaging.
[0079] In combination with the above embodiments, in one implementation, an embodiment of the present invention further provides a fingerprint image acquisition method. In this method, the first brightness code value of multiple position points conforms to the first brightness code value of at least one color channel of the fingerprint acquisition area of the gradual distribution conforms to at least one of the following conditions 1-4:
[0080] Condition 1: along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area, the first brightness code value of the i-th color channel gradually increases until it reaches a preset threshold corresponding to the i-th color channel.
[0081] In condition 1 of the embodiment of the present invention, the color channels include: R color channel, G color channel and B color channel, each of which corresponds to a respective preset threshold value, and the preset threshold value represents the maximum value of the first brightness code value. For any color channel among the three color channels, that is, the i-th color channel, along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area, the first brightness code value of the i-th color channel gradually increases until it reaches the preset threshold value corresponding to the i-th color channel.
[0082] Condition 2: In at least a portion of the edge area of the fingerprint collection area, the first brightness code value of the i-th color channel remains at a preset threshold corresponding to the i-th color channel.
[0083] In condition 2 of the embodiment of the present invention, in at least a portion of the edge region of the fingerprint collection area, the first brightness code value of the i-th color channel is maintained as a preset threshold value corresponding to the i-th color channel. The at least a portion of the edge region of the fingerprint collection area may be a portion of the area closest to the edge of the fingerprint collection area.
[0084] For example, Figure 3 As shown, Figure 3 : is a schematic diagram of a first brightness code value for the R color channel proposed by an embodiment of the present invention. Figure 3 The left picture in the figure is the gradient distribution spot diagram of the fingerprint collection area. Figure 3 The right picture in Figure 3 Schematic diagram of the first brightness code value of the R color channel corresponding to the left figure in FIG. Figure 3 The line segment in the right figure represents the R color channel (i.e., the r channel in the figure), the horizontal axis is the distance between the pixel point and the center point, and the vertical axis is the first brightness code value. It can be seen that along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area, the first brightness code value of the R color channel gradually increases until it reaches the preset threshold corresponding to the R color channel. And in at least a part of the edge area of the fingerprint collection area, the first brightness code value of the R color channel remains at the preset threshold corresponding to the R color channel.
[0085] Condition 3: the at least one color channel includes an R color channel; along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area, the first brightness code value of the R color channel remains at a preset threshold corresponding to the R color channel.
[0086] In condition 3 of the embodiment of the present invention, along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area, the first brightness code value of the R color channel is always maintained at the preset threshold corresponding to the R color channel.
[0087] Condition 4: From the center of the fingerprint collection area to the first sub-area of the fingerprint collection area, the first brightness code value of the i-th color channel gradually increases at a first growth rate, and from the first sub-area of the fingerprint collection area to the second sub-area of the fingerprint collection area, the first brightness code value of the i-th color channel gradually increases at a second growth rate, and the second sub-area is closer to the edge of the fingerprint collection area.
[0088] In condition 4 of the embodiment of the present invention, in the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area, there are at least a first sub-area and a second sub-area in sequence, and compared with the second sub-area, the first sub-area is closer to the center of the fingerprint collection area, and the second sub-area is closer to the edge of the fingerprint collection area.
[0089] From the center of the fingerprint collection area to the first sub-area of the fingerprint collection area, the first brightness code value of the i-th color channel gradually increases at a first growth rate, and from the first sub-area of the fingerprint collection area to the second sub-area of the fingerprint collection area, the first brightness code value of the i-th color channel gradually increases at a second growth rate, and the first growth rate is different from the second growth rate. Preferably, the second growth rate is greater than the first growth rate.
[0090] In another optional embodiment, in the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area, there are at least a first sub-area, a second sub-area, a third sub-area, etc., and in the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area, in two adjacent sub-areas of the fingerprint collection area, the first brightness code value of the i-th color channel gradually increases at different growth rates.
[0091] For example, Figure 4 As shown, Figure 4 is a schematic diagram of a first brightness code value for multiple color channels proposed by an embodiment of the present invention. Figure 4 The left picture in the figure is the gradient distribution spot diagram of the fingerprint collection area. Figure 4 The right picture in Figure 4 Schematic diagram of the first brightness code values of the three color channels corresponding to the left figure in FIG. Figure 4 The horizontal axis in the right figure is the distance between the pixel and the center point, and the vertical axis is the first brightness code value. It can be seen that Figure 4 The R color channel in the right figure (i.e., the r channel in the figure), along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area, its first brightness code value always remains at the preset threshold value corresponding to the R color channel; and Figure 4The G color channel and the B color channel in the right figure (i.e., the g channel and the b channel in the figure), along the center of the fingerprint collection area to the first sub-area of the fingerprint collection area, the first brightness code values of the G color channel and the B color channel both gradually increase at a first growth rate, and along the first sub-area of the fingerprint collection area to the second sub-area of the fingerprint collection area, the first brightness code values of the G color channel and the B color channel both gradually increase at a second growth rate; thereafter, the G color channel gradually increases at a third growth rate, and increases to a preset threshold value corresponding to the R color channel and then remains thereafter; after the first brightness code value of the B color channel gradually increases to the preset threshold value corresponding to the B color channel at the second growth rate, the first brightness code value of the B color channel remains at the preset threshold value corresponding to the B color channel.
[0092] Based on the same inventive concept, the second aspect of the embodiment of the present invention further proposes a fingerprint recognition method, referring to Figure 5 , shows a flow chart of a fingerprint recognition method according to an embodiment of the present invention. The fingerprint recognition method provided by the embodiment of the present invention may include the following steps:
[0093] S301, obtaining a fingerprint image, wherein the fingerprint image is obtained according to the fingerprint image acquisition method described in the first aspect of the embodiment of the present invention.
[0094] The fingerprint recognition method of the embodiment of the present invention can be applied to electronic devices, such as mobile phones, tablets, smart watches, door locks, fingerprint identifiers and other electronic devices. The electronic device has a display screen and a fingerprint module located below the display screen, and the display screen includes a fingerprint collection area. The display screen can be a touch screen, and the fingerprint module can be located below the display screen, that is, the fingerprint module can be an under-screen fingerprint module.
[0095] Specifically, the fingerprint image acquisition method described in the first aspect of the embodiment of the present invention can be used to control the light source to light up in response to the touch operation on the fingerprint acquisition area so that the first brightness code values of multiple position points in the fingerprint acquisition area conform to the gradient distribution; then, the fingerprint module is controlled to perform image acquisition on the fingerprint acquisition area to obtain a fingerprint image. The steps of the fingerprint image acquisition method in step S301 have been described in detail in the fingerprint image acquisition method provided in the first aspect of the embodiment of the present invention. The contents of the two are the same, and the technical effects achieved are the same, so they will not be repeated in this embodiment.
[0096] S302: extract features from the fingerprint image to obtain fingerprint features.
[0097] S303: Obtain a recognition result of the fingerprint image according to the fingerprint feature.
[0098] In the embodiment of the present invention, after the fingerprint image is acquired, feature extraction may be performed on the fingerprint image to obtain fingerprint features of the fingerprint image, and then a recognition result of the fingerprint image may be obtained based on the fingerprint features.
[0099] In the embodiment of the present invention, by increasing the brightness of the edge position of the fingerprint collection area, and then controlling the fingerprint module to perform image collection for the fingerprint collection area that conforms to the gradient distribution, the image collection is no longer disturbed by the low brightness around the fingerprint collection area, and a high-quality fingerprint image is collected, so that feature extraction and fingerprint recognition are performed based on the high-quality fingerprint image, thereby improving the accuracy of the fingerprint recognition result and further improving the fingerprint unlocking rate.
[0100] Based on the same inventive concept, the third aspect of the embodiment of the present invention further proposes a fingerprint image acquisition device 600. Figure 6 , Figure 6 600 is a schematic diagram of a fingerprint image acquisition device provided by an embodiment of the present invention, the fingerprint image acquisition device is applied to an electronic device, the electronic device has a display screen and a fingerprint module located below the display screen, the display screen includes a fingerprint acquisition area, the device 600 includes:
[0101] The area control module 601 is used to control the light source to light up in response to the touch operation on the fingerprint collection area, so that the first brightness code values of multiple position points in the fingerprint collection area conform to the gradient distribution, and the gradient distribution means that the first brightness code value gradually increases from the center of the fingerprint collection area to the edge of the fingerprint collection area;
[0102] The image acquisition module 602 is used to control the fingerprint module to acquire images in the fingerprint acquisition area to obtain a fingerprint image.
[0103] Optionally, the area control module 601 includes:
[0104] A first reading module, configured to read pre-stored target brightness code value information in response to a touch operation on the fingerprint collection area, wherein the target brightness code value information represents code values of a plurality of first brightness position points in a direction from a center of the fingerprint collection area to an edge of the fingerprint collection area;
[0105] The code value control module is used to control the lighting of the light source based on the target brightness code value information so that the first brightness code values of multiple position points in the fingerprint collection area conform to the gradient distribution.
[0106] Optionally, the device 600 further includes:
[0107] A code value acquisition module, used to acquire second brightness code values of a plurality of pixel points in an original fingerprint image corresponding to an original fingerprint collection area, wherein the original fingerprint image is obtained by the fingerprint module performing image acquisition on the original fingerprint collection area;
[0108] The code value determination module is used to determine and store the target brightness code value information according to the second brightness code values of multiple pixel points in the original fingerprint image, wherein the larger the second brightness code value of a pixel point, the smaller the first brightness code value of the position point corresponding to the pixel point in the target code value information.
[0109] Optionally, the plurality of position points are divided into N position point groups, and the first brightness code values of the position points in one position point group are the same; and the code value determination module includes:
[0110] A second reading module is used to read a pre-stored reference value and brightness code value adjustment amount array, wherein the brightness code value adjustment amount array includes N brightness code value adjustment amounts corresponding to the N position point groups one by one, the nth brightness code value adjustment amount is obtained according to the second brightness code value of a group of pixel points corresponding to the nth position point group in the original fingerprint image, and the reference value is the first brightness code value of the reference position point in the fingerprint collection area;
[0111] A code value adjustment module, used to obtain a first brightness code value corresponding to the nth position point group according to the nth brightness code value adjustment amount and the reference value, where n is a natural number from 1 to N;
[0112] The first storage module is used to store the N first brightness code values corresponding to the N position point groups as the target brightness code value information.
[0113] Optionally, the code value determination module includes:
[0114] A third reading module is used to read the coefficients of a pre-stored polynomial for adjusting the brightness code value, wherein the coefficients of the polynomial are obtained by fitting the second brightness code values of two pixel points corresponding to the same position point in the original fingerprint image and the target fingerprint image, and the target fingerprint image is an image whose brightness uniformity meets the target condition;
[0115] The second storage module is used to store the coefficients of the polynomial and the position information of multiple position points in the fingerprint collection area as the target brightness code value information.
[0116] Optionally, the code value determination module includes:
[0117] A fourth reading module is used to read a pre-stored target brightness code value set, wherein the target brightness code value set includes M target brightness code values corresponding to the M position points of the multiple position points one by one; the target brightness code value of each two adjacent position points of the M position points is used to determine the target brightness code value of the position point between the two adjacent position points, and M is greater than 1 and less than the total number of the multiple position points in the fingerprint collection area;
[0118] The third storage module is used to store the target brightness code value set as the target brightness code value information.
[0119] Optionally, the first brightness code values of the plurality of position points conform to the first brightness code value of at least one color channel of the fingerprint collection area of the gradual distribution and conform to at least one of the following conditions:
[0120] Along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area, the first brightness code value of the i-th color channel gradually increases until it reaches a preset threshold corresponding to the i-th color channel;
[0121] In at least a portion of the edge area of the fingerprint collection area, the first brightness code value of the i-th color channel is maintained as a preset threshold value corresponding to the i-th color channel;
[0122] The at least one color channel includes an R color channel; along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area, the first brightness code value of the R color channel is maintained as a preset threshold corresponding to the R color channel;
[0123] From the center of the fingerprint collection area to the first sub-area of the fingerprint collection area, the first brightness code value of the i-th color channel gradually increases at a first growth rate, and from the first sub-area of the fingerprint collection area to the second sub-area of the fingerprint collection area, the first brightness code value of the i-th color channel gradually increases at a second growth rate, and the second sub-area is closer to the edge of the fingerprint collection area.
[0124] Optionally, the light source includes at least one of the following: display pixels inside the display screen, and a plurality of external light sources integrated on the fingerprint module.
[0125] Based on the same inventive concept, the fourth aspect of the embodiment of the present invention further provides a fingerprint recognition device 700. Figure 7 , Figure 7 700 is a schematic diagram of a fingerprint recognition device provided by an embodiment of the present invention, the fingerprint recognition device is applied to an electronic device, the electronic device has a display screen, and a fingerprint module located below the display screen, the display screen includes a fingerprint collection area, and the device 700 includes:
[0126] An image acquisition module 701 is used to obtain a fingerprint image, where the fingerprint image is obtained according to the fingerprint image acquisition method described in the first aspect of the embodiment of the present invention;
[0127] A feature extraction module 702 is used to extract features from the fingerprint image to obtain fingerprint features;
[0128] The fingerprint recognition module 703 is used to obtain the recognition result of the fingerprint image according to the fingerprint feature.
[0129] Based on the same inventive concept, an embodiment of the present invention provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the processor implements the steps of the fingerprint image acquisition method described in the first aspect of the embodiment of the present invention, and / or implements the steps of the fingerprint recognition method described in the second aspect of the embodiment of the present invention.
[0130] Based on the same inventive concept, an embodiment of the present invention provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps of the fingerprint image acquisition method described in the first aspect of the embodiment of the present invention are implemented, and / or the steps of the fingerprint recognition method described in the second aspect of the embodiment of the present invention are implemented.
[0131] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.
[0132] It will be appreciated by those skilled in the art that the embodiments of the present invention may be provided as methods, devices, or computer program products. Therefore, the embodiments of the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the embodiments of the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.
[0133] The embodiments of the present invention are described with reference to the flowcharts and / or block diagrams of the methods, terminal devices (systems), and computer program products according to the embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of the processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable image processing terminal device to generate a machine, so that the instructions executed by the processor of the computer or other programmable image processing terminal device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0134] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable image processing terminal device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0135] These computer program instructions can also be loaded onto a computer or other programmable image processing terminal device, so that a series of operating steps are executed on the computer or other programmable terminal device to produce a computer-implemented process, so that the instructions executed on the computer or other programmable terminal device provide for implementing the process in the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0136] Although the preferred embodiments of the present invention have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the embodiments of the present invention.
[0137] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or terminal device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or terminal device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or terminal device including the elements.
[0138] The fingerprint image acquisition method, fingerprint recognition method, electronic device and storage medium provided by the present invention are introduced in detail above. The principle and implementation mode of the present invention are explained by using specific examples in this article. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. At the same time, for those skilled in the art, according to the idea of the present invention, there will be changes in the specific implementation mode and application scope. In summary, the content of this specification should not be understood as limiting the present invention.
Claims
1. A fingerprint image acquisition method, characterized in that: Applied to an electronic device, the electronic device has a display screen and a fingerprint module located below the display screen, the display screen includes a fingerprint collection area, and the method includes: In response to a touch operation on the fingerprint collection area, controlling the light source to light up so that the first brightness code values of multiple position points of the fingerprint collection area conform to a gradual distribution, wherein the gradual distribution means that the first brightness code value gradually increases along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area; The fingerprint module is controlled to collect images in the fingerprint collection area to obtain a fingerprint image.
2. The method according to claim 1, characterized in that: In response to the touch operation on the fingerprint collection area, controlling the light source to light up so that the first brightness code values of the plurality of position points of the fingerprint collection area conform to the gradient distribution includes: In response to a touch operation on the fingerprint collection area, read pre-stored target brightness code value information, wherein the target brightness code value information represents first brightness code values of a plurality of position points in a direction from a center of the fingerprint collection area to an edge of the fingerprint collection area; Based on the target brightness code value information, the light source is controlled to light up so that the first brightness code values of the plurality of position points in the fingerprint collection area conform to the gradient distribution.
3. The method according to claim 2, characterized in that The method further comprises: Acquire second brightness code values of a plurality of pixel points in an original fingerprint image corresponding to an original fingerprint collection area, wherein the original fingerprint image is obtained by the fingerprint module performing image collection on the original fingerprint collection area; The target brightness code value information is determined and stored according to the second brightness code values of multiple pixels in the original fingerprint image, wherein the larger the second brightness code value of a pixel is, the smaller the first brightness code value of the position point corresponding to the pixel in the target brightness code value information is.
4. The method according to claim 3, characterized in that The multiple position points are divided into N position point groups, and the first brightness code values of the position points in one position point group are the same; and the determining and storing the target brightness code value information according to the second brightness code values of the multiple pixel points in the original fingerprint image includes: Reading a pre-stored reference value and brightness code value adjustment array, wherein the brightness code value adjustment array includes N brightness code value adjustment amounts corresponding to the N position point groups, the nth brightness code value adjustment amount is obtained according to the second brightness code value of a group of pixel points corresponding to the nth position point group in the original fingerprint image, and the reference value is the first brightness code value of the reference position point in the fingerprint collection area; Obtaining a first brightness code value corresponding to the nth position point group according to the nth brightness code value adjustment amount and the reference value, where the value of n is a natural number from 1 to N; The N first brightness code values corresponding to the N position point groups are used as the target brightness code value information and stored.
5. The method according to claim 3, characterized in that: The step of determining and storing the target brightness code value information according to the second brightness code values of the plurality of pixels in the original fingerprint image includes: Reading coefficients of a pre-stored polynomial for adjusting brightness code values, wherein the coefficients of the polynomial are obtained by fitting the second brightness code values of two pixel points corresponding to the same position point in the original fingerprint image and the target fingerprint image, wherein the target fingerprint image is an image whose brightness uniformity meets the target condition; The coefficients of the polynomial and the position information of the multiple position points in the fingerprint collection area are used as the target brightness code value information and stored.
6. The method according to claim 3, characterized in that The step of determining and storing the target brightness code value information according to the second brightness code values of the plurality of pixels in the original fingerprint image includes: Reading a pre-stored target brightness code value set, wherein the target brightness code value set includes M target brightness code values corresponding to the M position points of the multiple position points one by one; the target brightness code value of each two adjacent position points of the M position points is used to determine the target brightness code value of the position point between the two adjacent position points, and M is greater than 1 and less than the total number of the multiple position points in the fingerprint collection area; The target brightness code value set is used as the target brightness code value information and stored.
7. The method according to any one of claims 1 to 6, characterized in that: The first brightness code values of the plurality of position points conform to the first brightness code value of at least one color channel of the fingerprint collection area of the gradual distribution and conform to at least one of the following conditions: Along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area, the first brightness code value of the i-th color channel gradually increases until it reaches a preset threshold corresponding to the i-th color channel; In at least a portion of the edge area of the fingerprint collection area, the first brightness code value of the i-th color channel is maintained as a preset threshold value corresponding to the i-th color channel; The at least one color channel includes an R color channel; along the direction from the center of the fingerprint collection area to the edge of the fingerprint collection area, the first brightness code value of the R color channel is maintained as a preset threshold corresponding to the R color channel; From the center of the fingerprint collection area to the first sub-area of the fingerprint collection area, the first brightness code value of the i-th color channel gradually increases at a first growth rate, and from the first sub-area of the fingerprint collection area to the second sub-area of the fingerprint collection area, the first brightness code value of the i-th color channel gradually increases at a second growth rate, and the second sub-area is closer to the edge of the fingerprint collection area.
8. The method according to any one of claims 1 to 7, characterized in that: The light source includes at least one of the following: display pixels inside the display screen, and a plurality of external light sources integrated on the fingerprint module.
9. A fingerprint recognition method, characterized in that: Applied to an electronic device, the electronic device has a display screen and a fingerprint module located below the display screen, the display screen includes a fingerprint collection area, and the method includes: Obtaining a fingerprint image, wherein the fingerprint image is obtained according to the fingerprint image acquisition method according to any one of claims 1 to 8; Extracting features from the fingerprint image to obtain fingerprint features; According to the fingerprint feature, a recognition result of the fingerprint image is obtained.
10. An electronic device, characterized in that: The invention comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein when the processor is executed, the steps of the fingerprint image acquisition method described in any one of claims 1 to 8 and / or the steps of the fingerprint recognition method described in claim 9 are implemented.
11. A computer-readable storage medium, characterized in that: A computer program / instruction is stored, and when the computer program / instruction is executed by a processor, the steps in the fingerprint image acquisition method described in any one of claims 1 to 8 and / or the steps in the fingerprint recognition method described in claim 9 are implemented.