A method, apparatus, medium, and device for detecting a position offset of an image sensor

By automatically detecting the positional offset of the image sensor and using reference data and contour determination functions, the problem of low efficiency in manual measurement is solved, and efficient and accurate positional offset detection is achieved.

CN117078747BActive Publication Date: 2026-04-14KUNSHAN QIUTI PHOTOELECTRIC TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
KUNSHAN QIUTI PHOTOELECTRIC TECH CO LTD
Filing Date
2023-08-11
Publication Date
2026-04-14

AI Technical Summary

Technical Problem

In existing technologies, image sensor position offset detection relies on manual measurement, resulting in low detection efficiency and low accuracy.

Method used

By acquiring the image to be tested, the target marker point and the actual center point are determined based on the reference data of the image sensor. Automatic detection is performed using the contour determination function, and the position offset is calculated.

Benefits of technology

It improves detection efficiency, reduces errors introduced by manual operation, and improves detection accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117078747B_ABST
    Figure CN117078747B_ABST
Patent Text Reader

Abstract

The application provides a method, device, medium and equipment for detecting position deviation of an image sensor, the method comprising: acquiring a to-be-detected picture; the to-be-detected picture is a picture of the image sensor after bonding; determining a target mark point in the to-be-detected picture and an actual center point of the image sensor contour based on reference data of the image sensor; and detecting the position deviation of the image sensor according to the target mark point in the to-be-detected picture and the actual center point of the image sensor contour. Thus, the target mark point of the to-be-detected picture and the actual center point of the image sensor contour in the to-be-detected picture are determined, and the position deviation of the image sensor is automatically detected according to the target mark point and the actual center point. Compared with the manual measurement method, the detection efficiency can be improved, the detection error caused by manual operation can be reduced, and the detection accuracy can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of image sensor detection technology for camera modules, and in particular to a method, apparatus, medium and device for detecting the positional offset of an image sensor. Background Technology

[0002] The camera module undergoes multiple processing steps during production. One such step involves using die bonding (DB) to fix the image sensor to the substrate, establishing an electrical connection between the image sensor and the substrate.

[0003] During the bonding process, metal leads need to be connected to the pads of the image sensor to achieve bonding. During bonding, the image sensor's position may shift, which can lead to substandard images captured by the camera module. Therefore, to ensure the subsequent image quality of the camera module, the image sensor's position needs to be checked after bonding.

[0004] In existing technologies, the offset of the image sensor is usually measured manually, which is time-consuming and labor-intensive, resulting in low detection efficiency. Summary of the Invention

[0005] To address the problems existing in the prior art, embodiments of the present invention provide a method, apparatus, medium, and device for detecting the positional offset of an image sensor, so as to solve or partially solve the technical problem that the time-consuming and labor-intensive process of manually detecting the position of an image sensor in the prior art leads to reduced detection efficiency.

[0006] A first aspect of the present invention provides a method for detecting positional offset of an image sensor, the method comprising:

[0007] Acquire a test image, which is an image captured by the bonded image sensor;

[0008] Based on the reference data of the image sensor, the target marker points in the image to be tested and the actual center point of the image sensor contour are determined.

[0009] The positional offset of the image sensor is detected based on the target marker points in the image to be tested and the actual center point of the image sensor contour.

[0010] In the above scheme, determining the target marker points in the image to be tested based on the reference data of the image sensor includes:

[0011] The target marker diameter, target ratio, and reference distance between target markers are obtained from the reference data; the target ratio is the ratio between the actual size of the image sensor and the number of pixels in the image to be measured.

[0012] The radius range of the target marker point is determined based on the diameter of the target marker point and the target ratio.

[0013] The contour of the first marker point is extracted from the image under test using a contour determination function.

[0014] The first marker point contour is filtered based on the radius range of the target marker point and the first contour aspect ratio threshold to obtain the second marker point contour;

[0015] The distance range of the target marker points is determined based on the reference distance between the target marker points;

[0016] The second marker point contour is filtered based on the distance range and the reference center point of the image sensor contour to obtain the third marker point contour;

[0017] Determine the first distance between any two third marker point contours, obtain the distance difference between the first distance and the reference distance, and determine the two third marker point contours corresponding to the minimum distance difference as the target marker points.

[0018] In the above scheme, determining the radius range of the target marker point based on the diameter of the marker point and the target ratio includes:

[0019] Determine the quotient of the ratio of the diameter of the marker point to the target, and determine half of the quotient as the radius of the target marker point;

[0020] The radius range is determined based on the radius of the target marker point; the radius range is (0.7R, 1.2R); where R is the radius of the target marker point.

[0021] In the above scheme, the step of filtering the second marker point contour based on the distance range and the reference center point of the image sensor contour to obtain the third marker point contour includes:

[0022] The range of the center point is determined based on the reference center point of the image sensor contour;

[0023] For the current second marker point profile, determine the midpoint between the current second marker point profile and the reference second marker point profile; the reference second marker point profile is any second marker point profile other than the current second marker point profile.

[0024] The current second marker profile that meets the filtering criteria is determined as the third marker profile; the filtering criteria are: the midpoint of the line connecting the current second marker profile and the reference second marker profile is within the range of the center point, and the second distance between the current second marker profile and the reference second marker profile is within the distance range.

[0025] In the above scheme, determining the actual center point of the image sensor contour based on the reference data of the image sensor includes:

[0026] The length of the image sensor profile in the X direction, the length of the image sensor profile in the Y direction, and the target ratio are obtained from the reference data; the target ratio is the ratio between the actual size of the image sensor and the number of pixels in the image to be measured.

[0027] The reference width of the image sensor profile is determined based on the length of the image sensor profile in the X direction and the target ratio; the reference height of the image sensor profile is determined based on the length of the image sensor profile in the Y direction and the target ratio.

[0028] The area range of the image sensor contour is determined based on the reference width and the reference height;

[0029] Extract the contours of each rectangle using the contour determination function;

[0030] The rectangular contour is filtered based on the area range of the image sensor contour, the aspect ratio threshold of the second contour, and the reference center point of the image sensor contour to obtain the reference contour.

[0031] For any reference contour, obtain the area difference between the area of ​​the reference contour and the reference area of ​​the image sensor contour, and determine the reference contour corresponding to the minimum area difference as the image sensor contour.

[0032] Obtain the actual center point of the image sensor profile.

[0033] In the above scheme, the positional offset includes: distance offset and angle offset; the detection of the positional offset of the image sensor based on the target marker points in the image to be tested and the actual center point of the image sensor contour includes:

[0034] Determine the midpoint between two target marker points, and obtain the x-coordinate and y-coordinate of the midpoint;

[0035] The first distance offset compensation value of the image sensor profile in the X direction and the second distance offset compensation value of the image sensor profile in the Y direction are obtained from the reference data.

[0036] The reference horizontal coordinate of the image sensor is determined based on the midpoint horizontal coordinate and the first distance offset compensation value; the reference vertical coordinate of the image sensor is determined based on the midpoint horizontal coordinate and the second distance offset compensation value.

[0037] The actual horizontal and vertical coordinates of the image sensor contour are determined based on the actual center point.

[0038] The horizontal coordinate offset distance is determined based on the reference horizontal coordinate and the actual horizontal coordinate, and the vertical coordinate offset distance is determined based on the reference vertical coordinate and the actual vertical coordinate.

[0039] If it is determined that the horizontal coordinate offset distance is less than a preset horizontal coordinate offset threshold, and it is determined that the vertical coordinate offset distance is less than a preset vertical coordinate offset threshold, then the distance offset of the image sensor is determined to be qualified.

[0040] In the above scheme, the positional offset includes: distance offset and angle offset; the detection of the positional offset of the image sensor based on the target marker points in the image to be tested and the actual center point of the image sensor contour includes:

[0041] Determine the midpoint between two target marker points, and establish a first coordinate system with the midpoint as the origin;

[0042] Determine the actual angle of the actual center point in the first coordinate system; the actual angle is the angle between the line connecting the actual center point and the origin of the first coordinate system and the X-axis of the first coordinate system.

[0043] A second coordinate system is established with the reference center point of the image to be tested as the origin;

[0044] The reference angle of the reference center point in the second coordinate system is determined based on the first distance offset compensation value of the image sensor profile in the X direction and the second distance offset compensation value of the image sensor profile in the Y direction;

[0045] If the angle difference between the actual angle and the reference angle is determined to be less than a preset angle threshold, then the angle offset of the image sensor is determined to be qualified.

[0046] A second aspect of the present invention provides an apparatus for detecting positional offset of an image sensor, the apparatus comprising:

[0047] An acquisition unit is used to acquire an image to be tested; the image to be tested is an image captured by the bonded image sensor.

[0048] The determining unit is used to determine the target marker points in the image to be tested and the actual center point of the image sensor contour based on the reference data of the image sensor;

[0049] The detection unit is used to detect the positional offset of the image sensor based on the target marker points in the image to be tested and the actual center point of the image sensor contour.

[0050] A third aspect of the present invention provides a computer-readable storage medium having a computer program stored thereon that, when executed by a processor, implements the steps of the method described in any of the first aspects.

[0051] A fourth aspect of the present invention provides a computer device including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the program, implements the steps of the method described in any of the first aspects.

[0052] This invention provides a method, apparatus, medium, and device for detecting the positional offset of an image sensor. The method includes: acquiring a test image; the test image is an image captured of a bonded image sensor; determining target marker points and the actual center point of the image sensor contour in the test image based on reference data of the image sensor; and detecting the positional offset of the image sensor based on the target marker points and the actual center point of the image sensor contour in the test image. Thus, by determining the target marker points and the actual center point of the image sensor contour in the test image, automatic detection can be performed based on the positional offset of the target marker points, the actual center point, and the image sensor. Compared with manual measurement, this improves detection efficiency and reduces detection errors caused by manual operation, thereby improving detection accuracy. Attached Figure Description

[0053] Various other advantages and benefits will become apparent to those skilled in the art upon reading the following detailed description of preferred embodiments. The accompanying drawings are for illustrative purposes only and are not intended to limit the invention. Furthermore, the same reference numerals denote the same parts throughout the drawings.

[0054] In the attached diagram:

[0055] Figure 1 A schematic flowchart of a method for detecting the positional offset of an image sensor according to an embodiment of the present invention is shown;

[0056] Figure 2 A schematic diagram of a test image is shown according to an embodiment of the present invention;

[0057] Figure 3 A schematic diagram of target marker points and image sensor outline according to an embodiment of the present invention is shown;

[0058] Figure 4 A schematic diagram of a device for detecting the positional offset of an image sensor according to an embodiment of the present invention is shown;

[0059] Figure 5 A schematic diagram of a computer device structure according to an embodiment of the present invention is shown;

[0060] Figure 6 A schematic diagram of a computer-readable storage medium structure according to an embodiment of the present invention is shown. Detailed Implementation

[0061] Exemplary embodiments of the present disclosure will now be described in more detail with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be implemented in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.

[0062] This invention provides a method for detecting the positional offset of an image sensor, such as... Figure 1 As shown, the method mainly includes the following steps:

[0063] S110, acquire the image to be tested; the image to be tested is an image captured by the bonded image sensor;

[0064] After the image sensor is bonded to the substrate, this embodiment requires taking an image of the bonded image sensor to obtain the image to be tested. For example... Figure 2 As shown, the image to be tested contains both the image sensor region 21 and the substrate region 22.

[0065] S111, Based on the reference data of the image sensor, determine the target marker points in the image to be tested and the actual center point of the image sensor contour;

[0066] In this embodiment, the reference data of the image sensor mainly includes: the storage path of the image to be tested, the length of the image sensor contour in the X direction (Area_X), the length of the image sensor contour in the Y direction (Area_Y), the first distance offset compensation value (Offset_X) of the image sensor contour in the X direction, the second distance offset compensation value (Offset_Y) of the image sensor contour in the Y direction, the diameter of the target marker (Mark_Diameter), the straight-line distance between two target markers (Mark_Distance), and the target ratio (Area_Rate) between the actual size of the image sensor and the number of pixels in the image to be tested.

[0067] The target ratio is measured in pixels per micrometer (μm). Since the actual size of the image sensor is μm, it needs to be converted into pixel count for calculation. Therefore, when the target ratio is known, the actual size of the image sensor can be converted into the corresponding pixel count based on the target ratio.

[0068] In practical applications, users can input the reference data of the image sensor in advance into the device for detecting the positional offset of the image sensor. This allows the device to use the reference data to determine the target marker point and the actual center point of the image sensor profile.

[0069] In one implementation, determining target marker points in the image to be tested based on reference data from an image sensor includes:

[0070] Obtain the target marker diameter, target ratio, and reference distance between target markers from the baseline data; the target ratio is the ratio between the actual size of the image sensor and the number of pixels in the image under test.

[0071] Determine the radius range of the target marker point based on the diameter of the marker point and the target ratio;

[0072] The contour of the first marker point is extracted from the image under test using a contour determination function.

[0073] The first marker point contour is filtered based on the radius range of the target marker point and the aspect ratio of the first contour to obtain the second marker point contour;

[0074] Determine the distance range of the target markers based on the baseline distance between them;

[0075] The second marker point contour is filtered based on the distance range and the reference center point of the image sensor contour to obtain the third marker point contour;

[0076] Determine the first distance between any two third marker point profiles, and obtain the distance difference between the first distance and the reference distance; determine the two third marker point profiles corresponding to the minimum distance difference as target marker points.

[0077] In one implementation, determining the radius range of the target marker point based on the marker point diameter and the target ratio includes:

[0078] Determine the quotient of the ratio of the diameter of the marker point to the target, and use half of the quotient as the radius of the target marker point;

[0079] The radius range is determined based on the radius of the target marker point; the radius range is (0.7R, 1.2R); R is the radius of the target marker point.

[0080] Specifically, the radius R of the target marker point can first be determined according to formula (1):

[0081] R= Mark_Diameter / 2*Area_Rate (1)

[0082] In formula (1), Mark_Diameter is the diameter of the marker point, and Area_Rate is the target ratio.

[0083] Then, the bitwise_not function is used to invert the brightness values ​​of the image under test (which can be understood as converting black to white and white to black). Then, the contour determination function is used to find the contour of the first marker point in the image under test after the inversion operation. An ellipse fitting operation is performed on each contour of the first marker point, and the aspect ratio of each contour of the first marker point is determined.

[0084] The first marker point contour is filtered based on the radius range of the target marker point and the first contour aspect ratio threshold. The first marker point contour that meets the first contour aspect ratio and whose contour radius is within the aforementioned determined radius range is determined as the second marker point contour. The first contour aspect ratio threshold is 0.9 to 1.1.

[0085] In one implementation, determining the distance range of the target markers based on the reference distance between target markers includes:

[0086] Determine the reference distance between the two target markers based on the baseline distance and the target ratio.

[0087] The distance range of the target marker is determined based on the reference distance; the distance range is (0.9D, 1.1D); D is the reference distance.

[0088] In this embodiment, the reference distance D between the two target marker points can be determined according to formula (2):

[0089] D=Area_Rate*Mark_Distance (2)

[0090] In formula (2), Area_Rate is the target ratio and Mark_Distance is the baseline distance between two target markers.

[0091] In one implementation, the second marker point contour is filtered based on a distance range and a reference center point of the image sensor contour to obtain a third marker point contour, including:

[0092] The range of the center point is determined based on the reference center point of the image sensor profile;

[0093] For the current second marker point profile, determine the midpoint between the current second marker point profile and the reference second marker point profile; the reference second marker point profile is any second marker point profile other than the current second marker point profile.

[0094] The current second marker point contour that meets the filtering conditions is determined as the third marker point contour; the filtering conditions are: the midpoint of the line connecting the current second marker point contour and the reference second marker point contour is within the center point range, and the second distance between the current second marker point contour and the reference second marker point contour is within the distance range.

[0095] For example, if the current second marker point profile is A, and the reference second marker point profile is B, determine the midpoint C between A and B and the second distance D1 between A and B; assuming that the coordinates of the midpoint C are within the range of the center point and D1 is within the range of the distance, then determine A and B as the third marker point profile.

[0096] The method for determining the range of the center point in this embodiment is as follows:

[0097] Obtain the coordinates of the reference center point of the image sensor contour, and determine the range of the center point based on the reference center point coordinates; the x-coordinate range of the center point is (2 / 3X0, 4 / 3X0), and the y-coordinate range of the center point is (2 / 3Y0, 4 / 3Y0). Where X0 is the x-coordinate of the reference center point, and Y0 is the y-coordinate of the reference center point.

[0098] In practical applications, the third marker point contour may contain multiple parts, so it is necessary to continue filtering the third marker point contour to determine the target marker point.

[0099] In this embodiment, the following is achieved when filtering the contour of the third target marker point:

[0100] For any two third marker point profiles, obtain the second distance between the two third marker point profiles, and determine the distance difference between the second distance and the reference distance;

[0101] There may be multiple distance differences. The two third marker points corresponding to the smallest distance difference are identified as the target marker points.

[0102] Among them, you can refer to Figure 3 The target markers include marker 31 and marker 32.

[0103] After the target markers are determined, it is also necessary to determine the actual center point of the image sensor contour.

[0104] In one implementation, determining the actual center point of the image sensor profile based on reference data from the image sensor includes:

[0105] Obtain the length of the image sensor profile in the X direction, the length of the image sensor profile in the Y direction, and the target ratio from the reference data; the target ratio is the ratio between the actual size of the image sensor and the number of pixels in the image to be measured.

[0106] The reference width of the image sensor is determined based on the length of the image sensor profile in the X direction and the target ratio; the reference height of the image sensor is determined based on the length of the image sensor profile in the Y direction and the target ratio.

[0107] The area range of the image sensor contour is determined based on the reference width and the reference height;

[0108] Extract the contours of each rectangle using the contour determination function;

[0109] The rectangular contour is filtered based on the area range of the image sensor contour, the aspect ratio threshold of the second contour, and the reference center point of the image sensor contour to obtain the reference contour.

[0110] For any reference contour, obtain the area difference between the area of ​​the reference contour and the reference area of ​​the image sensor contour, and determine the reference contour corresponding to the minimum area difference as the image sensor contour.

[0111] Obtain the actual center point of the image sensor profile.

[0112] Understandably, to determine the actual center point of the image sensor's outline, it is necessary to first determine the image sensor's outline. For example... Figure 3 As shown, since the image to be tested contains multiple rectangular outlines, it is necessary to filter these multiple rectangular outlines to determine the image sensor outline.

[0113] Specifically, the reference width W of the image sensor profile can be determined according to formula (3), and the reference height H of the image sensor profile can be determined according to formula (4):

[0114] W = Area_X * Area_Rate (3)

[0115] H = Area_Y * Area_Rate (4)

[0116] Where Area_X is the length of the image sensor contour in the X direction, Area_Y is the length of the image sensor contour in the Y direction, and Area_Rate is the target ratio.

[0117] Then, the area range of the image sensor contour is determined based on the reference width and reference height. The area range of the image sensor contour is (W*H*4 / 5, W*H*6 / 5).

[0118] After binarizing, Gaussian filtering, and normalizing the image to be tested, the contour determination function is used to extract the rectangular contours in the image to be tested, and the circumcircle of each rectangular contour is determined. The area of ​​the corresponding rectangular contour is calculated based on the circumcircle.

[0119] A rectangular contour whose area is within the area of ​​the image sensor contour, whose aspect ratio is less than the second contour aspect ratio threshold, and whose center point coordinates are within the aforementioned determined center point range is defined as a reference contour. The second contour aspect ratio threshold can be between 0.15 and 0.2.

[0120] There may be multiple reference contours. In this embodiment, it is necessary to continue to filter the reference contours to determine the image sensor contour.

[0121] For any reference contour, obtain the area difference between the area of ​​the reference contour and the reference area of ​​the image sensor contour, and determine the reference contour corresponding to the minimum area difference as the image sensor contour.

[0122] The reference area S of the image sensor contour can be determined according to formula (5):

[0123] S=Area_X*Area_Rate*Area_Y*Area_Rate (5)

[0124] In formula (5), Area_X is the length of the image sensor contour in the X direction, Area_Y is the length of the image sensor contour in the Y direction, and Area_Rate is the target ratio.

[0125] like Figure 3 As shown, the image sensor outline is marked 33. After the image sensor outline is determined, the actual center point of the image sensor outline can be directly obtained. The horizontal coordinate of the actual center point is sensor_center_x, and the vertical coordinate of the actual center point is sensor_center_y.

[0126] S112, the positional offset of the image sensor is detected based on the target marker points in the image to be tested and the actual center point of the image sensor contour.

[0127] In this embodiment, the positional offset of the image sensor includes distance offset and angular offset. When detecting distance offset, in one implementation, the positional offset of the image sensor is detected based on the target marker points in the image to be tested and the actual center point of the image sensor contour, including:

[0128] Determine the midpoint between two target marker points, and obtain the x-coordinate and y-coordinate of the midpoint;

[0129] Obtain the first distance offset compensation value of the image sensor profile in the X direction and the second distance offset compensation value of the image sensor profile in the Y direction from the reference data;

[0130] The reference horizontal coordinate of the image sensor is determined based on the midpoint horizontal coordinate and the first distance offset compensation value; the reference vertical coordinate of the image sensor is determined based on the midpoint horizontal coordinate and the second distance offset compensation value.

[0131] The actual horizontal and vertical coordinates of the image sensor contour are determined based on the actual center point.

[0132] The horizontal coordinate offset distance is determined based on the reference horizontal coordinate and the actual horizontal coordinate, and the vertical coordinate offset distance is determined based on the reference vertical coordinate and the actual vertical coordinate.

[0133] If the horizontal coordinate offset distance is determined to be less than the preset horizontal coordinate offset threshold, and the vertical coordinate offset distance is determined to be less than the preset vertical coordinate offset threshold, then the distance offset of the image sensor is determined to be qualified.

[0134] Specifically, the reference horizontal coordinate sensor_theory_x of the image sensor contour can be determined according to formula (6), and the reference vertical coordinate sensor_theory_y of the image sensor contour can be determined according to formula (7):

[0135] sensor_theory_x=mark_center_x+Offset_X*Area_Rate (6)

[0136] sensor_theory_y=mark_center_y+Offset_Y*Area_Rate (7)

[0137] Where, mark_center_x is the x-coordinate of the midpoint, mark_center_y is the y-coordinate of the midpoint, Offset_X is the first distance offset compensation value of the image sensor contour in the X direction, Offset_Y is the second distance offset compensation value of the image sensor contour in the Y direction, and Area_Rate is the target ratio.

[0138] Then, determine the horizontal coordinate offset distance diff_X according to formula (8), and determine the vertical coordinate offset distance diff_Y according to formula (9):

[0139] diff_X=(sensor_theory_x-sensor_center_x) / Area_Rate (8)

[0140] diff_Y=(sensor_center_y-sensor_theory_y) / Area_Rate (9)

[0141] Where sensor_center_x is the x-coordinate of the actual center point of the image sensor contour, sensor_center_y is the y-coordinate of the actual center point of the image sensor contour, sensor_theory_x is the x-coordinate of the actual center point, sensor_center_y is the y-coordinate of the actual center point, and Area_Rate is the target ratio.

[0142] Then, preset horizontal coordinate offset thresholds Spec_X and vertical coordinate offset thresholds Spec_Y are obtained from the reference data. If the absolute value of the horizontal coordinate offset distance is less than the absolute value of the horizontal coordinate offset threshold, and the absolute value of the vertical coordinate offset distance is also less than the absolute value of the vertical coordinate offset threshold, then the distance offset of the image sensor is determined to be qualified.

[0143] When detecting angular offset, in one implementation, the positional offset of the image sensor is detected based on the target marker points in the image to be tested and the actual center point of the image sensor contour, including:

[0144] Determine the midpoint between the two target markers, and establish a first coordinate system with the midpoint as the origin;

[0145] Determine the actual angle of the actual center point in the first coordinate system; the actual angle is the angle between the line connecting the actual center point and the origin of the first coordinate system and the X-axis of the first coordinate system.

[0146] A second coordinate system is established with the reference center point of the image to be tested as the origin;

[0147] The reference angle of the reference center point in the second coordinate system is determined based on the first distance offset compensation value of the image sensor profile in the X direction and the second distance offset compensation value of the image sensor profile in the Y direction.

[0148] If the angle difference between the actual angle and the reference angle is less than the preset angle threshold, then the angle offset of the image sensor is deemed acceptable.

[0149] Specifically, the actual angle Angle of the actual center point in the first coordinate system can be determined according to formula (10):

[0150]

[0151] In formula (9), mark_center_x is the x-coordinate of the midpoint, mark_center_y is the y-coordinate of the midpoint, sensor_center_x is the x-coordinate of the actual center point of the image sensor contour, sensor_center_y is the y-coordinate of the actual center point of the image sensor contour, and π is 3.1415926.

[0152] The reference angle of the reference center point in the second coordinate system is determined according to formula (11):

[0153]

[0154] Where Offset_X is the first distance offset compensation value of the image sensor contour in the X direction, and Offset_Y is the second distance offset compensation value of the image sensor contour in the Y direction.

[0155] Obtain the absolute value of the angle difference between the actual angle and the reference angle. If the absolute value of the angle difference is less than a preset angle threshold, the angle offset of the image sensor is deemed acceptable. The preset angle threshold can be obtained from the reference data.

[0156] If both the angular offset and positional offset of the image sensor are within acceptable limits, then the image sensor position is determined to be acceptable. If either the angular offset or the positional offset is found to be unacceptable, then the image sensor position is determined to be unacceptable.

[0157] This embodiment determines the target marker points in the image to be tested and the actual center point of the image sensor outline in the image to be tested. It then performs automatic detection based on the positional offset between the target marker points, the actual center point, and the image sensor. Compared with manual measurement, this method can improve detection efficiency and reduce detection errors caused by manual operation, thereby improving detection accuracy.

[0158] Based on the same inventive concept as in the foregoing embodiments, this embodiment also provides a device for detecting the testing environment of a camera module, such as... Figure 4 As shown, the device includes:

[0159] The acquisition unit 41 is used to acquire the image to be tested; the image to be tested is an image captured by the bonded image sensor.

[0160] The determining unit 42 is used to determine the target marker points in the image to be tested and the actual center point of the image sensor contour based on the reference data of the image sensor;

[0161] The detection unit 43 is used to detect the positional offset of the image sensor based on the target marker points in the image to be tested and the actual center point of the image sensor contour.

[0162] Since the apparatus described in the embodiments of the present invention is used for implementing the method of detecting the positional offset of an image sensor according to the embodiments of the present invention, those skilled in the art can understand the specific structure and modifications of the apparatus based on the method described in the embodiments of the present invention, and therefore will not be described in detail here. All apparatuses used in the methods of the embodiments of the present invention fall within the scope of protection of the present invention.

[0163] Based on the same inventive concept, this embodiment provides a computer device 500, such as... Figure 5 As shown, the system includes a memory 510, a processor 520, and a computer program 511 stored in the memory 510 and executable on the processor 520. When the processor 520 executes the computer program 511, it performs the following steps:

[0164] Acquire a test image, which is an image captured by the bonded image sensor;

[0165] Based on the reference data of the image sensor, the target marker points in the image to be tested and the actual center point of the image sensor contour are determined.

[0166] The positional offset of the image sensor is detected based on the target marker points in the image to be tested and the actual center point of the image sensor contour.

[0167] Based on the same inventive concept, this embodiment provides a computer-readable storage medium 600, such as... Figure 6 As shown, a computer program 611 is stored thereon, which, when executed by a processor, performs the following steps:

[0168] Acquire a test image, which is an image captured by the bonded image sensor;

[0169] Based on the reference data of the image sensor, the target marker points in the image to be tested and the actual center point of the image sensor contour are determined.

[0170] The positional offset of the image sensor is detected based on the target marker points in the image to be tested and the actual center point of the image sensor contour.

[0171] Through one or more embodiments of the present invention, the present invention has the following beneficial effects or advantages:

[0172] This invention provides a method, apparatus, medium, and device for detecting the positional offset of an image sensor. The method includes: acquiring a test image; the test image is an image captured of a bonded image sensor; determining target marker points and the actual center point of the image sensor contour in the test image based on reference data of the image sensor; and detecting the positional offset of the image sensor based on the target marker points and the actual center point of the image sensor contour in the test image. Thus, by determining the target marker points and the actual center point of the image sensor contour in the test image, automatic detection can be performed based on the positional offset of the target marker points, the actual center point, and the image sensor. Compared with manual measurement, this improves detection efficiency and reduces detection errors caused by manual operation, thereby improving detection accuracy.

[0173] The algorithms and displays provided herein are not inherently related to any particular computer, virtual system, or other device. Various general-purpose systems can also be used in conjunction with the teachings herein. The required structure for constructing such systems is apparent from the above description. Furthermore, this invention is not directed to any particular programming language. It should be understood that the contents of the invention described herein can be implemented using various programming languages, and the above description of specific languages ​​is for the purpose of disclosing the best mode of implementation of the invention.

[0174] Numerous specific details are set forth in the specification provided herein. However, it will be understood that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures, and techniques have not been shown in detail so as not to obscure the understanding of this specification.

[0175] Similarly, it should be understood that, in order to simplify this disclosure and aid in understanding one or more of the various aspects of the invention, in the above description of exemplary embodiments of the invention, various features of the invention are sometimes grouped together in a single embodiment, figure, or description thereof. However, this method of disclosure should not be construed as reflecting an intention that the claimed invention requires more features than are expressly recited in each claim. Rather, as reflected in the following claims, inventive aspects lie in fewer than all features of a single foregoing disclosed embodiment. Therefore, the claims following the detailed description are hereby expressly incorporated into this detailed description, wherein each claim itself is a separate embodiment of the invention.

[0176] Those skilled in the art will understand that modules in the device of the embodiments can be adaptively changed and placed in one or more devices different from that embodiment. Modules, units, or components in the embodiments can be combined into a single module, unit, or component, and further, they can be divided into multiple sub-modules, sub-units, or sub-components. Except where at least some of such features and / or processes or units are mutually exclusive, any combination can be used to combine all features disclosed in this specification (including the accompanying claims, abstract, and drawings) and all processes or units of any method or device so disclosed. Unless expressly stated otherwise, each feature disclosed in this specification (including the accompanying claims, abstract, and drawings) may be replaced by an alternative feature that serves the same, equivalent, or similar purpose.

[0177] Furthermore, those skilled in the art will understand that although some embodiments herein include certain features included in other embodiments but not others, combinations of features from different embodiments are intended to be within the scope of the invention and form different embodiments. For example, in the following claims, any of the claimed embodiments can be used in any combination.

[0178] The various component embodiments of the present invention can be implemented in hardware, or as software modules running on one or more processors, or a combination thereof. Those skilled in the art will understand that microprocessors or digital signal processors (DSPs) can be used in practice to implement some or all of the functions of some or all of the components of the gateway, proxy server, or system according to embodiments of the present invention. The present invention can also be implemented as a device or apparatus program (e.g., a computer program and computer program product) for performing some or all of the methods described herein. Such programs implementing the present invention can be stored on a computer-readable medium or can be in the form of one or more signals. Such signals can be downloaded from an Internet website, provided on a carrier signal, or provided in any other form.

[0179] It should be noted that the above embodiments are illustrative of the invention and not restrictive, and that those skilled in the art can devise alternative embodiments without departing from the scope of the appended claims. In the claims, any reference signs placed between parentheses should not be construed as limiting the claims. The word "comprising" does not exclude the presence of elements or steps not listed in the claims. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The invention can be implemented by means of hardware comprising several different elements and by means of a suitably programmed computer. In the unit claims enumerating several means, several of these means may be embodied by the same item of hardware. The use of the words first, second, and third, etc., does not indicate any order. These words can be interpreted as names.

[0180] Although preferred embodiments of this application have been described, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments as well as all changes and modifications falling within the scope of this application.

[0181] The above description is merely a preferred embodiment of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.

Claims

1. A method for detecting positional offset of an image sensor, characterized in that, The method includes: Acquire a test image, which is an image captured by the bonded image sensor; Based on the reference data of the image sensor, the target marker points in the image to be tested and the actual center point of the image sensor contour are determined. The positional offset of the image sensor is detected based on the target marker points in the image to be tested and the actual center point of the image sensor contour; wherein... Determining the target marker points in the image under test based on the reference data of the image sensor includes: The target marker diameter, target ratio, and reference distance between target markers are obtained from the reference data; the target ratio is the ratio between the actual size of the image sensor and the number of pixels in the image to be measured. The radius range of the target marker point is determined based on the diameter of the target marker point and the target ratio. The contour of the first marker point is extracted from the image under test using a contour determination function. The first marker point contour is filtered based on the radius range of the target marker point and the first contour aspect ratio threshold to obtain the second marker point contour; The distance range of the target marker points is determined based on the reference distance between the target marker points; The second marker point contour is filtered based on the distance range and the reference center point of the image sensor contour to obtain the third marker point contour; Determine the first distance between any two third marker point contours, obtain the distance difference between the first distance and the reference distance, and determine the two third marker point contours corresponding to the minimum distance difference as the target marker points.

2. The method as described in claim 1, characterized in that, Determining the radius range of the target marker point based on the diameter of the marker point and the target ratio includes: Determine the quotient of the ratio of the diameter of the marker point to the target, and determine half of the quotient as the radius of the target marker point; The radius range is determined based on the radius of the target marker point; the radius range is (0.7...). R 1.2 R ); the R The radius of the target marker point.

3. The method as described in claim 1, characterized in that, The step of filtering the second marker point contour based on the distance range and the reference center point of the image sensor contour to obtain the third marker point contour includes: The range of the center point is determined based on the reference center point of the image sensor contour; For the current second marker point profile, determine the midpoint between the current second marker point profile and the reference second marker point profile; the reference second marker point profile is any second marker point profile other than the current second marker point profile. The current second marker profile that meets the filtering criteria is determined as the third marker profile; the filtering criteria are: the midpoint of the line connecting the current second marker profile and the reference second marker profile is within the range of the center point, and the second distance between the current second marker profile and the reference second marker profile is within the distance range.

4. The method as described in claim 1, characterized in that, Determining the actual center point of the image sensor profile based on the reference data of the image sensor includes: The image sensor profile is obtained from the reference data. X The length of the direction and the contour of the image sensor are in Y The length and target ratio in the direction; the target ratio is the ratio between the actual size of the image sensor and the number of pixels in the image to be measured; Based on the image sensor profile X The reference width of the image sensor profile is determined by the length of the direction and the target ratio; based on the image sensor profile in... Y The length of the direction and the target ratio determine the reference height of the image sensor profile; The area range of the image sensor contour is determined based on the reference width and the reference height; Extract the contours of each rectangle using the contour determination function; The rectangular contour is filtered based on the area range of the image sensor contour, the aspect ratio threshold of the second contour, and the reference center point of the image sensor contour to obtain the reference contour. For any reference contour, obtain the area difference between the area of ​​the reference contour and the reference area of ​​the image sensor contour, and determine the reference contour corresponding to the minimum area difference as the image sensor contour. Obtain the actual center point of the image sensor profile.

5. The method as described in claim 1, characterized in that, The positional offset includes: distance offset and angle offset; the detection of the positional offset of the image sensor based on the target marker points in the image to be tested and the actual center point of the image sensor contour includes: Determine the midpoint between two target marker points, and obtain the x-coordinate and y-coordinate of the midpoint; The image sensor profile is obtained from the reference data. X The first distance offset compensation value in the direction and the image sensor profile are in Y The second distance offset compensation value in the direction; The reference horizontal coordinate of the image sensor is determined based on the midpoint horizontal coordinate and the first distance offset compensation value; the reference vertical coordinate of the image sensor is determined based on the midpoint horizontal coordinate and the second distance offset compensation value. The actual horizontal and vertical coordinates of the image sensor contour are determined based on the actual center point. The horizontal coordinate offset distance is determined based on the reference horizontal coordinate and the actual horizontal coordinate, and the vertical coordinate offset distance is determined based on the reference vertical coordinate and the actual vertical coordinate. If it is determined that the horizontal coordinate offset distance is less than a preset horizontal coordinate offset threshold, and it is determined that the vertical coordinate offset distance is less than a preset vertical coordinate offset threshold, then the distance offset of the image sensor is determined to be qualified.

6. The method as described in claim 1, characterized in that, The positional offset includes: distance offset and angle offset; the detection of the positional offset of the image sensor based on the target marker points in the image to be tested and the actual center point of the image sensor contour includes: Determine the midpoint between two target marker points, and establish a first coordinate system with the midpoint as the origin; Determine the actual angle of the actual center point in the first coordinate system; the actual angle is the angle between the line connecting the actual center point and the origin of the first coordinate system and the first coordinate system. X The included angle of the axis; A second coordinate system is established with the reference center point of the image to be tested as the origin; Based on the image sensor profile X The first distance offset compensation value in the direction and the image sensor profile are in Y The second distance offset compensation value in the direction determines the reference angle of the reference center point in the second coordinate system; If the angle difference between the actual angle and the reference angle is determined to be less than a preset angle threshold, then the angle offset of the image sensor is determined to be qualified.

7. A device for detecting positional offset of an image sensor, characterized in that, The device includes: An acquisition unit is used to acquire an image to be tested; the image to be tested is an image captured by the bonded image sensor. The determining unit is used to determine the target marker points in the image to be tested and the actual center point of the image sensor contour based on the reference data of the image sensor; The detection unit is used to detect the positional offset of the image sensor based on the target marker points in the image to be tested and the actual center point of the image sensor contour; wherein, Determining the target marker points in the image under test based on the reference data of the image sensor includes: The target marker diameter, target ratio, and reference distance between target markers are obtained from the reference data; the target ratio is the ratio between the actual size of the image sensor and the number of pixels in the image to be measured. The radius range of the target marker point is determined based on the diameter of the target marker point and the target ratio. The contour of the first marker point is extracted from the image under test using a contour determination function. The first marker point contour is filtered based on the radius range of the target marker point and the first contour aspect ratio threshold to obtain the second marker point contour; The distance range of the target marker points is determined based on the reference distance between the target marker points; The second marker point contour is filtered based on the distance range and the reference center point of the image sensor contour to obtain the third marker point contour; Determine the first distance between any two third marker point contours, obtain the distance difference between the first distance and the reference distance, and determine the two third marker point contours corresponding to the minimum distance difference as the target marker points.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the program implements the steps of the method according to any one of claims 1-6.

9. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps of the method according to any one of claims 1-6.

Citation Information

Patent Citations

  • Image detection method and device

    CN111161208A