Image processing method and electronic equipment

By adjusting the location of key point groups in the imaging data collected by different lenses, the problem of different imaging effects of different lenses is solved, and the user experience and imaging three-dimensional sense is improved.

CN120201312APending Publication Date: 2025-06-24LENOVO (BEIJING) LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510240113.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-28
Publication Date
2025-06-24

AI Technical Summary

Technical Problem

There are differences in imaging effects of different lenses, resulting in large differences between users and actual situations, affecting the user's user experience.

Method used

By acquiring the imaging data acquired by the first lens and the second lens, the key point group position in the second imaging data is adjusted based on the key point group position in the first imaging data, and the target image data is obtained. This method is suitable for lenses with different focal lengths, adjusting the distance proportional relationship between key point groups to narrow the difference between imaging effects and user visual effects.

Benefits of technology

By adjusting the position of key point groups in the lens imaging data, the difference in imaging effects of different focal length lenses on the target object is reduced, the user experience is improved, and the three-dimensional sense of imaging is enhanced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120201312A_ABST
    Figure CN120201312A_ABST
Patent Text Reader

Abstract

The invention provides an image processing method and electronic equipment. The method comprises the following steps: acquiring first imaging data acquired by a first lens and second imaging data acquired by a second lens; adjusting a second key point group position in the second imaging data based on a first key point group position in the first imaging data to obtain target image data; wherein the focal length of the first lens is different from that of the second lens; the first key point group position is a key point position corresponding to a target object contained in the first imaging data; the second key point group position is a key point position corresponding to the target object contained in the second imaging data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of image processing technologies, and in particular, to an image processing method and an electronic device. Background Art

[0002] There are differences in the imaging effects of different lenses. For example, a wide-angle lens usually has a large viewing angle and a large depth of field, and the foreground and background in the image are relatively clear. The imaging effect of a telephoto lens will compress the three-dimensional sense, resulting in a large difference between the visual and actual situations of the user in the image, which affects the user experience. Therefore, how to reduce the difference between the visual and actual situations of the user in the image and improve the user experience has become an urgent technical problem to be solved. Summary of the Invention

[0003] The present disclosure provides an image processing method and an electronic device.

[0004] According to a first aspect of the present disclosure, there is provided an image processing method, including:

[0005] Obtaining first imaging data collected by a first lens and second imaging data collected by a second lens;

[0006] Adjusting the position of a second key point group in the second imaging data based on the position of a first key point group in the first imaging data to obtain target image data;

[0007] Wherein, the focal length of the first lens is different from the focal length of the second lens; the position of the first key point group is the position of the key points corresponding to the target object included in the first imaging data; the position of the second key point group is the position of the key points corresponding to the target object included in the second imaging data.

[0008] In an embodiment of the present application, the distances between the key points in the first key point group have a first proportional relationship;

[0009] The distances between the key points in the second key point group have a second proportional relationship;

[0010] The first proportional relationship is different from the second proportional relationship.

[0011] In an embodiment of the present application, the adjusting the position of the second key point group of the target object in the second imaging data based on the position information of the first key point group of the target object in the first imaging data to obtain target image data includes:

[0012] Adjusting the second proportional relationship corresponding to the distances between the key points in the second key point group in the second imaging data based on the first proportional relationship of the distances between the key points in the first key point group to obtain target image data.

[0013] In an embodiment of the present application, the distances between the key points in the third key point group have a fifth proportional relationship; the first proportional relationship is the same as the fifth proportional relationship; the position of the third key point group is the position of the key points corresponding to the target object included in the target image data.

[0014] In an embodiment of the present application, the first sub-key point has a first distance from the first reference key point; the second sub-key point has a second distance from the first reference key point; the third sub-key point has a third distance from the second reference key point; the fourth sub-key point has a fourth distance from the second reference key point; the first sub-key point, the second sub-key point, and the first reference key point belong to the third key point group; the third sub-key point, the fourth sub-key point, and the second reference key point belong to the second key point group; the key point of the target object represented by the first sub-key point is the same as the key point of the target object represented by the third sub-key point, the key point of the target object represented by the second sub-key point is the same as the key point of the target object represented by the fourth sub-key point, and the key point of the target object represented by the first reference key point is the same as the key point of the target object represented by the second reference key point; the first distance and the third distance have a third proportional relationship; the second distance and the fourth distance have a fourth proportional relationship, and the third proportional relationship is different from the fourth proportional relationship.

[0015] In an embodiment of the present application, adjusting the position of the second key point group in the second imaging data based on the position of the first key point group in the first imaging data to obtain target image data includes:

[0016] Obtaining a first distortion parameter of the first lens and a second distortion parameter of the second lens;

[0017] Determining an adjustment coefficient corresponding to the second key point group in the second imaging data according to the first distortion parameter and the second distortion parameter;

[0018] Adjusting the position of the second key point group in the second imaging data based on the position of the first key point group in the first imaging data and the adjustment coefficient to obtain target image data.

[0019] In an embodiment of the present application, the second imaging data includes the facial key point position of the target object and the lens position parameter of the second lens;

[0020] Adjusting the position of the second key point group in the second imaging data based on the position of the first key point group in the first imaging data to obtain target image data includes:

[0021] Adjust the positions of each facial key point in the second imaging data according to the positions of the first key point group in the first imaging data to obtain the corrected facial key point information;

[0022] Construct a facial image of the target object as the target image based on the corrected facial key point information and the lens position parameters.

[0023] In an embodiment of the present application, the acquisition time interval between the first imaging data and the second imaging data is less than a preset time interval.

[0024] According to a second aspect of the present disclosure, there is provided an electronic device, including:

[0025] A first lens;

[0026] A second lens;

[0027] At least one processor; and

[0028] A memory communicatively connected to the at least one processor; wherein,

[0029] The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to acquire first imaging data collected by the first lens and second imaging data collected by the second lens, and adjust the positions of the second key point group in the second imaging data based on the positions of the first key point group in the first imaging data to obtain target image data; wherein, the focal length of the first lens is different from the focal length of the second lens; the positions of the first key point group are the key point positions corresponding to the target object included in the first imaging data; the positions of the second key point group are the key point positions corresponding to the target object included in the second imaging data.

[0030] In an embodiment of the present application, the focal length of the second lens is greater than the focal length of the first lens.

[0031] It should be understood that the content described in this part is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it used to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] By referring to the accompanying drawings and reading the following detailed description, the above and other objects, features, and advantages of the exemplary embodiments of the present disclosure will become easily understood. In the drawings, several embodiments of the present disclosure are shown in an exemplary rather than restrictive manner, wherein:

[0033] In the drawings, the same or corresponding reference numerals represent the same or corresponding parts.

[0034] Figure 1 Shows a schematic diagram of an implementation process of the image processing method provided by an embodiment of the present application;

[0035] Figure 2 Shows a schematic diagram of a target image data determination process provided by an embodiment of the present application;

[0036] Figure 3 Shows another schematic diagram of a target image data determination process provided by an embodiment of the present application;

[0037] Figure 4 Shows a schematic diagram of applying the image processing method provided by an embodiment of the present application;

[0038] Figure 5 Shows a schematic diagram of a structure of an image processing apparatus provided by an embodiment of the present application;

[0039] Figure 6 Shows a schematic diagram of a composition structure of an electronic device according to an embodiment of the present disclosure. Detailed implementation manners

[0040] To make the objectives, features, and advantages of the present disclosure more obvious and understandable, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present disclosure. Apparently, the described embodiments are only a part of the embodiments of the present disclosure, rather than all the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by those skilled in the art without creative efforts belong to the scope of protection of the present disclosure.

[0041] Since there are significant differences between the imaging effects of some lenses and the user's visual imaging effects, the user experience is affected. Therefore, in order to reduce the visual and actual differences of the user in imaging and improve the user experience, the present application provides an image processing method and an electronic device. In the present application, the first lens and / or the second lens may be lenses deployed on the electronic device, or the first lens and / or the second lens may also be lens devices external to the electronic device. The electronic device provided by the present application may be devices such as mobile phones, laptop computers, and tablet computers.

[0042] The technical solutions in the embodiments of the present application will be described below with reference to the accompanying drawings in the embodiments of the present application.

[0043] Figure 1 Shows a schematic diagram of an implementation process of the image processing method provided by an embodiment of the present application, as Figure 1 shown, the method includes:

[0044] S101, obtaining first imaging data collected by a first lens and second imaging data collected by a second lens.

[0045] In the embodiments of the present disclosure, the focal length of the first lens is different from that of the second lens. For example, the first lens may be a wide-angle lens or a standard lens, etc., and the second lens may be a telephoto lens. Or, the second lens may be a wide-angle lens or a standard lens, etc., and the first lens may be a telephoto lens. Generally, the focal length of a telephoto lens is greater than that of a standard lens, and the focal length of a standard lens is generally greater than that of a wide-angle lens. The imaging effects of lenses with different focal lengths on the same shooting object are different. For the same shooting object, the imaging angle of view of a wide-angle lens is wider, the imaging angle of view of a standard lens is closer to that of the human eye, and the imaging angle of view of a telephoto lens is relatively narrow. For example, when shooting the face of the same shooting object in the same scene, there is an axial displacement of the image plane in the face image captured by the wide-angle lens, resulting in a smaller axial distance between the nose plane and the ear plane of the person being photographed than the actual distance, and there is an axial stretching effect in the imaging effect compared with the actual visual effect, that is, the face of the person being photographed in the imaging is longitudinally stretched, increasing the three-dimensional sense. There is a lateral displacement of the image plane in the face image captured by the telephoto lens, resulting in a larger lateral distance between the nose plane and the ear plane of the person being photographed than the actual distance, that is, the face of the person being photographed in the imaging is laterally stretched, reducing the three-dimensional sense.

[0046] In the embodiments of the present disclosure, the first lens and / or the second lens may be integrated into an electronic device such as a mobile phone or a tablet. The operating system of the electronic device can access the camera hardware through an API (Application Programming Interface) to obtain the first imaging data collected by the first lens and the second imaging data collected by the second lens. If the first lens and / or the second lens are lenses independent of the electronic device, the electronic device can access the camera devices of the first lens and / or the second lens through an external interface to obtain the first imaging data collected by the first lens and the second imaging data collected by the second lens.

[0047] The first imaging data may include the imaging data of the target object captured by the first lens, and the second imaging data may include the imaging data of the target object captured by the second lens. The first imaging data and the second imaging data are imaging data of the same target object in the same scene.

[0048] In the embodiments of the present disclosure, the acquisition time interval between the first imaging data and the second imaging data is less than a preset time interval. The setting principle of the preset time interval is that within the preset time interval, information such as the scene where the same target object is located, the actions of the target object, and the expressions of the target object captured by the first lens and the second lens cannot change visibly to the naked eye. For example, the preset time interval can be set to 0.1 second or 0.2 second, etc.

[0049] S102. Adjust the positions of the second key point group in the second imaging data based on the positions of the first key point group in the first imaging data to obtain target image data.

[0050] The positions of the first key point group are the key point positions corresponding to the target object included in the first imaging data; the positions of the second key point group are the key point positions corresponding to the target object included in the second imaging data.

[0051] In the embodiments of the present disclosure, the target object may be a person, a scene, an animal, etc. For example, if the first lens uses a standard lens and the second lens uses a telephoto lens, and the target object to be photographed is the face of person A, due to the imaging of the telephoto lens having a vertical axial stretching effect, the photographed face of person A will be wider than the actual one, reducing the three-dimensionality of the face in the imaging. Therefore, in order to reduce the difference between the imaging effect of the face of person A photographed by the telephoto lens and the actual visual effect, the positions of the face key points in the face imaging data photographed by the standard lens can be used to adjust the positions of the face key points in the face imaging of person A photographed by the telephoto lens, reducing the horizontal stretching effect of the face imaging of person A photographed by the telephoto lens and enhancing the three-dimensionality of the imaging.

[0052] In the embodiments of the present disclosure, the key point groups of different types of target objects are different. For example, if the target object is a person, the key point group may include key points such as the nose, eyes, mouth, ears, and eyebrows on the human face. If the target object is a building object, the key point group may include key points composed of the edge points and the center point of the building object.

[0053] By using the method provided in the embodiments of the present disclosure, the first imaging data collected by the first lens and the second imaging data collected by the second lens are obtained; the positions of the second key point group in the second imaging data are adjusted based on the positions of the first key point group in the first imaging data to obtain target image data. By adjusting the key point positions corresponding to the target object in the first imaging data of the first lens with a different focal length from that of the second lens, the imaging effect difference of the target object by lenses with different focal lengths is reduced, and further the difference between the imaging effect and the user's vision is reduced, improving the user experience.

[0054] In the embodiments of the present disclosure, the distances between the key points in the first key point group have a first proportional relationship; the distances between the key points in the second key point group have a second proportional relationship; the first proportional relationship is different from the second proportional relationship.

[0055] For example, if the target object is a person, the key point group includes key points representing organs such as the nose, eyes, mouth, ears, and eyebrows on the human face. The key point corresponding to the nose can be used as the center point, the horizontal distance between each other key point in the first key point group and the center point is used as the first proportional relationship, and the horizontal distance between each other key point in the second key point group and the center point is used as the second proportional relationship. Since the imaging of a telephoto lens has a horizontal stretching effect, in the scenario where the second lens is a telephoto lens and the first lens is a standard lens, it can be obtained that the horizontal distance between each other key point in the first key point group in the first proportional relationship and the center point is smaller than the horizontal distance between the corresponding other key points in the second key point group in the second proportional relationship.

[0056] In a possible implementation manner, adjusting the position of the second key point group of the target object in the second imaging data based on the position information of the first key point group of the target object in the first imaging data to obtain target image data may include: adjusting the second proportional relationship corresponding to the distances between the key points in the second key point group in the second imaging data based on the first proportional relationship among the distances between the key points in the first key point group to obtain target image data.

[0057] As an implementable manner, in the embodiments of the present disclosure, the position of the third key point group is the position of the key points corresponding to the target object included in the target image data. The distances between the key points in the third key point group have a fifth proportional relationship; the first proportional relationship is the same as the fifth proportional relationship.

[0058] In the embodiments of the present disclosure, the proportional relationship between the distances between the key points in the second key point group in the second imaging data may be adjusted to the first proportional relationship, and the image corresponding to the adjusted second imaging data is used as the target image data. Optionally, the distances between the key points in the second key point group in the second imaging data may be adjusted to the distances between the corresponding key points in the first proportional relationship. For example, if the target object is a person, and the key point corresponding to the nose on the face is used as the center point, and the first proportional relationship represents the horizontal distances between each of the other key points in the first key point group and the key point corresponding to the nose, then the horizontal distances between the key points in the second imaging data and the key point corresponding to the nose may be adjusted to the distances between the corresponding key points in the first proportional relationship. For example, the first proportional relationship includes the horizontal distance L11 between the key point corresponding to the mouth of the target object and the key point corresponding to the nose in the first imaging data, the horizontal distance L12 between the key point corresponding to the eye and the key point corresponding to the nose, the horizontal distance L13 between the key point corresponding to the ear and the key point corresponding to the nose, and the horizontal distance L14 between the key point corresponding to the eyebrow and the key point corresponding to the nose; then, in the second imaging data, the horizontal distance between the key point corresponding to the mouth and the key point corresponding to the nose may be adjusted to L11, the horizontal distance between the key point corresponding to the eye and the key point corresponding to the nose may be adjusted to L12, the horizontal distance between the key point corresponding to the ear and the key point corresponding to the nose may be adjusted to L13, and the horizontal distance between the key point corresponding to the eyebrow and the key point corresponding to the nose may be adjusted to L14. The image corresponding to the adjusted second imaging data may be used as the target image data. The three-dimensional effect of the facial features distribution in the target image data is the same as or highly similar to the three-dimensional imaging effect corresponding to the first imaging data.

[0059] In a possible implementation, the first sub-key point has a first distance from the first reference key point; the second sub-key point has a second distance from the first reference key point; the third sub-key point has a third distance from the second reference key point; the fourth sub-key point has a fourth distance from the second reference key point; the first sub-key point, the second sub-key point, and the first reference key point belong to the third key point group; the third sub-key point, the fourth sub-key point, and the second reference key point belong to the second key point group; the key point of the target object represented by the first sub-key point is the same as the key point of the target object represented by the third sub-key point, the key point of the target object represented by the second sub-key point is the same as the key point of the target object represented by the fourth sub-key point, and the key point of the target object represented by the first reference key point is the same as the key point of the target object represented by the second reference key point; the first distance and the third distance have a third proportional relationship; the second distance and the fourth distance have a fourth proportional relationship, and the third proportional relationship is different from the fourth proportional relationship.

[0060] For example, for person A as the target object, the first sub-key point may be the left eye key point 11 corresponding to the left eye of person A in the first imaging data, the second sub-key point may be the right eye key point 12 corresponding to the right eye of person A in the first imaging data, and the first reference key point may be the nose key point 13 corresponding to the nose of person A in the first imaging data; the distance between the left eye key point 11 and the nose key point 13 is the first distance l1, the distance between the right eye key point 12 and the nose key point 13 is the second distance l2, and the left eye key point 11, the right eye key point 12, and the nose key point 13 belong to the third key point group; the third sub-key point may be the left eye key point 21 corresponding to the left eye of person A in the second imaging data, the fourth sub-key point may be the right eye key point 22 corresponding to the right eye of person A in the second imaging data, and the second reference key point may be the nose key point 23 corresponding to the nose of person A in the second imaging data; the distance between the left eye key point 21 and the nose key point 23 is the third distance l3, the distance between the right eye key point 22 and the nose key point 23 is the fourth distance l4, and the left eye key point 21, the right eye key point 22, and the nose key point 23 belong to the second key point group. The ratio between the first distance l1 between the left eye key point 11 and the nose key point 13 in the first imaging data and the third distance l3 between the left eye key point 21 and the nose key point 23 in the second imaging data can be determined as the third proportional relationship, and the ratio between the second distance l2 between the right eye key point 12 and the nose key point 13 in the first imaging data and the fourth distance l4 between the right eye key point 22 and the nose key point 23 in the second imaging data can be determined as the fourth proportional relationship. Due to the asymmetry of the left and right sides of a person's face, the distances from the left eye to the nose and from the right eye to the nose are different. If the key point corresponding to the nose is used as the center, the stereoscopic compression effect of the second lens on key points with different distances from the center is different. Therefore, the third proportional relationship and the fourth proportional relationship are generally different.

[0061] In a possible implementation manner, Figure 2 shows a schematic diagram of a target image data determination process provided by an embodiment of the present application. As Figure 2 shown, adjusting the position of the second key point group in the second imaging data based on the position of the first key point group in the first imaging data to obtain the target image data may include:

[0062] S201, obtain the first distortion parameter of the first lens and the second distortion parameter of the second lens.

[0063] In the embodiments of the present disclosure, the distortion parameter of the lens is used to characterize the difference between the geometric shape of the image formed due to the optical characteristics of the lens itself and the actual scene. For example, the distortion parameter may include a pincushion distortion parameter or a barrel distortion parameter, etc. The first distortion parameter of the first lens and the second distortion parameter of the second lens can be obtained by collecting the historical calibration data of the lens.

[0064] In the embodiments of the present disclosure, if the distortion parameter of the lens includes a pincushion distortion parameter, it means that the central area of the lens imaging is normal and the edge area bulges outwards, resulting in the key points in the edge area of the image being farther from the center than in reality. If the distortion parameter of the lens includes a barrel distortion parameter, it means that the central area of the lens imaging is normal and the edge area bulges inwards, resulting in the key points in the edge area of the image being closer to the center than in reality.

[0065] S202. Determine the adjustment coefficient corresponding to the second key point group in the second imaging data according to the first distortion parameter and the second distortion parameter.

[0066] Based on the influence of the distortion parameter on the imaging data, if the distortion parameter of the lens is a pincushion distortion parameter, since the key points in the edge area of the image are farther from the center than in reality, a correction coefficient less than 1 can be determined for the key points in the edge area, and the correction coefficient can be used to correct the distance between the key points in the edge area and the center. If the distortion parameter of the lens is a barrel distortion parameter, since the key points in the edge area of the image are closer to the center than in reality, a correction coefficient greater than 1 can be determined for the key points in the edge area.

[0067] In the embodiments of the present disclosure, the first correction coefficient of the edge key points in the first imaging data can be determined according to the first distortion parameter, the second correction coefficient of the edge key points in the second imaging data can be determined according to the second distortion parameter, and the product of the first correction coefficient and the second correction coefficient can be used as the adjustment coefficient of the edge key points in the second key point group in the second imaging data.

[0068] In the embodiments of the present disclosure, the imaging range where the second imaging data characterized by the second distortion parameter will have lens distortion can be determined as the edge area. The adjustment coefficient of the key points in the edge area is the product of the corresponding first correction coefficient and the second correction coefficient, and the correction coefficient of the key points outside the edge area can be set to 1.

[0069] S203. Adjust the position of the second key point group in the second imaging data based on the position of the first key point group in the first imaging data and the adjustment coefficient to obtain the target image data.

[0070] In the embodiments of the present disclosure, the positions of the second key point group in the second imaging data can be adjusted according to the positions of the first key point group in the first imaging data. The distances between the respective key points in the adjusted second key point group and the reference center point are multiplied by corresponding adjustment coefficients to obtain adjusted distances, and the positions of the key points are readjusted according to the adjusted distances. When all the second key points have their positions readjusted by the adjustment coefficients, the obtained imaging data can be used as the target image data.

[0071] In the embodiments of the present disclosure, different resolutions may also cause the key points in the edge region and the key points in the central region of the imaging data to be different from the actual ones. Corresponding adjustment coefficients can be determined for each key point according to the influence of the resolution on the imaging effect.

[0072] In another possible implementation manner, Figure 3 shows another schematic diagram of the target image data determination process provided by the embodiments of the present application. The second imaging data includes the facial key point positions of the target object and the lens position parameters of the second lens. The lens position parameters are parameters characterizing the spatial position and orientation of the lens relative to the camera coordinate system. The lens position parameters may include a rotation vector and a translation vector. As Figure 3 shown, the adjusting the positions of the second key point group in the second imaging data based on the positions of the first key point group in the first imaging data to obtain the target image data may include:

[0073] S301, according to the positions of the first key point group in the first imaging data, adjust the positions of the respective facial key points in the second imaging data to obtain the corrected facial key point information.

[0074] Specifically, reference may be made to step S102, which will not be elaborated here.

[0075] S302, based on the corrected facial key point information and the lens position parameters, construct the facial image of the target object as the target image.

[0076] In the embodiments of the present disclosure, the corrected facial key point information may include the coordinates of the corresponding key points such as eyes, nose, and mouth. A facial model of the target object is constructed according to the coordinates of the key points. Specifically, the coordinates of the key points can be respectively subjected to affine transformation and perspective transformation through the rotation vector and translation vector included in the lens position parameters, so as to align the facial key points of the target object with other key points in the image corresponding to the second imaging data. Then, the transformed facial image is fused into the image corresponding to the second imaging data to obtain the fused image as the target image.

[0077] Figure 4 shows a schematic diagram of applying the image processing method provided by the embodiments of the present application. AsFigure 4 As shown, the standard lens and the telephoto lens of the mobile phone 401 can be used to collect face images of the target object 402 respectively. The horizontal facial distance in the image 403 of the standard lens is L1, and the horizontal facial distance in the image 404 of the telephoto lens is L2. By comparison, it can be known that the horizontal facial distance L2 in the image 404 of the telephoto lens is greater than the horizontal facial distance L1 in the image 403 of the standard lens, that is, the image 404 of the telephoto lens has a horizontal stretching effect on the human face, reducing the three-dimensionality of the human face. By adjusting the imaging data of the image 404 of the telephoto lens through the imaging data of the image 403 of the standard lens, the horizontal facial distance in the adjusted image 405 can be obtained as L3. By comparison, it can be known that the horizontal facial distance L3 in the adjusted image 405 is very close to the horizontal facial distance L1 in the image 403 of the standard lens. Through adjustment, the three-dimensionality of the face image is enhanced.

[0078] Based on the same inventive concept, according to the image processing method provided in the above embodiments of the present disclosure, correspondingly, another embodiment of the present disclosure further provides an image processing apparatus, and its structural schematic diagram is as Figure 5 shown, specifically including:

[0079] An imaging data acquisition module 501, configured to acquire first imaging data collected by a first lens and second imaging data collected by a second lens;

[0080] A key point position adjustment module 502, configured to adjust the position of a second key point group in the second imaging data based on the position of a first key point group in the first imaging data to obtain target image data;

[0081] Wherein, the focal length of the first lens is different from the focal length of the second lens; the position of the first key point group is the position of the key points corresponding to the target object included in the first imaging data; the position of the second key point group is the position of the key points corresponding to the target object included in the second imaging data.

[0082] By using the apparatus provided in the embodiments of the present disclosure, first imaging data collected by a first lens and second imaging data collected by a second lens are acquired; the position of a second key point group in the second imaging data is adjusted based on the position of a first key point group in the first imaging data to obtain target image data. By using the position of the key points corresponding to the target object in the first imaging data of the first lens with a different focal length from that of the second lens to adjust the position of the key points corresponding to the target object in the second imaging data, the difference in the imaging effects of the lenses with different focal lengths on the target object is reduced, and further the difference between the imaging effect and the user's vision is reduced, improving the user's experience.

[0083] In an implementable manner, the distances between the key points in the first key point group have a first proportional relationship;

[0084] The distances between the key points in the second key point group have a second proportional relationship;

[0085] The first proportional relationship is different from the second proportional relationship.

[0086] In an implementable manner, the key point position adjustment module is specifically configured to adjust the second proportional relationship corresponding to the distances between the key points in the second key point group in the second imaging data based on the first proportional relationship of the distances between the key points in the first key point group, so as to obtain target image data.

[0087] In an implementable manner, the distances between the key points in the third key point group have a fifth proportional relationship; the first proportional relationship is the same as the fifth proportional relationship; the position of the third key point group is the key point position corresponding to the target object included in the target image data.

[0088] In an implementable manner, the first sub-key point has a first distance from the first reference key point; the second sub-key point has a second distance from the first reference key point; the third sub-key point has a third distance from the second reference key point; the fourth sub-key point has a fourth distance from the second reference key point; the first sub-key point, the second sub-key point, and the first reference key point belong to the third key point group; the third sub-key point, the fourth sub-key point, and the second reference key point belong to the second key point group; the key point of the target object represented by the first sub-key point is the same as the key point of the target object represented by the third sub-key point, the key point of the target object represented by the second sub-key point is the same as the key point of the target object represented by the fourth sub-key point, and the key point of the target object represented by the first reference key point is the same as the key point of the target object represented by the second reference key point; the first distance and the third distance have a third proportional relationship; the second distance and the fourth distance have a fourth proportional relationship, and the third proportional relationship is different from the fourth proportional relationship.

[0089] In an implementable manner, the key point position adjustment module 502 is specifically configured to obtain the first distortion parameter of the first lens and the second distortion parameter of the second lens; determine an adjustment coefficient corresponding to the second key point group in the second imaging data according to the first distortion parameter and the second distortion parameter;

[0090] Based on the position of the first key point group in the first imaging data and the adjustment coefficient, adjust the position of the second key point group in the second imaging data to obtain target image data.

[0091] In an implementable embodiment, the second imaging data includes the facial key point positions of the target object and the lens position parameters of the second lens; the key point position adjustment module 502 is specifically configured to adjust each facial key point position in the second imaging data according to the first key point group position in the first imaging data to obtain the corrected facial key point information; and construct a facial image of the target object as the target image based on the corrected facial key point information and the lens position parameters.

[0092] In an implementable embodiment, the acquisition time interval between the first imaging data and the second imaging data is less than a preset time interval.

[0093] According to an embodiment of the present disclosure, the present disclosure provides an electronic device, including:

[0094] A first lens;

[0095] A second lens;

[0096] At least one processor; and

[0097] A memory communicatively connected to the at least one processor; wherein,

[0098] The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to acquire first imaging data collected by the first lens and second imaging data collected by the second lens, and adjust the second key point group position in the second imaging data based on the first key point group position in the first imaging data to obtain target image data; wherein, the focal length of the first lens is different from the focal length of the second lens; the first key point group position is the key point position corresponding to the target object included in the first imaging data; and the second key point group position is the key point position corresponding to the target object included in the second imaging data.

[0099] In an implementable embodiment, the focal length of the second lens is greater than the focal length of the first lens.

[0100] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device and a readable storage medium.

[0101] Figure 6FIG. 0 shows a schematic block diagram of an exemplary electronic device 600 that can be used to implement embodiments of the present disclosure. The electronic device is intended to represent various forms of digital computers, such as, for example, laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as, for example, personal digital processors, cellular telephones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely exemplary and are not intended to limit the implementations of the present disclosure described and / or claimed herein.

[0102] As Figure 6 shown, the device 600 includes a computing unit 601 that can perform various appropriate actions and processes in accordance with a computer program stored in a read-only memory (ROM) 602 or a computer program loaded from a storage unit 608 into a random access memory (RAM) 603. In the RAM 603, various programs and data required for the operation of the device 600 can also be stored. The computing unit 601, the ROM 602, and the RAM 603 are connected to each other via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.

[0103] A plurality of components in the device 600 are connected to the I / O interface 605, including: an input unit 606, such as a keyboard, a mouse, etc.; an output unit 607, such as various types of displays, speakers, etc.; a storage unit 608, such as a magnetic disk, an optical disk, etc.; and a communication unit 609, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 609 allows the device 600 to exchange information / data with other devices via a computer network such as the Internet and / or various telecommunication networks.

[0104] The computing unit 601 can be various general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 601 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 601 executes the various methods and processes described above, such as the image processing method. For example, in some embodiments, the image processing method can be implemented as a computer software program tangibly embodied in a machine-readable medium, such as the storage unit 608. In some embodiments, part or all of the computer program can be loaded and / or installed onto the device 600 via the ROM 602 and / or the communication unit 609. When the computer program is loaded into the RAM 603 and executed by the computing unit 601, one or more steps of the image processing method described above can be executed. Alternatively, in other embodiments, the computing unit 601 can be configured to execute the image processing method in any other suitable manner (e.g., by means of firmware).

[0105] The various embodiments of the systems and techniques described above in this document can be implemented in digital electronic circuitry, integrated circuit systems, field-programmable gate arrays (FPGA), application-specific integrated circuits (ASIC), application-specific standard products (ASSP), systems-on-chip (SOC), complex programmable logic devices (CPLD), computer hardware, firmware, software, and / or combinations thereof. These various embodiments can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a dedicated or general-purpose programmable processor that receives data and instructions from a storage system, at least one input device, and at least one output device, and transmits the data and instructions to the storage system, the at least one input device, and the at least one output device.

[0106] The program code for implementing the methods of the present disclosure can be written in any combination of one or more programming languages. These program codes can be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when the program codes are executed by the processor or controller, the functions / operations specified in the flowcharts and / or block diagrams are implemented. The program codes can be executed entirely on the machine, partially on the machine, as a stand-alone software package partially on the machine and partially on a remote machine, or entirely on a remote machine or server.

[0107] In the context of this disclosure, a machine-readable medium can be a tangible medium that can contain or store a program for use by or in connection with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or Flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0108] To provide for interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which the user can provide input to the computer. Other kinds of devices can also be used to provide for interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic, speech, or tactile input).

[0109] The systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer having a graphical user interface or a web browser through which the user can interact with an implementation of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), and the Internet.

[0110] A computer system can include a client and a server. The client and the server are generally remote from each other and typically interact through a communication network. The client-server relationship is created by computer programs running on the respective computers and having a client-server relationship to each other. The server can be a cloud server, can also be a server of a distributed system, or a server incorporating a blockchain.

[0111] It should be understood that the various forms of processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in the present disclosure can be executed in parallel, sequentially, or in a different order, as long as the desired results of the technical solutions disclosed in the present disclosure can be achieved, and no limitations are imposed herein.

[0112] In addition, the terms "first" and "second" are used only for descriptive purposes and should not be construed as indicating or implying relative importance or implicitly specifying the quantity of the indicated technical features. Thus, features defined with "first" and "second" may explicitly or implicitly include at least one of such features. In the description of the present disclosure, "a plurality" means two or more, unless otherwise specifically defined.

[0113] As described above, the above are only specific embodiments of the present disclosure, but the protection scope of the present disclosure is not limited thereto. Any person skilled in the art within the technical scope disclosed by the present disclosure can easily think of changes or substitutions, which should all be covered within the protection scope of the present disclosure. Therefore, the protection scope of the present disclosure should be subject to the protection scope of the claimed rights.

Claims

1. An image processing method, comprising: Acquire first imaging data acquired by the first lens and second imaging data acquired by the second lens; Adjusting the position of the second key point group in the second imaging data based on the position of the first key point group in the first imaging data to obtain target image data; Among them, the focal length of the first lens is different from the focal length of the second lens; the first key point group position is the key point position corresponding to the target object contained in the first imaging data; the second key point group position is the key point position corresponding to the target object contained in the second imaging data.

2. The method according to claim 1, wherein the distances between the key points in the first key point group have a first proportional relationship; The distances between the key points in the second key point group have a second proportional relationship; The first proportional relationship is different from the second proportional relationship.

3. The method according to claim 2, wherein adjusting the position of the second key point group of the target object in the second imaging data based on the position information of the first key point group of the target object in the first imaging data to obtain the target image data comprises: Based on the first proportional relationship between the distances between the key points in the first key point group, the second proportional relationship corresponding to the distances between the key points in the second key point group in the second imaging data is adjusted to obtain the target image data.

4. According to the method of claim 3, the distance between each key point in the third key point group has a fifth proportional relationship; the first proportional relationship is the same as the fifth proportional relationship; the position of the third key point group is the key point position corresponding to the target object contained in the target image data.

5. The method according to claim 4, wherein the first sub-key point has a first distance from the first reference key point; the second sub-key point has a second distance from the first reference key point; the third sub-key point has a third distance from the second reference key point; the fourth sub-key point has a fourth distance from the second reference key point; the first sub-key point, the second sub-key point, and the first reference key point belong to the third key point group; the third sub-key point, the fourth sub-key point, and the second reference key point belong to the second key point group; the key point of the target object represented by the first sub-key point is the same as the key point of the target object represented by the third sub-key point, the key point of the target object represented by the second sub-key point is the same as the key point of the target object represented by the fourth sub-key point, and the key point of the target object represented by the first reference key point is the same as the key point of the target object represented by the second reference key point; the first distance has a third proportional relationship with the third distance; the second distance has a fourth proportional relationship with the fourth distance, and the third proportional relationship is different from the fourth proportional relationship.

6. The method according to claim 1, wherein adjusting the position of the second key point group in the second imaging data based on the position of the first key point group in the first imaging data to obtain the target image data comprises: Acquire a first distortion parameter of the first lens and a second distortion parameter of the second lens; Determining an adjustment coefficient corresponding to a second key point group in the second imaging data according to the first distortion parameter and the second distortion parameter; Based on the position of the first key point group in the first imaging data and the adjustment coefficient, the position of the second key point group in the second imaging data is adjusted to obtain target image data.

7. The method according to claim 1, wherein the second imaging data comprises facial key point positions of the target object and lens position parameters of the second lens; The step of adjusting the position of the second key point group in the second imaging data based on the position of the first key point group in the first imaging data to obtain the target image data includes: adjusting the positions of the facial key points in the second imaging data according to the positions of the first key point group in the first imaging data to obtain corrected facial key point information; Based on the corrected facial key point information and the lens position parameters, a facial image of the target object is constructed as a target image. 8 . The method according to claim 1 , wherein a time interval between collecting the first imaging data and collecting the second imaging data is less than a preset time interval.

9. An electronic device, comprising: First shot; Second shot; at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the acquisition of first imaging data captured by a first lens and second imaging data captured by a second lens, and adjust the second key point group position in the second imaging data based on the first key point group position in the first imaging data to obtain target image data; wherein the focal length of the first lens is different from the focal length of the second lens; the first key point group position is the key point position corresponding to the target object contained in the first imaging data; and the second key point group position is the key point position corresponding to the target object contained in the second imaging data. 10 . The electronic device according to claim 9 , wherein a focal length of the second lens is greater than a focal length of the first lens.