Refrigerator internal image correction method, device and refrigerator based on wide-angle camera

By calculating the offset between the edge curve of the refrigerator partition beam and the tangent line, the internal pictures of the refrigerator are corrected, which solves the distortion problem during wide-angle camera shooting and improves the user's sensory experience.

CN113920017BActive Publication Date: 2025-02-18QINDAO HAIER REFRIGERATOR CO LTD +1
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202010658119.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-07-09
Publication Date
2025-02-18
Estimated Expiration
2040-07-09

AI Technical Summary

Technical Problem

A wide-angle camera will cause distortion when taking photos of the food inside the refrigerator, resulting in poor sensory effects of the user.

Method used

By obtaining the edge curve of the refrigerator partition beam near the door body and the tangent line of the lowest pixel point, the offset of each pixel point is calculated, and all pixel points in the picture are corrected according to the offset to obtain the corrected picture.

Benefits of technology

It reduces the distortion of the pictures inside the refrigerator, makes the user's experience more intuitive and comfortable, and improves the user's visual experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113920017B_ABST
    Figure CN113920017B_ABST
Patent Text Reader

Abstract

The present invention discloses a method, device and storage medium for correcting pictures of the inside of a refrigerator based on a wide-angle camera, the method comprising: arbitrarily selecting a pixel point in the picture to be corrected as the center point, obtaining the edge curve y=f1(x) of the refrigerator partition beam close to the door body in the picture; obtaining the tangent y=f2(x) of the lowest pixel point of the edge curve; calculating the offset d=f1(x)-f2(x) of each pixel point in the same vertical direction between the edge curve and the tangent; and correcting all the pixels of the picture according to the offset d to obtain a corrected picture. Compared with the prior art, the method for correcting pictures of the inside of a refrigerator based on a wide-angle camera of the present invention reduces the distortion to a level that is not easily perceived by the user by correcting the obvious basis for the user to judge the distortion (partition beam), thereby improving the user's perception.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of household appliance control, and in particular to a method and device for correcting an image of the inside of a refrigerator based on a wide-angle camera, and a refrigerator. Background Art

[0002] A wide-angle camera is a camera with a shorter focal length than a standard camera, a larger viewing angle than a standard camera, a longer focal length than a fisheye camera, and a smaller viewing angle than a fisheye camera. Since a wide-angle camera has a short focal length and a large viewing angle, it can capture a larger area of ​​scenery within a shorter shooting distance. Therefore, a wide-angle camera is generally used in a refrigerator to capture food in the refrigerator.

[0003] However, photos taken with a wide-angle camera will be distorted, and the distorted photos of food give users a relatively poor sensory effect. Summary of the invention

[0004] The object of the present invention is to provide a method, device and refrigerator for correcting the interior image of a refrigerator based on a wide-angle camera.

[0005] To achieve one of the above-mentioned purposes of the invention, an embodiment of the present invention provides a method for correcting a picture of the interior of a refrigerator based on a wide-angle camera, the method comprising:

[0006] A pixel point in the image to be corrected is randomly selected as the center point, and an edge curve y=f1(x) of the refrigerator partition beam close to the door body in the image is obtained;

[0007] Obtain the tangent line y=f2(x) of the lowest pixel point of the edge curve;

[0008] Calculate the offset d=f1(x)-f2(x) of each pixel point between the edge curve and the tangent line in the same vertical direction;

[0009] According to the offset d, all pixels of the image are corrected to obtain a corrected image.

[0010] As a further improvement of an embodiment of the present invention, the method includes:

[0011] A left-right symmetrical picture of the refrigerator partition beam is obtained as the picture to be corrected.

[0012] As a further improvement of an embodiment of the present invention, the method includes:

[0013] A left-right symmetrical picture of the partition beam is obtained at a position that is the same distance from the left and right edges of the partition beam.

[0014] As a further improvement of an embodiment of the present invention, the method includes:

[0015] After obtaining the picture of the interior of the refrigerator, the left-right symmetrical part of the partition beam in the picture is cropped to obtain a left-right symmetrical picture of the partition beam.

[0016] As a further improvement of an embodiment of the present invention, the “correcting all pixels of the image according to the offset d” specifically includes:

[0017] The pixel points of the edge curve and all the pixel points of the image have the same value range on the X-axis;

[0018] Move all pixels of the image downward in the vertical direction by a distance d.

[0019] As a further improvement of an embodiment of the present invention, the “correcting all pixels of the image according to the offset d” specifically includes:

[0020] The pixel value range of the edge curve on the X-axis is [a, b];

[0021] The value range of all pixels of the image on the X-axis is [c, d], where c is less than a and d is greater than b;

[0022] Move the pixel points of the image whose value range on the X-axis is [a, b] downward in the vertical direction by a distance d;

[0023] Move the pixel points of the image whose value range on the X-axis is [c, a) downward in the vertical direction by a distance D1, where D1 is the offset of the pixel points of the edge curve when the value on the X-axis is a;

[0024] The pixel points of the image whose value range on the X-axis is (b, d] are moved downward in the vertical direction by a distance D2, where D2 is the offset of the pixel points of the edge curve when the value on the X-axis is b.

[0025] As a further improvement of an embodiment of the present invention, the “obtaining the edge curve y=f1(x) of the refrigerator partition beam close to the door body in the picture” specifically includes:

[0026] The Candy operator is used to detect the edge of the refrigerator partition in the image, and the edge curve y=f1(x) of the refrigerator partition beam close to the door body is obtained.

[0027] As a further improvement of an embodiment of the present invention, the step of “obtaining a tangent line y=f2(x) of the lowest pixel point of the edge curve” specifically includes:

[0028] Calculate the pixel point Y0 corresponding to the minimum value of the edge curve on the y-axis;

[0029] A tangent line is drawn to the edge curve at the position of the pixel point Y0 to obtain a tangent line y=f2(x).

[0030] To achieve one of the above-mentioned purposes of the invention, one embodiment of the present invention provides an electronic device, including a memory and a processor, wherein the memory stores a computer program that can be run on the processor, and when the processor executes the program, it implements the steps in any one of the above-mentioned methods for correcting the interior image of a refrigerator based on a wide-angle camera.

[0031] To achieve one of the above-mentioned objects of the invention, an embodiment of the present invention provides a refrigerator, wherein the refrigerator includes the electronic device as described above.

[0032] Compared with the prior art, the refrigerator interior image correction method based on the wide-angle camera of the present invention reduces the distortion to a level that is not easily noticed by the user by correcting the obvious basis for the user to judge the distortion (partition beam), thereby improving the user's viewing experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0033] Figure 1 It is a flow chart of a refrigerator interior picture correction method based on a wide-angle camera of the present invention.

[0034] Figure 2 It is a schematic diagram of the structure of a refrigerator.

[0035] Figure 3 It is a schematic diagram of the principle structure of the refrigerator interior image correction method based on a wide-angle camera of the present invention.

[0036] Figure 4 It is a coordinate diagram of the edge curve in the refrigerator interior picture correction method based on the wide-angle camera of the present invention.

[0037] Figure 5 It is a structural schematic diagram of a partition beam after correction using the refrigerator interior image correction method based on a wide-angle camera of the present invention. DETAILED DESCRIPTION

[0038] The present invention will be described in detail below in conjunction with the specific embodiments shown in the accompanying drawings. However, these embodiments do not limit the present invention, and any structural, methodological, or functional changes made by a person skilled in the art based on these embodiments are all within the scope of protection of the present invention.

[0039] like Figure 1 As shown, the present invention provides a method for correcting a picture of the inside of a refrigerator based on a wide-angle camera, wherein the method corrects the obvious basis for the user to judge the distortion (partition beam), so as to reduce the distortion to a level that is not easily perceived by the user, thereby improving the user's perception. The method comprises:

[0040] Step S100: arbitrarily select a pixel point in the image to be corrected as the center point, and obtain the edge curve y=f1(x) of the refrigerator partition beam close to the door body in the image.

[0041] The partition 10 and the partition beam 11 of the refrigerator are as shown in FIG. Figure 2 As shown, the image detection algorithm is used to obtain the position of the refrigerator partition beam 11, and then the edge curve y=f1(x) of the partition beam 11 close to the door body is obtained. The edge curve is as follows Figure 3 As shown in 111, the x-axis and y-axis of the curve are as follows Figure 3 As shown in the upper right corner of , the x-axis is the horizontal axis and the y-axis is the vertical axis.

[0042] Preferably, the Candy operator is used to detect the edge of the refrigerator partition beam in the image to obtain the edge curve y=f1(x) of the refrigerator partition close to the door body.

[0043] The Canny operator, also called the Canny edge detection operator, is a multi-level edge detection algorithm developed by John F. Canny in 1986. It is one of the most classic and advanced algorithms in image edge detection algorithms. This is an existing technology and will not be described in detail here.

[0044] It should be noted that the partition beam 11 of the refrigerator in the image to be corrected is bilaterally symmetrical. Therefore, in a preferred embodiment, the method further includes:

[0045] A left-right symmetrical picture of the refrigerator partition beam is obtained as the picture to be corrected.

[0046] Specifically, the image to be corrected may be obtained in the following two ways, but is not limited to the following two ways.

[0047] Method 1: Obtain a left-right symmetrical image of the partition beam at a position that is the same distance from the left and right edges of the partition beam. That is, install the wide-angle camera inside the refrigerator, and the wide-angle camera is the same distance from the left and right edges of the partition beam, such as installing it in the middle of the top of the door body, or installing it at the top of the inner side of the refrigerator body close to the door body.

[0048] Method 2: After obtaining a picture of the interior of the refrigerator, crop the left-right symmetrical part of the partition beam in the picture to obtain a left-right symmetrical picture of the partition beam. This method has relatively few requirements for the installation of a wide-angle camera, as long as the partition beam of the refrigerator can be photographed. After obtaining a picture including the partition beam, crop the picture to ensure that the partition beam is in a left-right symmetrical state.

[0049] Step S200: Obtain the tangent line y=f2(x) of the lowest pixel point of the edge curve.

[0050] The tangent line is Figure 3 As shown in 112, specifically, the pixel point Y0 corresponding to the minimum value of the edge curve on the y-axis is calculated; a tangent line is drawn to the edge curve at the position of the pixel point Y0 to obtain a tangent line equation y=f2(x). Generally, the tangent line is a straight line parallel to the X-axis.

[0051] Step S300: Calculate the offset d=f1(x)-f2(x) of each pixel point between the edge curve and the tangent line in the same vertical direction.

[0052] That is, the offset d on the y-axis of each pixel point on the edge curve y=f1(x) and the pixel point with the same x-axis value on the tangent line y=f2(x) is calculated. Figure 3 As shown in d.

[0053] Step S400: Correct all pixels of the image according to the offset d to obtain a corrected image.

[0054] The value range of the pixel points of the edge curve on the X-axis is compared with the value range of all the pixel points of the image to be corrected on the X-axis, and then it is determined how all the pixel points of the image to be corrected should be moved.

[0055] In a specific implementation, the pixel points of the edge curve and all the pixel points of the image to be corrected have the same value range on the X-axis, and all the pixel points of the image are moved downward in the vertical direction by a distance d.

[0056] Since the value of each pixel point on the edge curve y=f1(x) on the x-axis is different, the corresponding offsets may be the same or different. Assuming that the values ​​of the pixels on the edge curve y=f1(x) on the x-axis include {x1, x2, ..., xn}, and the corresponding offsets are {d1, d2, ..., dn}, then the pixel point with the x-axis value of x1 in the pixel points of the image to be corrected is moved downward by d1 in the vertical direction (y-axis); the pixel point with the x-axis value of x2 in the pixel points of the image to be corrected is moved downward by d2 in the vertical direction (y-axis); and so on, the pixel point with the x-axis value of xn in the pixel points of the image to be corrected is moved downward by dn in the vertical direction (y-axis).

[0057] like Figure 4As shown, in another specific embodiment, the value range of the pixel points of the edge curve on the X-axis is included in the value range of all the pixel points of the to-be-corrected image on the X-axis, that is, assuming that the value range of the pixel points of the edge curve on the X-axis is [a, b], the value range of all the pixel points of the to-be-corrected image on the X-axis is [c, d], where c is less than a and d is greater than b; the pixel points of the image in the value range of [a, b] on the X-axis are moved downward by a distance d in the vertical direction; the pixel points of the image in the value range of [c, a) on the X-axis are moved downward by a distance D1 in the vertical direction, where D1 is the offset of the pixel points of the edge curve when the value of the pixel points on the X-axis is a; the pixel points of the image in the value range of (b, d] on the X-axis are moved downward by a distance D2 in the vertical direction, where D2 is the offset of the pixel points of the edge curve when the value of the pixel points on the X-axis is b.

[0058] In a specific embodiment, a wide-angle camera is set in the middle of the upper part of the refrigerator door (i.e., on the left-right symmetry axis), and a photo taken by the wide-angle camera is obtained as the image to be corrected. The Candy operator is used to detect the edge of the refrigerator partition in the image to be corrected, and the edge curve y=f1(x) of the refrigerator partition beam close to the door body is obtained. Calculate the pixel point Y0 corresponding to the minimum value of the edge curve on the y-axis; make a tangent to the edge curve at the position of the pixel point Y0 to obtain the tangent equation y=f2(x). Calculate the offset d on the y-axis for each pixel on the edge curve y=f1(x) that has the same value on the x-axis as the pixel on the tangent y=f2(x). That is, the values ​​of the pixels on the edge curve y=f1(x) on the x-axis include {x1, x2, ..., xn}, and the corresponding offset is {d1, d2, ..., dn}, then the pixel with the x-axis value x1 in the pixel points of the image to be corrected is moved downward by d1 in the vertical direction (y-axis); the pixel with the x-axis value x2 in the pixel points of the image to be corrected is moved downward by d2 in the vertical direction (y-axis); and so on, the pixel with the x-axis value xn in the pixel points of the image to be corrected is moved downward by dn in the vertical direction (y-axis). For the pixel points in the image to be corrected whose values ​​on the x-axis are not covered by the values ​​of the edge curve on the x-axis, if they are located on the left side of the edge curve, they are moved downward by a distance D1 in the vertical direction, where D1 is the offset when the pixel points of the edge curve on the x-axis have the smallest value. If the pixel point is located on the right side of the edge curve, it is moved downward in the vertical direction by a distance D2, where D2 is the maximum offset of the pixel point of the edge curve on the X-axis.

[0059] Figure 5This is a picture corrected using the refrigerator interior picture correction method based on a wide-angle camera of the present invention. It can be seen from the figure that the distorted shape of the refrigerator partition beam has been corrected, so that the obvious basis for users to judge the distortion (partition beam) is corrected, and the distortion is reduced to a level that is not easily noticeable to users, thereby improving the user's viewing experience.

[0060] The present invention also provides an electronic device, comprising a memory and a processor, wherein the memory stores a computer program that can be run on the processor, and when the processor executes the program, it implements any one of the steps in the above-mentioned method for correcting the interior image of a refrigerator based on a wide-angle camera, that is, it implements the steps in any one of the technical solutions in the above-mentioned method for correcting the interior image of a refrigerator based on a wide-angle camera.

[0061] The present invention also provides a refrigerator, which comprises the electronic device described above.

[0062] It should be understood that although this specification is described according to implementation modes, not every implementation mode contains only one independent technical solution. This description of the specification is only for the sake of clarity. Those skilled in the art should regard the specification as a whole. The technical solutions in each implementation mode may also be appropriately combined to form other implementation modes that can be understood by those skilled in the art.

[0063] The series of detailed descriptions listed above are only specific descriptions of feasible implementation methods of the present invention. They are not intended to limit the scope of protection of the present invention. Any equivalent implementation methods or changes that do not deviate from the technical spirit of the present invention should be included in the scope of protection of the present invention.

Claims

1. A method for correcting an image of the inside of a refrigerator based on a wide-angle camera, characterized in that: The method comprises: A pixel point in the image to be corrected is randomly selected as the center point, and an edge curve y=f1(x) of the refrigerator partition beam close to the door body in the image is obtained; Obtain the tangent line y=f2(x) of the lowest pixel point of the edge curve; Calculate the offset d=f1(x)-f2(x) of each pixel point between the edge curve and the tangent line in the same vertical direction; According to the offset d, all pixels of the image are corrected to obtain a corrected image; If the pixel points of the edge curve and all the pixel points of the image have the same value range on the X-axis, move all the pixel points of the image downward by a distance d in the vertical direction; If the value range of the pixel points of the edge curve on the X-axis is [a, b], and the value range of all the pixel points of the image on the X-axis is [c, d], where c is less than a and d is greater than b, the pixel points of the image in the value range of [a, b] on the X-axis are moved downward by a distance d in the vertical direction, and the pixel points of the image in the value range of [c, a) on the X-axis are moved downward by a distance D1 in the vertical direction, where D1 is the offset of the pixel points of the edge curve when the value of the pixel points on the X-axis is a, and the pixel points of the image in the value range of (b, d] on the X-axis are moved downward by a distance D2 in the vertical direction, where D2 is the offset of the pixel points of the edge curve when the value of the pixel points on the X-axis is b.

2. The refrigerator interior image correction method based on a wide-angle camera according to claim 1, characterized in that: The method comprises: A left-right symmetrical picture of the refrigerator partition beam is obtained as the picture to be corrected.

3. The refrigerator interior image correction method based on a wide-angle camera according to claim 2, characterized in that: The method comprises: A left-right symmetrical picture of the partition beam is obtained at a position that is the same distance from the left and right edges of the partition beam.

4. The refrigerator interior image correction method based on a wide-angle camera according to claim 2, characterized in that: The method comprises: After obtaining the picture of the interior of the refrigerator, the left-right symmetrical part of the partition beam in the picture is cropped to obtain a left-right symmetrical picture of the partition beam.

5. The refrigerator interior image correction method based on a wide-angle camera according to claim 1, characterized in that: The "obtaining the edge curve y=f1(x) of the refrigerator partition beam close to the door body in the picture" specifically includes: The Candy operator is used to detect the edge of the refrigerator partition in the image, and the edge curve y=f1(x) of the refrigerator partition beam close to the door body is obtained.

6. The refrigerator interior image correction method based on a wide-angle camera according to claim 1, characterized in that: The "obtaining the tangent line y=f2(x) of the lowest pixel point of the edge curve" specifically includes: Calculate the pixel point Y0 corresponding to the minimum value of the edge curve on the y-axis; A tangent line is drawn to the edge curve at the position of the pixel point Y0 to obtain a tangent line y=f2(x).

7. An electronic device comprising a memory and a processor, wherein the memory stores a computer program that can be run on the processor, characterized in that: When the processor executes the program, the steps in the refrigerator interior image correction method based on a wide-angle camera as described in any one of claims 1-6 are implemented.

8. A refrigerator, characterized in that: The refrigerator comprises the electronic device according to claim 7.

Citation Information

Patent Citations

  • Image distortion compensation method

    JP2008287430A