Image processing method, device, apparatus and storage medium

By expanding the field of view of the image acquisition component, the target face image in the environmental image is identified and extracted, which solves the problem of low payment efficiency caused by the user adjusting the position, and achieves the effect of simplifying operation and improving payment efficiency.

CN114255494BActive Publication Date: 2025-10-24TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202011014067.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-09-24
Publication Date
2025-10-24
Estimated Expiration
2040-10-25

AI Technical Summary

Technical Problem

During facial recognition payment, users need to adjust their position relative to the terminal camera to ensure that their facial image is displayed in the scanning frame, resulting in low payment efficiency.

Method used

The system uses an image acquisition component to obtain environmental images with a field of view larger than that of a single standard lens. It identifies and extracts the image region of the target face, displays the face image, and simplifies user operation.

Benefits of technology

It acquires complete facial images without requiring users to consciously adjust their standing position and posture, simplifying the operation process, improving payment efficiency, and ensuring the accuracy of facial recognition.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114255494B_ABST
    Figure CN114255494B_ABST
Patent Text Reader

Abstract

The application discloses an image processing method and device, equipment and storage medium, which are applied to face payment equipment and belong to the computer vision technical field of artificial intelligence. The method comprises the following steps: acquiring an environment image through an image acquisition component; identifying a target face contained in the environment image; extracting an image region containing the target face from the environment image to obtain a face image of the target face; and displaying the face image of the target face. In the application, the integrity of the face image is ensured, the user operation is simplified, the operation efficiency is improved, the face image of the target face is extracted, the situation that the target face is too small in the environment image to cause subsequent face recognition inconvenience is avoided, the face image of the target face is extracted from the environment image, the influence of unnecessary content in the environment image on face recognition is effectively removed, the problem that the face in the environment image is too small is solved, and the accuracy of subsequent face recognition can be effectively ensured.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of computer vision of artificial intelligence, and particularly relates to an image processing method and device, equipment and a storage medium. BACKGROUND

[0002] At present, the application range of face payment is wider and wider. In the payment process, the user can complete payment through face payment.

[0003] In the related technology, when the user pays, the user can click a payment button of a terminal display interface and select a face payment mode, and then a face scanning frame is displayed in the terminal display interface. The user adjusts the positional relationship between the user and a terminal camera, so that the position of the face of the user corresponds to the face scanning frame. At this time, the face scanning frame of the terminal display interface includes a face image. After the face image scanning is completed and verified, a deduction operation is performed from a user account corresponding to the face image, and the user payment is completed.

[0004] However, in the face payment process in the related technology, the user needs to adjust the position between the user and the terminal camera to ensure that the face image is displayed in the face scanning frame, which leads to low efficiency of completing payment. SUMMARY

[0005] Embodiments of the present application provide an image processing method, device, equipment and storage medium, which can simplify user operation and improve operation efficiency while ensuring the integrity of the face image. The technical solution is as follows:

[0006] According to an aspect of an embodiment of the present application, an image processing method is provided, applied to a face payment device, and the method comprises:

[0007] An environment image is acquired by an image acquisition component, and the angle of view range of the image acquisition component is greater than that of a single standard lens.

[0008] A target face contained in the environment image is identified.

[0009] An image region containing the target face is extracted from the environment image to obtain a face image of the target face.

[0010] The face image of the target face is displayed.

[0011] According to an aspect of an embodiment of the present application, an image processing device is provided, and the device comprises:

[0012] An image acquisition module is configured to acquire an environment image by an image acquisition component, and the angle of view range of the image acquisition component is greater than that of a single standard lens.

[0013] The face recognition module is configured to recognize a target face contained in the environment image.

[0014] The region extraction module is configured to extract an image region containing the target face from the environment image to obtain a face image of the target face.

[0015] The face display module is configured to display the face image of the target face.

[0016] Optionally, the face recognition module comprises:

[0017] The face acquisition unit is configured to recognize a face contained in the environment image.

[0018] The attribute acquisition unit is configured to, in a case where the number of faces is greater than 1, acquire attribute information of each face, the attribute information being used to indicate an attribute feature of the face.

[0019] The face recognition unit is configured to determine the target face from the environment image based on the attribute information of each face.

[0020] Optionally, the face recognition unit is configured to, in a case where the attribute information comprises a face distance, determine a face with the smallest face distance as the target face, wherein the face distance refers to a distance between the face and the face payment device; or, in a case where the attribute information comprises a face position, determine a face with a position closest to a central position of the environment image as the target face, wherein the face position refers to a position of the face in the environment image; or, in a case where the attribute information comprises a face posture, determine a face with a posture of facing the face payment device as the target face, wherein the face posture refers to a relative posture between the face and the face payment device; or, in a case where the attribute information comprises a face size, determine a face with the largest face size as the target face, wherein the face size refers to a size of a minimum rectangular frame corresponding to the face; or, in a case where the attribute information comprises a face expression, determine a face with a specified expression as the target face.

[0021] Optionally, the face recognition module comprises:

[0022] The distance acquisition unit is configured to, in a case where the number of faces is greater than 1, acquire a face distance of each face, the face distance referring to a distance between the face and the face payment device.

[0023] The candidate acquisition unit is configured to determine a face with a face distance less than a threshold value as a candidate face.

[0024] The face recognition unit is configured to: if the number of the candidate faces is equal to 1, determine the candidate face as the target face; and if the number of the candidate faces is greater than 1, perform the step of determining the target face from the environment image based on attribute information of each of the candidate faces.

[0025] Optionally, the region extraction module comprises:

[0026] The region cropping unit is configured to: crop, based on a preset cropping size and a preset cropping shape, an image region containing the target face in the environment image to obtain a face image of the target face; or determine a cropping size and a cropping shape according to a size of the image region containing the target face; and crop, based on the cropping size and the cropping shape, the image region containing the target face in the environment image to obtain the face image of the target face.

[0027] Optionally, the region cropping unit is configured to: determine a position of a first face feature point in the image region containing the target face, the first face feature point being a feature point closest to a center position of the target face; and crop, based on the preset cropping size and the preset cropping shape, the image region containing the target face in the environment image with the first face feature point as the center to obtain the face image of the target face.

[0028] Optionally, the image acquisition module is configured to: acquire, by the image acquisition component, a to-be-processed video stream, the to-be-processed video stream comprising at least two images; acquire a quality score of each of the images, the quality score being positively correlated with an imaging effect of the image; and determine an image with the largest quality score as the environment image to be recognized.

[0029] Optionally, the face display module is configured to: in a case where the number of the target faces is greater than 1, display each of the target faces; and in response to a selection operation on a first target face, display a face image of the first target face.

[0030] Optionally, the image acquisition component comprises at least one camera with a wide-angle lens; or the image acquisition component comprises a plurality of cameras with standard lenses.

[0031] According to an aspect of an embodiment of the present application, there is provided a face payment device, comprising a processor and a memory, the memory storing at least one instruction, at least one program, a code set or an instruction set, the at least one instruction, the at least one program, the code set or the instruction set being loaded and executed by the processor to implement the image processing method described above.

[0032] According to one aspect of an embodiment of the present application, a computer-readable storage medium is provided, in which at least one instruction, at least one program, a code set or an instruction set is stored. The at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by a processor to implement the above-mentioned image processing method.

[0033] According to one aspect of an embodiment of the present application, a computer program product or computer program is provided, comprising computer instructions stored in a computer-readable storage medium. A processor of a facial recognition payment device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the facial recognition payment device to perform the above-described image processing method.

[0034] The technical solutions provided in the embodiments of the present application can bring the following beneficial effects:

[0035] The environmental image is acquired through the image acquisition component. Since the viewing angle of the image acquisition component is greater than that of a single standard lens, the image acquisition range is expanded. When the image acquisition component acquires the face image, the user does not need to deliberately adjust the standing position and posture to obtain the complete face image. While ensuring the integrity of the face image, the user operation is simplified and the operation efficiency is improved. Moreover, the image area containing the target face is extracted from the environmental image to obtain the face image of the target face. That is to say, when the face in the environmental image is small due to the large viewing angle of the image acquisition component, the face image of the target face is extracted to avoid the situation where the target face accounts for too small a proportion in the environmental image, resulting in inconvenience in subsequent face recognition. The face image of the target face is extracted from the environmental image, effectively removing the influence of unnecessary content in the environmental image on face recognition, solving the problem of the face being too small in the environmental image, and effectively ensuring the accuracy of subsequent face recognition. BRIEF DESCRIPTION OF THE DRAWINGS

[0036] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0037] Figure 1 This is a schematic diagram of a face-scanning payment device provided by an embodiment of the present application;

[0038] Figure 2 is a flowchart of an image processing method provided by an embodiment of the present application;

[0039] Figure 3An exemplary schematic diagram showing a single standard lens and the perspective range difference of an image acquisition component is shown;

[0040] Figure 4 An exemplary schematic diagram showing an environment image of users with different heights is shown;

[0041] Figure 5 An exemplary flow chart showing a target face recognition mode is shown;

[0042] Figure 6 An exemplary flow chart showing another target face recognition mode is shown;

[0043] Figure 7 A flow chart of an image processing method provided by another embodiment of the present application is shown;

[0044] Figure 8 An exemplary schematic diagram showing the display mode of a target face under different conditions is shown;

[0045] Figure 9 An exemplary schematic diagram showing a payment flow is shown;

[0046] Figure 10 A block diagram of an image processing device provided by an embodiment of the present application is shown;

[0047] Figure 11 A block diagram of an image processing device provided by another embodiment of the present application is shown;

[0048] Figure 12 A structural block diagram of a face payment device provided by an embodiment of the present application is shown. DETAILED DESCRIPTION

[0049] In order to make the purpose, technical solutions and advantages of the present application clearer, the embodiments of the present application will be further described in detail below with reference to the drawings.

[0050] Artificial intelligence (AI) is to use digital computers or digital computer controlled machines to simulate, extend and expand human intelligence, perceive environment, acquire knowledge and use knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology of computer science, which tries to understand the essence of intelligence and produce a new intelligent machine that can react in a similar way to human intelligence. Artificial intelligence is to study the design principles and implementation methods of various intelligent machines, so that machines have the functions of perception, reasoning and decision-making.

[0051] Artificial intelligence technology is a comprehensive discipline, involving a wide range of fields, both hardware and software level technology. Artificial intelligence basic technology generally includes, such as sensors, special artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation / interaction system, mechatronics and other technologies. Artificial intelligence software technology mainly includes computer vision technology, speech processing technology, natural language processing technology and machine learning / deep learning and other fields.

[0052] Computer vision (CV) Computer vision is a science that studies how to make machines "see". Further, it refers to using cameras and computers to replace human eyes to identify, track and measure targets, and further process graphics so that the computer processing becomes more suitable for human eye observation or image transmission to instrument detection. As a scientific discipline, computer vision researches related theories and technologies, trying to establish artificial intelligence systems that can obtain information from images or multidimensional data. Computer vision technology usually includes image processing, image recognition, image semantic understanding, image retrieval, OCR, video processing, video semantic understanding, video content / behavior recognition, three-dimensional object reconstruction, 3D technology, virtual reality, augmented reality, simultaneous localization and mapping, and other technologies. It also includes common face recognition, fingerprint recognition and other biometric identification technologies.

[0053] With the research and progress of artificial intelligence technology, artificial intelligence technology has been researched and applied in many fields, such as common smart home, smart wearable devices, virtual assistants, smart speakers, smart marketing, unmanned vehicles, autonomous vehicles, drones, robots, smart medical care, smart customer service, etc. It is believed that with the development of technology, artificial intelligence technology will be applied in more fields and play an increasingly important role.

[0054] The scheme provided by the embodiments of the present application relates to computer vision and other technologies of artificial intelligence. The face payment device acquires an environment image by using an image acquisition component, extracts an image region containing a target face from the environment image, obtains a face image of the target face, further performs face recognition on the face image of the target face, determines a user payment account corresponding to the face image, and deducts a user corresponding to be paid amount from the user payment account. It should be noted that in the embodiments of the present application, after obtaining the face image of the target face, the recognition operation on the face image and the deduction operation on the user payment account can be performed by the face payment device, or can be performed by the background server corresponding to the face payment device. The embodiments of the present application do not limit this.

[0055] Please refer to Figure 1Fig. 1 shows a face payment device 10 according to an embodiment of the present application.

[0056] The image acquisition component 11 is configured to acquire an environment image. Optionally, the image acquisition component 11 can include, but is not limited to, at least one of the following: a camera, a video camera, a face scanner, and the like. In the embodiment of the present application, in order to ensure that the environment image can include a complete face, the image acquisition component 11 needs to be provided with a sufficient shooting range, so that the environment image can accommodate the faces of users of different heights or different positions without the need for the user to deliberately adjust. Optionally, the image acquisition component 11 is configured to acquire an environment image within an ultra-wide angle view range. For example, the image acquisition component 11 includes an image acquisition device with a view range greater than a preset threshold. It should be noted that the image acquisition component 11 can include one or more image acquisition devices, which are not limited in the embodiment of the present application. If the image acquisition component 11 includes multiple image acquisition devices, the multiple image acquisition devices can be of the same type or of different types.

[0057] In a possible implementation, the image acquisition component 11 includes at least one lens with a view range greater than the above-mentioned preset threshold. For example, the image acquisition component 11 includes at least one camera with a wide-angle lens. In another possible implementation, the image acquisition component 11 includes multiple lenses, so that the view range of the image acquisition component 11 is greater than the preset threshold. For example, the image acquisition component 11 includes multiple cameras with standard lenses. Of course, in other possible implementations, the image acquisition component 11 can also adjust the shooting angle of the lens, so that the view range of the image acquisition component 11 is greater than the preset threshold.

[0058] The face payment device 10 is configured to extract and display a face image from the environment image. Optionally, the face payment device can be an electronic device such as a mobile phone, a mobile phone, a tablet computer, a game console, an e-book reader, a multimedia playback device, a wearable device, a PC (Personal Computer), a self-service payment machine, and the like. The face payment device 10 can install a client of an application program. The application program can be any application program with a payment function, or any application program capable of calling a payment function, such as a payment application program, a purchase application program, a social application program, an online application program of a merchant, and the like. Optionally, the application program can be a downloaded and installed application program, or an instant application program.

[0059] In the embodiments of the present application, the image acquisition component 11 can be arranged in the face payment device 10, for example, the image acquisition component 11 is a hardware component part of the face payment device 10; or the image acquisition component 11 and the face payment device 10 can also be connected through a network.

[0060] The preset threshold value is a numerical value set by the staff according to actual experience, which can be 100°, 110° or 120°, etc., and the embodiments of the present application are not limited to this. Of course, in actual application, after the preset threshold value is set, the staff can also change the preset threshold value according to the actual situation. Alternatively, the staff can change the preset threshold value by replacing the image acquisition component 11. In one possible implementation, the staff can manually replace the image acquisition component corresponding to the face payment device 10, and replace the current image acquisition component 11 with a new image acquisition component 11, so as to change the preset threshold value. In another possible implementation, the staff can send a threshold modification instruction to the face payment device 10, and further, the face payment device 10 can search and connect the image acquisition component 11 that meets the updated preset threshold value in the preset range according to the updated preset threshold value in the threshold modification instruction. The preset range refers to the surrounding area of the face payment device 10, and the image acquisition direction of each image acquisition component in the preset range is the same as the screen display direction of the face payment device 10.

[0061] Alternatively, in the embodiments of the present application, the face payment device 10 further includes a display screen 12, which is used to display the content corresponding to the face payment device 10 to the user. For example, the display screen 12 can display the environment image, the face image of the target face, and the process of the environment image, etc.

[0062] Please refer to Figure 2 which shows a flowchart of an image processing method provided by an embodiment of the present application. The method can be applied to Figure 1 The face payment device 20 in the face payment system shown in the figure, for example, the execution subject of each step can be the face payment device 20. The method can include the following steps (201-204):

[0063] Step 201, acquiring an environment image through an image acquisition component.

[0064] The image acquisition component is used to acquire an environment image from the surrounding environment of the face payment device. Optionally, the image acquisition component can include but is not limited to at least one of the following: a camera, a video camera, a face scanner, etc. In the embodiments of the present application, the angle of view range of the image acquisition component is greater than the angle of view range of a single standard lens, such as Figure 3As shown, the viewing angle range of a single standard lens is a first viewing angle range 31, and the viewing angle range of the image acquisition component is a second viewing angle range 32, wherein the first viewing angle range 31 is smaller than the second viewing angle range 32. Optionally, the image acquisition component includes at least one camera with a wide-angle lens; or, the image acquisition component includes multiple cameras with standard lenses. The viewing angle range of the wide-angle lens is larger than the viewing angle range of the standard lens. Optionally, a wide-angle lens refers to a lens with a viewing angle range greater than a first threshold value, and a standard lens refers to a lens with a viewing angle range less than a second threshold value. Both the first threshold value and the second threshold value can be flexibly set according to actual conditions, and the first threshold value is greater than or equal to the second threshold value. For example, when the first threshold value is equal to the second threshold value, the first threshold value can be 100°, 110°, or 120°, etc., which is not limited in this embodiment of the present application.

[0065] The environmental image refers to the image around the face-scanning payment device. Optionally, in order to ensure that the target face is included in the environmental image, the environmental image may be an image of the surrounding environment in front of the display screen of the face-scanning payment device. In an embodiment of the present application, in order to reduce processing overhead, the face-scanning payment device may start the image acquisition component after receiving the face-scanning payment instruction, and obtain the environmental image through the image acquisition component. Among them, the face-scanning payment instruction may be an instruction triggered by the user through the face-scanning payment control, and the face-scanning payment control may be displayed on the display screen of the face-scanning payment device. Optionally, the user may trigger the above-mentioned face-scanning payment instruction by clicking on the face-scanning payment control or pressing the corresponding key. It should be noted that in an embodiment of the present application, the viewing angle range of the image acquisition component is greater than the viewing angle range of a single standard lens, so that the image acquisition component can capture the faces of users of different heights. For example, if Figure 4 As shown, for a user 41 with a taller height (such as a height of 1.9 meters), in the environmental image captured by the image acquisition component, the face of the user 41 is located in the top area 42 of the environmental image; for a user 43 with a shorter height (such as a height of 1.3 meters), in the environmental image captured by the image acquisition component, the face of the user 43 is located in the bottom area 44 of the environmental image.

[0066] In one possible implementation, the image acquisition component is connected to the face-scanning payment device via hardware. For example, the image acquisition component is a hardware component of the face-scanning payment device, or the image acquisition component is connected to the face-scanning payment device via a data cable.

[0067] In another possible implementation, the image acquisition component is connected to the facial payment device through a network. Optionally, the surrounding area of the facial payment device is provided with multiple image acquisition components of different types. The different types of image acquisition components correspond to different ranges of view angles. It should be noted that the range of view angle of any type of image acquisition component is greater than that of a single standard lens.

[0068] In a possible implementation, after obtaining the facial payment instruction, the facial payment device searches and activates the image acquisition component with the largest range of view angle from the image acquisition components of different types to ensure the integrity of the environment image, so that the environment image can accommodate the complete target face when the target face is included.

[0069] In another possible implementation, after obtaining the facial payment instruction, the facial payment device activates the image acquisition component with the smallest range of view angle. If the environment image acquired by the image acquisition component with the smallest range of view angle includes a complete target face, the facial image of the target face is extracted from the environment image, and face recognition and account deduction are performed. If the environment image acquired by the image acquisition component with the smallest range of view angle does not include a complete target face, the image acquisition component with a range of view angle greater than the smallest range of view angle is switched to acquire the environment image, so that the environment image can include a complete target face, and the facial image of the target face is extracted from the environment image, and then face recognition and account deduction are performed. It should be noted that the smallest range of view angle is greater than the range of view angle of a single standard lens.

[0070] In a possible implementation, in the case where the environment image acquired by the image acquisition component with the smallest range of view angle does not include a complete target face, the facial payment device can sort the ranges of view angle of the image acquisition components according to their sizes, and gradually increase the range of view angle of the activated image acquisition component, so that the size of the environment image can be reduced as much as possible when the environment image includes a complete target face, and the processing overhead of the environment image can be reduced.

[0071] In another possible implementation, in a case where the target face is not complete in the environment image captured by the image capture component with the smallest field of view, the face payment device can determine a required field of view according to the size of the target face included in the environment image captured by the image capture component with the smallest field of view, and start the image capture component corresponding to the required field of view to reacquire the environment image, so that the reacquired environment image includes a complete target face image. The face payment device can store a correspondence among the size of the target face included in the currently acquired environment image, the field of view of the currently started image capture component, and the field of view of the required image capture component. After the face payment device acquires the size of the target face included in the environment image captured by the image capture component with the smallest field of view, the face payment device can determine the field of view of the required image capture component according to the correspondence, so as to quickly start the required image capture component and accelerate the acquisition rate of the environment image.

[0072] In the embodiments of the present application, the face payment device can acquire a plurality of images by using the image capture device when acquiring the environment image, and select the environment image from the plurality of images. Optionally, the step 201 includes the following steps:

[0073] 1. Acquire a to-be-processed video stream by using the image capture component.

[0074] The to-be-processed video stream refers to a continuous image set acquired after the face payment instruction. Optionally, in the embodiments of the present application, the face payment device starts the image capture component to acquire continuous images of the environment around the face payment device after receiving the face payment instruction, and the to-be-processed video is composed of the continuous image set. The to-be-processed video stream includes at least two images.

[0075] 2. Acquire a quality score of each image.

[0076] The quality score is used to indicate the imaging effect of the image. Optionally, the quality score is positively correlated with the imaging effect of the image. If the quality score is large, the imaging effect of the image is good; if the quality score is small, the imaging effect of the image is poor.

[0077] In the embodiment of the present application, the face payment device, after obtaining the to-be-processed video, performs quality evaluation on each frame image in the to-be-processed video to obtain a quality score of each frame image. The influence parameters of the quality score include, but are not limited to, at least one of the following: face area in the image, image definition, image exposure, and size of the shadow area in the image. Optionally, the face payment device can call a quality evaluation model to obtain the quality score of the environmental image. Of course, in actual application, different weights can be set for different influence parameters, and the face payment device can obtain the quality score according to the weight corresponding to each influence parameter.

[0078] 3. Determine the image with the maximum quality score as the environmental image to be recognized.

[0079] In the embodiment of the present application, the face payment device, after obtaining the quality score of each frame image, determines the image with the maximum quality score as the environmental image to be recognized.

[0080] Of course, in actual application, the face payment device can also directly obtain a single frame image through the image acquisition component, perform quality evaluation on the single frame image, and obtain a quality score of the single frame image. In the case where the quality score of the single frame image is greater than or equal to a target value, the single frame image is taken as the environmental image to be recognized. In the case where the quality score of the single frame image is less than the target value, a new single frame image is obtained through the image acquisition component, and the above steps are repeated until the environmental image to be recognized is obtained. The target value can be any value set by the staff according to the actual situation.

[0081] Step 202, recognizing a target face contained in the environmental image.

[0082] The target face refers to the face corresponding to the user to be paid. In the embodiment of the present application, the face payment device, after obtaining the environmental image, recognizes the target face contained in the environmental image from the environmental image. Optionally, the face payment device can recognize the target face contained in the environmental image according to the face feature points in the environmental image, and the specific recognition manner is referred to in the Figure 5 and Figure 6 embodiments, which are not described herein.

[0083] Step 203, extracting an image region containing the target face from the environmental image to obtain a face image of the target face.

[0084] In the embodiments of the present application, after the face payment device identifies the target face contained in the environment image, the face payment device determines the image region containing the target face based on the position of the target face in the environment image, extracts the image region containing the target face from the environment image, and obtains the face image of the target face. Optionally, the face payment device can determine the image region containing the target face according to the distribution of the target face feature points. The target face feature points refer to the face feature points corresponding to the target face, and the face feature points refer to a set of feature points capable of representing the target object as a face, such as facial feature points, facial boundary contour points, etc. In a possible implementation, after the face payment device identifies the target face contained in the environment image, the face payment device obtains the target face feature points, takes the distribution region of the target face feature points as the image region containing the target face, extracts the image region from the environment image, and obtains the face image of the target face.

[0085] Optionally, in the embodiments of the present application, the face payment device can obtain the face image of the target face by cropping the image region of the target face in the environment image.

[0086] In a possible implementation, the face payment device crops the image region containing the target face in the environment image based on a preset cropping size and a preset cropping shape, and obtains the face image of the target face. The preset cropping size and the preset cropping shape can be set by the staff according to the actual situation. It should be noted that the face image obtained by the preset cropping size and the preset cropping shape includes the complete target face. Optionally, after the face payment device determines the image region containing the target face, the face payment device determines the position of the first face feature point in the image region containing the target face. The first face feature point is the feature point closest to the center position of the target face. For example, the face payment device can select the face feature point representing the nose from the target face feature points as the first face feature point after obtaining the target face feature points. Further, after obtaining the first face feature point, the face payment device crops the image region containing the target face in the environment image based on the preset cropping size and the preset cropping shape, and obtains the face image of the target face with the first face feature point as the center.

[0087] In another possible implementation, the face payment device determines a cropping size and a cropping shape according to a size of the image region containing the target face, and crops the image region containing the target face in the environment image based on the cropping size and the cropping shape to obtain the face image of the target face. Different target faces correspond to different cropping sizes and cropping shapes. Optionally, after the face payment device determines the image region containing the target face, the face payment device determines a cropping size and a cropping shape for the environment image according to a size and a shape of the image region containing the target face, and crops the image region containing the target face in the environment image based on the cropping size and the cropping shape to obtain the face image of the target face.

[0088] In step 204, the face image of the target face is displayed.

[0089] In the embodiments of the present application, after the face payment device obtains the face image of the target face, the face payment device displays the face image of the target face to the user on the display screen, and the user can determine whether the face image of the target face displayed on the display screen is the face image of the user. Further, after the face payment device receives the check pass instruction triggered by the user, the face payment device matches the face image of the target face with the pre-stored face image, determines the user identity and the user payment account through the pre-stored face image matched with the face image of the target face, and then deducts the payment amount from the user payment account. Of course, after the face payment device receives the check pass instruction triggered by the user, the face payment device can also send the face image of the target face to the server, and the server can complete the face recognition operation on the face image and the deduction operation on the user payment account. The check pass instruction can be triggered by the user through the check pass control on the display screen. Optionally, the user can generate the check pass instruction by clicking the check pass control or pressing a corresponding key.

[0090] It should be noted that in the embodiments of the present application, when the face payment device displays the face image of the target face, the check fail control can be displayed on the display screen. If the user determines that the face image of the target face displayed on the display screen is not the face image of the user, the user can trigger the check fail control to generate the check fail information. Then, when the face payment device detects the check fail information, the face payment device obtains a new environment image and repeats the above steps. Optionally, the new environment image can be obtained by a different image acquisition component. For example, the angle range of the image acquisition component corresponding to the new environment image is greater than the angle range of the image acquisition component corresponding to the previous environment image.

[0091] In summary, in the technical scheme provided by the embodiments of the present application, the image acquisition component acquires the environment image. Since the angle range of the image acquisition component is larger than that of a single standard lens, the image acquisition range is expanded, so that the image acquisition component can acquire a complete face image without the user deliberately adjusting the standing position and standing posture when acquiring the face image. In this way, the integrity of the face image is ensured, the user operation is simplified, and the operation efficiency is improved. Moreover, the image region containing the target face is extracted from the environment image, and the face image of the target face is obtained. That is, in the case where the angle range of the image acquisition component is large and the face in the environment image is small, the face image of the target face is extracted, so as to avoid the case that the target face occupies too small a proportion in the environment image, which leads to inconvenience in subsequent face recognition. The face image of the target face is extracted from the environment image, the influence of unnecessary content in the environment image on face recognition is effectively removed, the problem of too small face in the environment image is solved, and the accuracy of subsequent face recognition can be effectively ensured.

[0092] In addition, the image with the best imaging effect is selected from the to-be-processed video as the environment image, so as to ensure that the environment image is clear and accurate, improve the accuracy of the face image of the target face extracted from the environment image, and ensure the reliability of face recognition and face detection.

[0093] Next, the recognition manner of the target face is introduced.

[0094] In the example embodiments, reference is made to Figure 5 which shows a flowchart of the target face recognition manner provided by an embodiment of the present application, and the specific steps are as follows:

[0095] Step 501, recognize the face contained in the environment image.

[0096] In the embodiments of the present application, the face recognition payment device recognizes the face contained in the environment image after acquiring the environment image. Optionally, the face recognition payment device can perform face detection according to the facial feature points in the environment image.

[0097] In one possible implementation, the face recognition payment device performs image processing on the environment image after acquiring the environment image, extracts the facial feature points in the environment image, and recognizes the face contained in the environment image based on the facial feature points. The facial feature points refer to a set of feature points that can represent a target object as a face, such as facial contour points, facial boundary contour points, etc. Optionally, the face recognition payment device determines that the environment image contains a face after acquiring the facial feature points, and further recognizes the face contained in the environment image according to the distribution of the facial feature points in the environment image. It should be noted that the face contained in the environment image can be one or more.

[0098] In another possible implementation, the face payment device, after acquiring the environment image, calls a face detection model to process the environment image to identify the face contained in the environment image. The face detection model can be a deep learning model.

[0099] In step 502, if the number of faces is greater than 1, attribute information of each face is acquired.

[0100] In the embodiments of the present application, after the face payment device identifies the face contained in the environment image, the face payment device determines the subsequent step of acquiring the target face based on the number of faces contained in the environment image.

[0101] Optionally, if the number of faces contained in the environment image is 1, the face payment device takes the only face as the target face.

[0102] Optionally, if the number of faces contained in the environment image is greater than 1, the face payment device acquires attribute information of each face contained in the environment image, and selects the target face from each face contained in the environment image based on the attribute information of each face. The attribute information is used to indicate the attribute characteristics of the face. Optionally, the attribute information includes, but is not limited to, at least one of the following: face distance, face position, face posture, face size, face expression, etc.

[0103] The face distance refers to the distance between the face and the face payment device. Optionally, if the number of faces is greater than 1, the face payment device acquires depth information of face feature points corresponding to each face from a depth map of the environment image, and determines the face distance of each face based on the face feature points and the depth information. The environment image can include the face payment device, and the face payment device acquires the face distance based on the depth information of the face payment device and the depth information of the face feature points; or the environment image does not include the face payment device, and the acquisition position of the environment image is taken as the position of the face payment device, and the face distance is acquired based on the depth information of the face feature points.

[0104] The face position refers to the position of the face in the environment image. Optionally, if the number of faces is greater than 1, the face payment device determines the position of the face on the environment image based on the distribution area of the face feature points, and then acquires the face position.

[0105] The face posture refers to the relative posture of the face and the face payment device. Optionally, in the case that the number of faces is greater than 1, the face payment device obtains the depth information of the face feature points corresponding to each face from the depth map of the environment image, and determines the face posture of each face based on the face feature points and the depth information. Illustratively, the face payment device can draw the face plane contour according to the face feature points, draw the face solid contour based on the face plane contour and the depth information, and then obtain the face posture. In the above environment image, the face payment device can include the face payment device, and the face payment device obtains the face posture based on the face orientation relationship between the position of the face payment device and the face solid contour; or the above environment image does not include the face payment device, and the face payment device obtains the face posture based on the face orientation relationship between the position of the face payment device and the face solid contour, taking the collection position of the environment image as the position of the face payment device.

[0106] The face size refers to the area of the smallest rectangular frame corresponding to the face. Optionally, in the case that the number of faces is greater than 1, the face payment device determines the distribution area of the face feature points in the environment image based on the distribution of the face feature points, obtains the display area of the face in the environment image according to the distribution area, and then obtains the face size.

[0107] The face expression refers to the expression made by the user at the collection time of the environment image. Optionally, in the case that the number of faces is greater than 1, the face payment device obtains the depth information of the face feature points corresponding to each face from the depth map of the environment image, and determines the face expression of each face based on the face feature points and the depth information. Illustratively, the face payment device can determine the face feature contour according to the face feature points, determine the position of the face feature in the actual environment based on the face feature contour and the depth information, and then obtain the face expression.

[0108] Step 503, determining a target face from the environment image based on the attribute information of each face.

[0109] In the embodiment of the present application, the face payment device determines the target face from the environment image based on the attribute information of each face after obtaining the attribute information of each face.

[0110] Optionally, in the case that the attribute information includes the face distance, the face with the smallest face distance is determined as the target face. The face distance refers to the distance between the face and the face payment device.

[0111] Optionally, in the case that the attribute information includes the face position, the face with the closest distance between the face position and the center position of the environment image is determined as the target face. The face position refers to the position of the face in the environment image.

[0112] Optionally, in the case that the attribute information comprises a face posture, a face whose face posture is a front face posture to the face payment device is determined as the target face. The face posture refers to a relative posture between the face and the face payment device.

[0113] Optionally, in the case that the attribute information comprises a face size, a face with the largest face size is determined as the target face. The face size refers to a size of a minimum rectangular frame corresponding to the face.

[0114] Optionally, in the case that the attribute information comprises a face expression, a face with a specified expression is determined as the target face. The specified expression can be set by a staff and used to indicate a waiting payment expression.

[0115] It should be noted that, in actual application, the face payment device can obtain the target face according to one or more attribute information. For example, in the case that the target face cannot be determined by one attribute information, another attribute information is used to identify the target face.

[0116] In the example embodiment, reference is made to Figure 6 which shows a flowchart of a target face identification method provided by another embodiment of the present application, and the specific steps are as follows:

[0117] Step 601, identifying a face contained in an environment image.

[0118] The step 601 is the same as the step 501 in the embodiment, and details are referred to the embodiment, which will not be repeated here. Figure 5 The step 601 is the same as the step 501 in the embodiment, and details are referred to the embodiment, which will not be repeated here. Figure 5 The step 601 is the same as the step 501 in the embodiment, and details are referred to the embodiment, which will not be repeated here.

[0119] Step 602, in the case that the number of faces is greater than 1, obtaining a face distance of each face.

[0120] The face distance refers to a distance between the face and the face payment device. In the embodiment of the present application, if the number of faces contained in the environment image is 1, the face payment device takes the unique face as the target face; if the number of faces contained in the environment image is greater than 1, the face payment device obtains the face distance of each face.

[0121] Optionally, the face payment device can obtain the face distance of each face according to the face feature point and the depth information corresponding to the face feature point, and details are referred to the embodiment, which will not be repeated here. Figure 5

[0122] Step 603, determining a face with a face distance less than a threshold value as a candidate face.

[0123] ​In the embodiment of the present application, the face payment device determines the face with a face distance less than the threshold as a candidate face after obtaining the face distance.

[0124] Step 604, if the number of candidate faces is equal to 1, the candidate face is determined as the target face.

[0125] Optionally, if the number of candidate faces is equal to 1, the face payment device determines the candidate face as the target face.

[0126] Step 605, if the number of candidate faces is greater than 1, the target face is determined from the environment image based on the attribute information of each face.

[0127] Optionally, if the number of candidate faces is greater than 1, the face payment device obtains the attribute information of each face in the candidate face, and determines the target face from the environment image based on the attribute information of each face in the candidate face, which will be described in detail in the Figure 5 Embodiment, which will not be repeated here.

[0128] It should be noted that the above is an example of the number of target faces being 1, and the number of target faces being greater than 1 will be introduced below.

[0129] Please refer to Figure 7 , which shows a flowchart of an image processing method provided by an embodiment of the present application. The method can be applied to Figure 1 The face payment device 20 in the face payment system shown in the face payment system, and the execution subject of each step can be the face payment device 20 described above. The method can include the following steps (701-704):

[0130] Step 701, obtaining an environment image through an image acquisition component.

[0131] Step 702, identifying a target face contained in the environment image.

[0132] The steps 701 and 702 described above are the same as the steps 201 and 202 in the Figure 2 Embodiment, which will be described in detail in the Figure 2 Embodiment, which will not be repeated here.

[0133] Step 703, displaying each target face in the case where the number of target faces is greater than 1.

[0134] In the embodiment of the present application, if the number of the target faces is greater than 1, the face payment device can determine the image region of each target face based on the facial feature points in the environment image, extract the image region of each target face from the environment image, obtain the face image of each target face, and display the face image of each target face, so as to display each target face. Wherein, the face image of each target face is displayed side by side on the display screen of the face payment device.

[0135] In step 704, in response to the selection operation for the first target face, the face image of the first target face is displayed.

[0136] The selection operation refers to the operation performed by the user for a certain target face. In the embodiment of the present application, when the face payment device detects the selection operation for the first target face among the target faces, the face image of the first target face is displayed, and the face images of the other target faces except the first target face are not displayed.

[0137] For example, in combination with reference to Figure 8 The display mode of the target face in different situations is introduced. In the environment image 80, only the first user 81 is included, at this time, the face payment device recognizes the face 82 of the first user 81 in the environment image 80, and crops the image region 83 including the face 82 in the environment image, obtains and displays the face image 84 of the first user 81. In the environment image 90, the first user 91, the second user 92 and the third user 93 are included, at this time, the face payment device recognizes the first face 94 of the first user 91, the second face 95 of the second user 92 and the third face 96 of the third user 93 in the environment image 90, and determines the first face 94 with the largest face size as the target face from the face size of each face image, crops the image region 97 including the first face 94 in the environment image, obtains and displays the face image 98 of the first user 91. In the environment image 100, the first user 101 and the second user 102 are included, at this time, the face payment device recognizes the first face 103 of the first user 101 and the second face 104 of the second user 102 in the environment image 100, and cannot determine the target face from the first face 103 and the second face 104 according to the attribute information, therefore, the first image region 105 including the first face 103 and the second image region 106 including the second face 104 in the environment image are cropped, the first face image 107 of the first user 101 and the second face image 108 of the second user 102 are obtained and displayed, and after detecting the selection operation of the user for the first face image 107, the second face image 108 is not displayed, and the first face image 107 is displayed.

[0138] Optionally, to ensure the accurate completion of the payment process, the face-scanning payment device displays a prompt message after displaying the facial image of the first target face. The prompt message is used to remind the user to enter verification information, and the verification information is used to verify whether the first target face is the face of the user to be paid. Furthermore, after obtaining the verification information entered by the user, the face-scanning payment device verifies the verification information. If the verification information passes the verification, the user identity and user payment account are determined through the pre-stored facial image that matches the facial image of the first target face; if the verification information fails the verification, the facial images of the other target faces except the first target face are redisplayed. When verifying the verification information, the face-scanning payment device can compare the verification information with the pre-stored identity information. If the verification information is the same as the pre-stored identity information, the verification information passes the verification. Optionally, the pre-stored identity information refers to the identity information corresponding to the pre-stored facial image that matches the facial image of the first target face, and the pre-stored identity information has the function of indicating a unique user.

[0139] To sum up, in the technical solution provided by the embodiment of the present application, when the target face includes multiple faces, the user selects the first target face to ensure the accuracy of the selection of the first target face and ensure that the payment process is accurate and smooth.

[0140] In addition, combined with reference Figure 9 , which introduces the complete payment process of this application.

[0141] Step 901: The face-scanning payment device obtains an environment image through an image acquisition component.

[0142] Step 902: The face-scanning payment device recognizes the target face in the environment image.

[0143] In step 903, the face-scanning payment device extracts an image region including the target face from the environment image to obtain a facial image of the target face.

[0144] In step 904, the face payment device determines whether the number of target faces is 1. If the number of target faces is 1, step 905 is executed; if the number of target faces is greater than 1, step 906 is executed.

[0145] Step 905: The face-scanning payment device displays a facial image of a single target face.

[0146] Step 906: The face-scanning payment device displays facial images of multiple target faces.

[0147] In step 907, in response to the selection operation on the first target face in the face image of the target face, the face payment device retains the display of the face image of the first target face, and cancels the display of the face image of the other target faces in the target face except the first target face.

[0148] In step 908, the face payment device performs a payment process through the currently displayed face image.

[0149] The following is an embodiment of the device of the present application, which can be used to execute the method embodiments of the present application. For details not disclosed in the device embodiments of the present application, please refer to the method embodiments of the present application.

[0150] Please refer to Figure 10 , which shows a block diagram of an image processing device provided by an embodiment of the present application. The device has the function of implementing the above-mentioned image processing method, which can be realized by hardware or corresponding software executed by hardware. The device can be a face payment device or can be arranged in a face payment device. The device 1000 can include an image acquisition module 1010, a face recognition module 1020, a region extraction module 1030, and a face display module 1040.

[0151] The image acquisition module 1010 is configured to acquire an environment image through an image acquisition component, and the angle range of the image acquisition component is greater than that of a single standard lens.

[0152] The face recognition module 1020 is configured to recognize a target face contained in the environment image.

[0153] The region extraction module 1030 is configured to extract an image region containing the target face from the environment image to obtain a face image of the target face.

[0154] The face display module 1040 is configured to display the face image of the target face.

[0155] In an exemplary embodiment, as Figure 11 shown, the face recognition module 1020 includes a face acquisition unit 1021, an attribute acquisition unit 1022, and a face recognition unit 1023.

[0156] The face acquisition unit 1021 is configured to recognize a face contained in the environment image.

[0157] The attribute acquisition unit 1022 is configured to, in the case where the number of faces is greater than 1, acquire attribute information of each face, the attribute information being used to indicate the attribute characteristics of the face.

[0158] The face recognition unit 1023 is configured to determine the target face from the environment image based on attribute information of each face.

[0159] In an example embodiment, the face recognition unit 1023 is configured to determine the face with the smallest face distance as the target face when the attribute information comprises face distances; wherein the face distance refers to a distance between the face and the facial payment device; or determine the face with the closest face position to the center position of the environment image as the target face when the attribute information comprises face positions; wherein the face position refers to a position of the face in the environment image; or determine the face with a front face posture as the target face when the attribute information comprises face postures; wherein the face posture refers to a relative posture between the face and the facial payment device; or determine the face with the largest face size as the target face when the attribute information comprises face sizes; wherein the face size refers to a size of a minimum rectangular frame corresponding to the face; or determine the face with a specified face expression as the target face when the attribute information comprises face expressions.

[0160] In an example embodiment, as shown in Figure 11 The face recognition module 1020 comprises a distance acquisition unit 1024, a candidate acquisition unit 1025, and a face recognition unit 1023.

[0161] The distance acquisition unit 1024 is configured to acquire face distances of each face when the number of faces is greater than 1; wherein the face distance refers to a distance between the face and the facial payment device.

[0162] The candidate acquisition unit 1025 is configured to determine a face with a face distance less than a threshold value as a candidate face.

[0163] The face recognition unit 1023 is configured to determine the candidate face as the target face when the number of candidate faces is equal to 1; or perform the step of determining the target face from the environment image based on attribute information of each face when the number of candidate faces is greater than 1.

[0164] In an example embodiment, as shown in Figure 11 The region extraction module 1030 comprises a region cropping unit.

[0165] The region cropping unit is configured to crop, based on a preset cropping size and a preset cropping shape, an image region containing the target face in the environment image to obtain a face image of the target face; or determine a cropping size and a cropping shape according to a size of the image region containing the target face, and crop, based on the cropping size and the cropping shape, the image region containing the target face in the environment image to obtain the face image of the target face.

[0166] In an example embodiment, the region cropping unit is configured to determine a position of a first face feature point in the image region containing the target face, the first face feature point being a feature point closest to a center position of the target face; and crop, based on the preset cropping size and the preset cropping shape, the image region containing the target face in the environment image with the first face feature point as a center to obtain the face image of the target face.

[0167] In an example embodiment, the image acquisition module 1010 is configured to acquire a to-be-processed video stream by using the image acquisition component, the to-be-processed video stream including at least two images; acquire a quality score of each image, the quality score being positively correlated with an imaging effect of the image; and determine an image with the largest quality score as the environment image to be recognized.

[0168] In an example embodiment, the face display module 1040 is configured to display each target face when the number of target faces is greater than 1; and display a face image of a first target face in response to a selection operation on the first target face.

[0169] In an example embodiment, the image acquisition component includes at least one camera with a wide-angle lens; or the image acquisition component includes a plurality of cameras with standard lenses.

[0170] In conclusion, in the technical scheme provided by the embodiment of the present application, the image acquisition component is used to acquire the environment image. Since the angle range of the image acquisition component is larger than that of a single standard lens, the image acquisition range is expanded, so that the image acquisition component can acquire a complete face image without the user deliberately adjusting the standing position and standing posture when acquiring the face image. In this way, the integrity of the face image is ensured, the user operation is simplified, and the operation efficiency is improved. Moreover, the image region containing the target face is extracted from the environment image, and then the face image of the target face is obtained. That is, in the case where the angle range of the image acquisition component is large and the face in the environment image is small, the face image of the target face is extracted, so as to avoid the case that the target face occupies too small a proportion in the environment image, which causes the subsequent face recognition to be inconvenient. The face image of the target face is extracted from the environment image, the influence of unnecessary content in the environment image on face recognition is effectively removed, the problem of the face being too small in the environment image is solved, and the accuracy of the subsequent face recognition can be effectively ensured.

[0171] It should be noted that the device provided in the above embodiment is only used as an example to illustrate the division of the above functional modules in realizing its functions. In actual application, the above functions can be completed by different functional modules according to needs, that is, the internal structure of the device is divided into different functional modules to complete all or part of the above described functions. In addition, the device and method embodiments provided in the above embodiments belong to the same concept, and the specific implementation process is described in detail in the method embodiments, which will not be repeated here.

[0172] Please refer to Figure 12 which shows a structural block diagram of the face payment device 1200 provided in an embodiment of the present application. The face payment device 1200 can be an electronic device such as a mobile phone, a mobile phone, a tablet computer, a game console, an e-book reader, a multimedia playback device, a wearable device, a PC (Personal Computer), a self-service payment machine, etc. The face payment device is used to implement the image processing method provided in the above embodiments. The face payment device can be Figure 1 the face payment device 10 in the game running environment shown in FIG. 12. Specifically:

[0173] Generally, the face payment device 1200 includes a processor 1201 and a memory 1202.

[0174] The processor 1201 can include one or more processing cores, such as a 4-core processor, an 8-core processor, and the like. The processor 1201 can be implemented in at least one of a hardware form of a DSP (Digital Signal Processing), an FPGA (Field Programmable Gate Array), a PLA (Programmable Logic Array). The processor 1201 can also include a main processor and a co-processor, the main processor being a processor for processing data in an awake state, also referred to as a CPU (Central Processing Unit), and the co-processor being a low-power processor for processing data in a standby state. In some embodiments, the processor 1201 can be integrated with a GPU (Graphics Processing Unit) that is responsible for rendering and drawing of content to be displayed on the display screen. In some embodiments, the processor 1201 can further include an AI (Artificial Intelligence) processor for processing machine learning-related computing operations.

[0175] The memory 1202 can include one or more computer-readable storage media that can be non-transitory. The memory 1202 can also include a high-speed random access memory, and a non-volatile memory such as one or more disk storage devices, flash storage devices. In some embodiments, the non-transitory computer-readable storage medium in the memory 1202 is configured to store at least one instruction, at least one program, a code set or an instruction set, which is configured to be executed by one or more processors to implement the image processing method described above.

[0176] In some embodiments, the face payment device 1200 can also optionally include a peripheral device interface 1203 and at least one peripheral device. The processor 1201, the memory 1202, and the peripheral device interface 1203 can be connected through a bus or a signal line. Each peripheral device can be connected to the peripheral device interface 1203 through a bus, a signal line, or a circuit board. Specifically, the peripheral device includes at least one of a radio frequency circuit 1204, a display screen 1205, a camera assembly 1206, an audio circuit 1207, a positioning assembly 1208, and a power supply 1209.

[0177] Those skilled in the art can understand that, Figure 12The structure shown in the figure does not constitute a limitation on the face payment device 1200, and can include more or fewer components than shown, or combine certain components, or adopt a different arrangement of components.

[0178] In an example embodiment, a computer readable storage medium is also provided, in which at least one instruction, at least one program, a code set or an instruction set is stored, and the at least one instruction, the at least one program, the code set or the instruction set is executed by a processor to implement the image processing method described above.

[0179] Optionally, the computer readable storage medium can include ROM (Read Only Memory), RAM (Random Access Memory), SSD (Solid State Drives), optical disc, etc. Among them, the random access memory can include ReRAM (Resistance Random Access Memory) and DRAM (Dynamic Random Access Memory).

[0180] In an example embodiment, a computer program product or computer program is also provided, which includes computer instructions stored in a computer readable storage medium. The processor of the face payment device reads the computer instructions from the computer readable storage medium, and the processor executes the computer instructions to make the face payment device execute the image processing method described above.

[0181] It should be understood that "multiple" referred to herein refers to two or more. "And / or", which describes the association relationship of associated objects, means that there can be three relationships, for example, A and / or B can mean that A exists alone, A and B exist together, and B exists alone. The character " / " generally represents that the associated objects before and after it are in an "or" relationship. In addition, the step numbers described herein only exemplarily show a possible execution order between steps, and in some other embodiments, the above steps can also be executed in a different order from the numbering order, such as simultaneously executing two steps with different numbers, or executing two steps with different numbers in an order opposite to the illustration, and the embodiments of the present application do not limit this.

[0182] The above only describes example embodiments of the present application and does not limit the present application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principles of the present application shall be included in the protection scope of the present application.

Claims

1. An image processing method, characterized by, The method is applied to a face payment device, a surrounding area of the face payment device is provided with multiple image acquisition components of different types, the multiple image acquisition components of different types correspond to different visual angle ranges, the visual angle range of the image acquisition component is greater than the visual angle range of a single standard lens, and the method comprises the following steps: acquiring an environment image through an image acquisition component with the smallest visual angle range; in a case where a complete target face is included in an image acquired by the image acquisition component with the smallest visual angle range, determining the image acquired by the image acquisition component with the smallest visual angle range as the environment image; in a case where a complete target face is not included in the image acquired by the image acquisition component with the smallest visual angle range, determining a required visual angle range according to the face size of the target face included in the image acquired by the image acquisition component with the smallest visual angle range, and starting an image acquisition component corresponding to the required visual angle range to acquire the environment image; recognizing a target face included in the environment image; extracting an image region including the target face from the environment image to obtain a face image of the target face; in a case where the number of target faces is greater than 1, displaying the face image of each target face; in response to a selection operation on a first target face in the multiple target faces, displaying the face image of the first target face, and displaying prompt information for reminding input of verification information, the verification information being used to verify whether the first target face is a face corresponding to a user to be paid, the face payment device being used to compare the verification information with pre-stored identity information; in a case where the verification information is the same as the pre-stored identity information, determining that the verification information passes the verification; in a case where the verification information passes the verification, determining the identity of the user to be paid and a payment account of the user to be paid according to a pre-stored face image matched with the first target face.

2. The method of claim 1, wherein, The step of recognizing a target face included in the environment image comprises the following steps: recognizing a face included in the environment image; in a case where the number of faces is greater than 1, acquiring attribute information of each face, the attribute information being used to indicate the attribute characteristics of the face; determining the target face from the environment image based on the attribute information of each face.

3. The method of claim 2, wherein, The step of determining the target face from the environment image based on the attribute information of each face comprises the following steps: in a case where the attribute information includes a face distance, determining a face with the smallest face distance as the target face; wherein the face distance refers to the distance between the face and the face payment device; or, in a case where the attribute information includes a face position, determining a face with the closest distance between the face position and the central position of the environment image as the target face; wherein the face position refers to the position of the face in the environment image; or, In a case where the attribute information comprises a face posture, a face posture being a relative posture between the face and the face payment device, a face with a face posture being a front view of the face payment device is determined as the target face; Or, In a case where the attribute information comprises a face size, a face with a maximum face size is determined as the target face; wherein the face size refers to a size of a minimum rectangular frame corresponding to the face; Or, In a case where the attribute information comprises a face expression, a face with a specified expression is determined as the target face.

4. The method of claim 2, wherein, After the face contained in the environment image is recognized, the method further comprises: In a case where the number of faces is greater than 1, a face distance of each face is obtained, the face distance being a distance between the face and the face payment device; a face with a face distance less than a threshold value is determined as a candidate face; if the number of candidate faces is equal to 1, the candidate face is determined as the target face; if the number of candidate faces is greater than 1, the step of determining the target face from the environment image based on the attribute information of each face is performed.

5. The method of claim 1, wherein, The step of extracting an image region containing the target face from the environment image to obtain a face image of the target face comprises: cropping the image region containing the target face in the environment image based on a preset cropping size and a preset cropping shape to obtain the face image of the target face; Or, determining a cropping size and a cropping shape according to the size of the image region containing the target face; and cropping the image region containing the target face in the environment image based on the cropping size and the cropping shape to obtain the face image of the target face.

6. The method of claim 5, wherein, The step of cropping the image region containing the target face in the environment image based on a preset cropping size and a preset cropping shape to obtain the face image of the target face comprises: determining a position of a first face feature point in the image region containing the target face, the first face feature point being a feature point closest to the center position of the target face; cropping the image region containing the target face in the environment image based on the preset cropping size and the preset cropping shape and taking the first face feature point as the center to obtain the face image of the target face.

7. The method of claim 1, wherein, The step of collecting an environment image through an image acquisition component with the smallest view angle range comprises: acquiring a to-be-processed video stream through the image acquisition component with the smallest view angle range, the to-be-processed video stream comprising at least two images; obtaining a quality score of each image, the quality score being positively correlated with the imaging effect of the image; determining an image with the largest quality score as the environment image collected by the image acquisition component with the smallest view angle range.

8. The method of any one of claims 1 to 7, wherein: the image acquisition component comprises at least one camera with a wide-angle lens; Or, the image acquisition component comprises a plurality of cameras with a standard lens.

9. An image processing apparatus characterized by comprising: The device comprises: The image acquisition module is configured to: acquire an environment image by using an image acquisition component with a minimum field of view; in a case where a complete target face is included in an image acquired by the image acquisition component with the minimum field of view, determine the image acquired by the image acquisition component with the minimum field of view as the environment image; in a case where the complete target face is not included in the image acquired by the image acquisition component with the minimum field of view, determine a required field of view according to a face size of the target face included in the image acquired by the image acquisition component with the minimum field of view, and start an image acquisition component corresponding to the required field of view to acquire the environment image; The face recognition module is configured to recognize a target face included in the environment image. The region extraction module is configured to extract an image region including the target face from the environment image to obtain a face image of the target face. The face display module is configured to: in a case where the number of target faces is greater than one, display face images of the target faces; in response to a selection operation on a first target face in the target faces, display the face image of the first target face, and display prompt information for reminding input of verification information, the verification information being used to verify whether the first target face is a face corresponding to a to-be-paid user, and the face payment device is configured to compare the verification information with prestored identity information; in a case where the verification information is the same as the prestored identity information, determine that the verification information passes verification; and in a case where the verification information passes verification, determine an identity of the to-be-paid user and a payment account of the to-be-paid user according to a prestored face image matched with the first target face.

10. A facial payment device, characterized by, The face payment device includes a processor and a memory, and the memory stores at least one program, which is loaded and executed by the processor to implement the image processing method according to any one of claims 1 to 9.

11. A computer readable storage medium, characterized in that, The storage medium stores at least one program, which is loaded and executed by the processor to implement the image processing method according to any one of claims 1 to 9.

12. A computer program product, characterised in that, The computer program product includes computer instructions stored in a computer readable storage medium, and the processor reads and executes the computer instructions from the computer readable storage medium to implement the image processing method according to any one of claims 1 to 9.

Citation Information

Patent Citations

  • Face verification method, device and equipment and storage medium

    CN109948586A

  • Method and device based on face recognition

    CN110032945A

  • Face-scanning payment method and device

    CN110443620A

  • Face-scanning payment method and device and electronic equipment

    CN111292092A

  • Face recognition-based picture cutting method, device and apparatus, and storage medium

    WO2015154516A1