Disclosure of Invention
The technical problem to be solved by the invention is as follows: provided are an efficient iris recognition method and device.
The solution of the invention for solving the technical problem is as follows:
an efficient iris recognition method comprises the following steps:
step 100, collecting a plurality of human eye images, and defining the collected human eye images as initial images;
step 200, judging whether the initial image meets the identification requirement, and deleting the initial image which does not meet the identification requirement;
step 300, performing image preprocessing operation on the initial image;
step 400, obtaining an iris area in each initial image, and segmenting the iris area from the initial images to obtain a plurality of images to be detected;
and 500, identifying and matching the plurality of images to be detected with prestored iris images stored in a database.
As a further improvement of the above technical solution, step 200 includes the following steps:
step 210, judging whether the definition of each initial image meets the requirement, and deleting the initial images with insufficient definition;
step 220, judging whether each initial image has an iris area, and deleting the initial images without the iris area and the initial images with insufficient iris area.
As a further improvement of the above technical solution, step 210 includes the following steps:
step 211, performing image graying processing on the initial image;
step 212, performing image segmentation operation on the initial image by using a watershed algorithm to obtain a plurality of inspection areas;
step 213, calculating the area of each inspection area;
step 214, setting an area threshold and a quantity threshold, counting the quantity of the inspection regions smaller than the area threshold according to the area size of each inspection region, and if the quantity is larger than the quantity threshold, determining that the definition of the initial image is insufficient;
in step 215, the original image with insufficient sharpness is deleted.
As a further improvement of the above technical solution, step 220 includes the following steps:
step 221, performing gaussian filtering processing on the initial image;
step 222, performing image graying processing on the initial image;
step 223, performing edge detection on the initial image, calculating the gradient of the initial image, and determining the circumferential line of the iris area in the initial image;
step 224, drawing all gradient straight lines in the initial image in a two-dimensional Hough space;
step 225, identifying the point with the maximum intersection frequency of each gradient straight line, and taking the point as the center of a circle of an iris area in the initial image;
step 226, calculating the distance from the circle center to the circumference, and taking the distance as the radius of the iris area in the initial image;
step 227, setting a standard threshold, judging whether the radius of the iris area in the initial image is smaller than the standard threshold, and if so, deleting the initial image.
The invention also discloses an iris recognition device, which comprises:
the acquisition module is used for acquiring a plurality of human eye images and defining the acquired human eye images as initial images;
the image deleting module is used for judging whether the initial image meets the identification requirement or not and deleting the initial image which does not meet the identification requirement;
the preprocessing module is used for carrying out image preprocessing operation on the initial image;
the segmentation module is used for acquiring the iris area in each initial image and segmenting the iris area from the initial image to obtain a plurality of images to be detected;
and the matching module is used for identifying and matching the plurality of images to be detected with prestored iris images stored in the database.
As a further improvement of the above technical solution, the image deleting module includes:
the first deleting unit is used for judging whether the definition of each initial image meets the requirement or not and deleting the initial images with insufficient definition;
and the second deleting unit is used for judging whether the iris area exists in each initial image or not and deleting the initial image without the iris area and the initial image with the insufficient iris area.
As a further improvement of the above technical solution, the first deleting unit includes:
the first gray processing unit is used for carrying out image graying processing on the initial image;
the image segmentation unit is used for carrying out image segmentation operation on the initial image by utilizing a watershed algorithm to obtain a plurality of inspection areas;
the area calculation unit is used for calculating the area of each inspection area;
a first input unit for setting an area threshold value and a number threshold value;
the statistical unit is used for counting the number of the inspection regions smaller than the area threshold value according to the area size of each inspection region;
the first judging unit is used for judging whether the initial image meets the definition requirement according to the number of the detection areas in the initial image, wherein the area of the detection areas is smaller than the area threshold, and if the number is larger than the number threshold, the definition of the initial image is determined to be insufficient;
and the first clearing unit is used for deleting the initial image with insufficient definition.
As a further improvement of the above technical solution, the second deleting unit includes:
the filtering unit is used for carrying out Gaussian filtering processing on the initial image;
the second gray processing unit is used for carrying out image gray processing on the initial image;
a circumference line determining unit, configured to perform edge detection on the initial image, calculate a gradient of the initial image, and determine a circumference line of an iris region in the initial image;
the system comprises a drawing unit, a calculating unit and a calculating unit, wherein the drawing unit is used for drawing all gradient straight lines in an initial image in a two-dimensional Hough space;
the circle center identification unit is used for identifying the point with the maximum intersection frequency of the gradient straight lines, and taking the point as the circle center of the iris area in the initial image;
the radius calculation unit is used for calculating the distance from the circle center to the circumference line, and taking the distance as the radius of the iris area in the initial image;
a second input unit for setting a standard threshold;
the second judging unit is used for judging whether the radius of the iris area in the initial image is smaller than a standard threshold value or not;
and the second clearing unit is used for deleting the initial image with the iris area radius smaller than the standard threshold.
The invention has the beneficial effects that: before iris extraction and identification matching are carried out on the initial image, a deleting step is introduced, and the initial image which does not meet the identification requirement is deleted, so that the calculation amount caused by subsequent identification matching on the initial image is greatly reduced, and the identification efficiency of the iris identification process is improved.
Detailed Description
The conception, the specific structure and the technical effects of the present invention will be clearly and completely described below in conjunction with the embodiments and the accompanying drawings to fully understand the objects, the features and the effects of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present application, and not all embodiments, and other embodiments obtained by those skilled in the art without inventive efforts based on the embodiments of the present application belong to the protection scope of the present application.
Referring to fig. 1, the present application discloses an efficient iris recognition method, a first embodiment of which includes the steps of:
step 100, collecting a plurality of human eye images, and defining the collected human eye images as initial images;
step 200, judging whether the initial image meets the identification requirement, and deleting the initial image which does not meet the identification requirement;
step 300, performing image preprocessing operation on the initial image, thereby providing the image quality of the initial image and the accuracy of image matching identification in subsequent operation;
step 400, obtaining an iris area in each initial image, and segmenting the iris area from the initial images to obtain a plurality of images to be detected;
and 500, identifying and matching the plurality of images to be detected with prestored iris images stored in a database.
Specifically, compared with the prior art, the embodiment is mainly distinguished in that a deletion step is introduced, and the initial image which does not meet the identification requirement is deleted, so that the subsequent identification and matching of the initial image is greatly reduced, the calculation amount is reduced, and the identification efficiency of the iris identification process is improved.
Further as a preferred implementation manner, the identification requirement in step 200 of this embodiment includes that the initial image is required to simultaneously satisfy two requirements of sufficient definition and a sufficiently large iris area, and it is considered that, in practical application, in the process of acquiring an image of a human eye, a target person may be far away from a human eye acquisition instrument or a body may shake, so as to affect the image acquisition quality. Step 200 in this embodiment includes the following steps:
step 210, judging whether the definition of each initial image meets the requirement, and deleting the initial images with insufficient definition;
step 220, judging whether each initial image has an iris area, and deleting the initial images without the iris area and the initial images with insufficient iris area.
Further as a preferred implementation manner, step 210 in this embodiment includes the following steps:
step 211, performing image graying processing on the initial image;
step 212, performing image segmentation operation on the initial image by using a watershed algorithm to obtain a plurality of inspection areas;
step 213, calculating the area of each inspection area;
step 214, setting an area threshold and a quantity threshold, counting the quantity of the inspection regions smaller than the area threshold according to the area size of each inspection region, and if the quantity is larger than the quantity threshold, determining that the definition of the initial image is insufficient;
in step 215, the original image with insufficient sharpness is deleted.
Specifically, the embodiment specifically implements a definition calculation function based on a watershed algorithm, the initial image is segmented into a plurality of inspection regions by using the watershed algorithm, and for an image with blurriness and lower definition, the inspection regions with smaller areas obtained after segmentation are more, that is, the number of the inspection regions with areas lower than an area threshold is used as a basis for judging the definition of the initial image, so that the judgment accuracy is high, the computation amount is low, and the computation efficiency of the entire iris identification process is not affected.
Of course, in order to further improve the operation efficiency of the iris identification process, step 210 in this embodiment further includes step 215, arranging each of the initial images according to the sharpness of the initial image, and retaining a plurality of initial images with the highest sharpness.
Further as a preferred implementation manner, step 220 in this embodiment includes the following steps:
step 221, performing gaussian filtering processing on the initial image;
step 222, performing image graying processing on the initial image;
step 223, performing edge detection on the initial image, calculating the gradient of the initial image, and determining the circumferential line of the iris area in the initial image;
step 224, drawing all gradient straight lines in the initial image in a two-dimensional Hough space;
step 225, identifying the point with the maximum intersection frequency of each gradient straight line, and taking the point as the center of a circle of an iris area in the initial image;
step 226, calculating the distance from the circle center to the circumference, and taking the distance as the radius of the iris area in the initial image;
step 227, setting a standard threshold, judging whether the radius of the iris area in the initial image is smaller than the standard threshold, and if so, deleting the initial image.
The application also discloses an iris recognition device simultaneously, and its first embodiment includes:
the acquisition module is used for acquiring a plurality of human eye images and defining the acquired human eye images as initial images;
the image deleting module is used for judging whether the initial image meets the identification requirement or not and deleting the initial image which does not meet the identification requirement;
the preprocessing module is used for carrying out image preprocessing operation on the initial image;
the segmentation module is used for acquiring the iris area in each initial image and segmenting the iris area from the initial image to obtain a plurality of images to be detected;
and the matching module is used for identifying and matching the plurality of images to be detected with prestored iris images stored in the database.
Further preferably, in this embodiment, the image deleting module includes:
the first deleting unit is used for judging whether the definition of each initial image meets the requirement or not and deleting the initial images with insufficient definition;
and the second deleting unit is used for judging whether the iris area exists in each initial image or not and deleting the initial image without the iris area and the initial image with the insufficient iris area.
Further preferably, in this embodiment, the first deleting unit includes:
the first gray processing unit is used for carrying out image graying processing on the initial image;
the image segmentation unit is used for carrying out image segmentation operation on the initial image by utilizing a watershed algorithm to obtain a plurality of inspection areas;
the area calculation unit is used for calculating the area of each inspection area;
a first input unit for setting an area threshold value and a number threshold value;
the statistical unit is used for counting the number of the inspection regions smaller than the area threshold value according to the area size of each inspection region;
the first judging unit is used for judging whether the initial image meets the definition requirement according to the number of the detection areas in the initial image, wherein the area of the detection areas is smaller than the area threshold, and if the number is larger than the number threshold, the definition of the initial image is determined to be insufficient;
and the first clearing unit is used for deleting the initial image with insufficient definition.
Of course, in order to further improve the operation efficiency of the iris identification process, in this embodiment, the first deleting unit further includes a sorting unit, configured to sort each initial image according to the definition of the initial image, and retain a plurality of initial images with the highest definition.
Further preferably, in this embodiment, the second deleting unit includes:
the filtering unit is used for carrying out Gaussian filtering processing on the initial image;
the second gray processing unit is used for carrying out image gray processing on the initial image;
a circumference line determining unit, configured to perform edge detection on the initial image, calculate a gradient of the initial image, and determine a circumference line of an iris region in the initial image;
the system comprises a drawing unit, a calculating unit and a calculating unit, wherein the drawing unit is used for drawing all gradient straight lines in an initial image in a two-dimensional Hough space;
the circle center identification unit is used for identifying the point with the maximum intersection frequency of the gradient straight lines, and taking the point as the circle center of the iris area in the initial image;
the radius calculation unit is used for calculating the distance from the circle center to the circumference line, and taking the distance as the radius of the iris area in the initial image;
a second input unit for setting a standard threshold;
the second judging unit is used for judging whether the radius of the iris area in the initial image is smaller than a standard threshold value or not;
and the second clearing unit is used for deleting the initial image with the iris area radius smaller than the standard threshold.
While the preferred embodiments of the present invention have been described in detail, it should be understood that the invention is not limited to those precise embodiments, and that various changes and modifications may be effected therein by one skilled in the art without departing from the scope or spirit of the invention as defined in the appended claims.