A plate size measurement method and device, electronic equipment and readable storage medium

By dividing the support surface model and the depth range twice, the problem of low measurement accuracy caused by camera imaging resolution and angle limitations in plate size measurement is solved, and high-precision plate size measurement is achieved.

CN122115539APending Publication Date: 2026-05-29CHINA IND INTERNET RES INST
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHINA IND INTERNET RES INST
Filing Date
2026-03-19
Publication Date
2026-05-29

AI Technical Summary

Technical Problem

Existing methods for measuring sheet metal dimensions suffer from low accuracy due to limitations in camera imaging resolution and shooting angle. In particular, motion blur is easily generated during image acquisition when the conveyor belt is moving at high speed, which reduces the accuracy of the measurement.

Method used

By segmenting the material twice based on the support surface model and the depth range, the point cloud of the material under test is accurately separated, eliminating interference from the support surface and holes, thus improving measurement accuracy.

Benefits of technology

It achieves high-precision measurement of plate dimensions, eliminates interference from support surfaces and slots, and improves the accuracy of measurement results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122115539A_ABST
    Figure CN122115539A_ABST
Patent Text Reader

Abstract

The application provides a plate size measurement method and device, electronic equipment and readable storage medium, wherein the plate size measurement method comprises: obtaining original point cloud data; the original point cloud data comprises point cloud of a to-be-measured plate and point cloud of a plate support surface bearing the to-be-measured plate; based on a constructed plate support surface model, the original point cloud data is segmented to obtain first point cloud data; based on the first point cloud data and a preset depth interval, the first point cloud data is segmented to obtain second point cloud data; based on the second point cloud data and the plate support surface model, the size of the to-be-measured plate is determined. In this way, through twice segmentation based on the support surface model and the depth interval, the point cloud of the to-be-measured plate is accurately separated, the interference of the support surface and holes and grooves is excluded, and the accuracy of plate size measurement is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of industrial measurement technology, and in particular to a method, apparatus, electronic device, and readable storage medium for measuring the dimensions of sheet metal. Background Technology

[0002] During the sheet metal production process, the cut sheets need to be dimensionally measured to verify whether they meet the specifications. Currently, some production lines use a non-contact measurement method based on two-dimensional images, which uses an industrial camera to acquire images of the sheet metal and calculates the sheet metal dimensions based on image processing technology.

[0003] However, due to limitations in camera imaging resolution and perspective distortion caused by the shooting angle, measurement methods based on two-dimensional images struggle to guarantee accuracy. Furthermore, when the conveyor belt moves at high speed, image acquisition is prone to motion blur, further reducing measurement accuracy. Therefore, existing methods for measuring sheet metal dimensions have relatively low accuracy. Summary of the Invention

[0004] In view of this, embodiments of this application provide at least one method, apparatus, electronic device, and readable storage medium for measuring the size of a plate. By performing two segments based on a support surface model and a depth range, the point cloud of the plate to be measured is accurately separated, eliminating interference from the support surface and holes, thereby improving the accuracy of plate size measurement.

[0005] This application mainly includes the following aspects: In a first aspect, embodiments of this application provide a method for measuring the dimensions of a sheet metal, the method comprising: Acquire raw point cloud data; the raw point cloud data includes the point cloud of the material to be tested and the point cloud of the support surface of the material to be tested. Based on the constructed plate support surface model, the original point cloud data is segmented to obtain the first point cloud data; Based on the first point cloud data and the preset depth range, the first point cloud data is segmented to obtain the second point cloud data; Based on the second point cloud data and the plate support surface model, the dimensions of the plate to be tested are determined.

[0006] Secondly, embodiments of this application also provide a sheet metal size measuring device, the sheet metal size measuring device comprising: The data acquisition module is used to acquire raw point cloud data; the raw point cloud data includes the point cloud of the board to be tested and the point cloud of the board support surface that supports the board to be tested. The first segmentation module is used to segment the original point cloud data based on the constructed plate support surface model to obtain the first point cloud data; The second segmentation module is used to segment the first point cloud data based on the first point cloud data and a preset depth range to obtain the second point cloud data. The size determination module is used to determine the size of the plate to be tested based on the second point cloud data and the plate support surface model.

[0007] Thirdly, embodiments of this application also provide an electronic device, including: a processor, a memory, and a bus. The memory stores machine-readable instructions executable by the processor. When the electronic device is running, the processor communicates with the memory through the bus, and the machine-readable instructions are executed by the processor to perform the steps of the plate size measurement method as described above.

[0008] Fourthly, embodiments of this application also provide a computer-readable storage medium storing a computer program, which, when executed by a processor, performs the steps of the plate size measurement method as described above.

[0009] This application provides a method, apparatus, electronic device, and readable storage medium for measuring the dimensions of sheet metal. The method includes: acquiring raw point cloud data; the raw point cloud data includes the point cloud of the sheet metal to be measured and the point cloud of the support surface supporting the sheet metal; segmenting the raw point cloud data based on a constructed support surface model to obtain first point cloud data; segmenting the first point cloud data based on the first point cloud data and a preset depth range to obtain second point cloud data; and determining the dimensions of the sheet metal to be measured based on the second point cloud data and the support surface model. In this way, through two segmentations based on the support surface model and the depth range, the point cloud of the sheet metal to be measured is accurately separated, eliminating interference from the support surface and holes / grooves, thus improving the accuracy of sheet metal dimension measurement.

[0010] To make the above-mentioned objectives, features and advantages of this application more apparent and understandable, preferred embodiments are described below in detail with reference to the accompanying drawings. Attached Figure Description

[0011] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0012] Figure 1 A flowchart of a plate size measurement method provided in an embodiment of this application is shown; Figure 2One of the schematic diagrams showing the installation location of the linear laser scanner in an embodiment of this application is illustrated; Figure 3 A schematic diagram of the original point cloud data in an embodiment of this application is shown; Figure 4 A second schematic diagram of the installation location of the linear laser scanner in an embodiment of this application is shown; Figure 5 This illustration shows a schematic diagram of the first point cloud data in an embodiment of this application; Figure 6 A schematic diagram of the second point cloud data in an embodiment of this application is shown; Figure 7 A schematic diagram of the hole and slot point cloud data in an embodiment of this application is shown; Figure 8 This illustration shows one of the functional block diagrams of a sheet metal size measuring device provided in an embodiment of this application; Figure 9 This is a second functional block diagram of a sheet metal size measuring device provided in an embodiment of this application; Figure 10 A schematic diagram of the structure of an electronic device provided in an embodiment of this application is shown. Detailed Implementation

[0013] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. The components of the embodiments of this application described and shown in the accompanying drawings can generally be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of this application provided in the accompanying drawings is not intended to limit the scope of the claimed application, but merely represents selected embodiments of this application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.

[0014] To facilitate understanding of this application, the technical solutions provided in this application will be described in detail below with reference to specific embodiments.

[0015] Please see Figure 1 , Figure 1 This is a flowchart illustrating a method for measuring the dimensions of a sheet metal as provided in an embodiment of this application. Figure 1 As shown in the embodiments of this application, the method for measuring the dimensions of sheet metal includes the following steps: S101, acquire raw point cloud data; the raw point cloud data includes the point cloud of the board to be tested and the point cloud of the board support surface supporting the board to be tested.

[0016] Here, when measuring the dimensions of the material to be measured, it is first necessary to obtain the spatial three-dimensional information of the material and its underlying supporting structure, which serves as the basis for all subsequent calculations. The original point cloud data is a collection of a large number of points with three-dimensional coordinates, where each point represents the spatial location of a sampling point on the object's surface.

[0017] In this embodiment, a linear laser scanner can be used to scan the moving test plate. Please refer to [link / reference]. Figure 2 , Figure 2 This is a schematic diagram showing the installation location of the linear laser scanner in an embodiment of this application. Figure 2 As shown, a linear laser scanner is positioned above the sheet metal production line. When the conveyor belt carries the sheet metal through the scanner's field of view, the scanner is triggered and performs a line-by-line scan, simultaneously acquiring 3D point cloud data of the sheet metal and the surface of the conveyor belt below it. The acquired raw point cloud data includes point clouds from both the upper surface of the sheet metal and the surface of the conveyor belt that supports the sheet metal. For example, please refer to... Figure 3 , Figure 3 This is a schematic diagram of the original point cloud data in an embodiment of this application. Figure 3 As shown, when a rectangular plate passes through the scanning area with a conveyor belt, the points with smaller depth values ​​at the top of the original point cloud data belong to the plate body, while the points with larger depth values ​​at the bottom belong to the conveyor belt support surface.

[0018] S102, based on the constructed plate support surface model, the original point cloud data is segmented to obtain the first point cloud data.

[0019] Here, the original point cloud data contains point clouds of both the material to be measured and its supporting surface. If dimensional calculations are performed directly based on this mixed data, the point cloud of the supporting surface will interfere with the measurement results. Therefore, it is necessary to remove the point cloud of the supporting surface from the original point cloud data and retain only the point cloud belonging to the material itself.

[0020] In this embodiment, a pre-constructed model of the board support surface describes the geometric position of the board support surface in three-dimensional space. Based on this model, points belonging to the support surface can be identified from the original point cloud data, and these points can be removed, leaving the remaining point cloud as the first point cloud data. For example, if the board support surface model is a plane equation, the distance from each point in the original point cloud data to the plane can be calculated. Points with a distance less than a certain threshold are identified as points on the support surface and removed, leaving the remaining points as the point cloud of the board to be tested. This point cloud may also include the holes and grooves on the board.

[0021] S103, based on the first point cloud data and the preset depth range, the first point cloud data is segmented to obtain the second point cloud data.

[0022] Here, although the first point cloud data has already eliminated interference from the support surface, it may still contain point clouds of the holes and grooves on the board being tested. The point clouds of the holes and grooves differ in depth from the point clouds of the board's main surface. If used directly for dimensional calculations, the measurement results will not accurately reflect the dimensions of the board itself. Therefore, it is necessary to further remove the point clouds of the holes and grooves.

[0023] In this embodiment, a depth range is defined based on the first point cloud data, corresponding to the depth range of the surface of the material to be tested. Points in the first point cloud data whose depth values ​​fall within this range are retained, while points whose depth values ​​fall outside this range (i.e., the point cloud of the hole / groove portion) are discarded to obtain the second point cloud data. The second point cloud data only contains the point cloud of the surface of the material to be tested, excluding interference from the support surface and the hole / groove. For example, if the depth values ​​of the material to be tested are concentrated around a certain value, a depth range of 3 mm above and below this value can be defined, and all points in the first point cloud data whose depth values ​​fall within this range are retained as the second point cloud data.

[0024] S104, Based on the second point cloud data and the plate support surface model, determine the size of the plate to be tested.

[0025] Here, after obtaining a clean point cloud of the material to be tested, various dimensions of the material to be tested, including length, width and thickness, can be calculated based on the point cloud data.

[0026] In this embodiment, based on the second point cloud data, the length and width of the material to be measured can be determined using graphical methods. For example, edge detection is performed on the second point cloud data to find the edge contour of the material to be measured, thereby determining its maximum bounding rectangle. The length and width of the material are then obtained based on the dimensions of this rectangle. Simultaneously, based on the second point cloud data and a pre-constructed material support surface model, the thickness of the material to be measured can be determined. For example, a planar model of the upper surface of the material to be measured is fitted based on the second point cloud data. Combined with the material support surface model, the vertical distance between the two planes is calculated, which is the thickness of the material to be measured. For example, for a rectangular material, its length, width, and thickness can be calculated using the above method, completing the dimensional measurement.

[0027] Further, the plate support surface model is constructed according to the following steps: Step a1: Obtain the point cloud data of the pre-scanned support surface of the plate.

[0028] Here, the board support surface model is used to identify and remove point clouds belonging to the board support surface from the original point cloud data in subsequent steps. In order to establish an accurate support surface model, it is necessary to scan the unloaded board support surface in advance to obtain clean support surface point cloud data when there is no board to be tested.

[0029] In this embodiment, before measuring the material to be tested, a linear laser scanner is first activated to scan the unloaded conveyor belt (i.e., the support surface of the material) to acquire three-dimensional point cloud data of the conveyor belt surface. During scanning, the conveyor belt runs at normal production speed, and the scanner continuously acquires point cloud data covering the entire width and a certain length of the conveyor belt. This data only contains the point cloud of the support surface itself, without any interference from the material.

[0030] Step a2: The point cloud data of the plate support surface is fitted using the least squares method to obtain the plane equation of the plate support surface model.

[0031] Please see here. Figure 4 , Figure 4 This is a second schematic diagram showing the installation location of the linear laser scanner in an embodiment of this application. For example... Figure 4 As shown, since the support surface (such as a conveyor belt) may have a certain tilt during actual installation and is not absolutely horizontal, a plane equation is needed to describe its position and orientation in three-dimensional space. By fitting the obtained support surface point cloud data using the least squares method, an optimal plane equation can be obtained, which can accurately represent the geometric position of the support surface.

[0032] In this embodiment, the support surface point cloud data obtained in step a1 is used as input, and the least squares method is employed for plane fitting. The goal of the least squares method is to find a plane equation. This minimizes the sum of the squares of the distances from all point cloud data points to the plane. The plane parameters are obtained by solving a system of linear equations. This is the model of the plate support surface. This model will be used in subsequent steps to identify and remove point clouds belonging to the support surface by calculating the distance from each point in the original point cloud data to this plane and comparing it with the depth range.

[0033] Further, the step of segmenting the first point cloud data based on the first point cloud data and a preset depth range to obtain second point cloud data includes: Step b1: Select a first target point from the first point cloud data and obtain the depth value of the first target point; the first target point is any point in the central target area of ​​the first point cloud data.

[0034] Please see here. Figure 5 , Figure 5 This is a schematic diagram of the first point cloud data in an embodiment of this application. For example... Figure 5As shown, the first point cloud data obtained after the first segmentation includes point clouds from both the surface of the material under test and the point clouds from the holes and grooves on the material. To remove the point clouds from the holes and grooves, a reference value needs to be determined that represents the depth of the material's surface. Since the surface of the material is a continuous plane in space, the depth value of its central region can well represent the depth level of the entire material surface.

[0035] In this embodiment, within the area of ​​the test material corresponding to the first point cloud data, the central target area of ​​the material is identified. This area roughly corresponds to the vicinity of the geometric center of the material. A point is randomly selected within this central target area as the first target point, and the depth value (i.e., the Z-axis coordinate) of this point is obtained. Since the surface of the material is usually relatively flat in the central area, the depth value of this point can approximately represent the depth of the surface of the material itself. For example, for a rectangular material, the distribution range of its first point cloud data in the X and Y directions can be calculated, and a point near the midpoint of the X and Y directions can be taken as the first target point.

[0036] Step b2: Using the depth value of the first target point as the numerical center and the preset depth as the error range, the depth interval is set.

[0037] Here, the surface of the board body is not absolutely flat and may have slight undulations or measurement noise. Therefore, a fixed depth value cannot be used to represent the entire board surface. Instead, a depth range needs to be set, and points within this range are considered to belong to the board body.

[0038] In this embodiment, a continuous depth interval is formed by offsetting the depth value of the first target point upwards and downwards by a preset error range. This error range can be set according to the material of the board, its surface flatness, and the accuracy requirements of the measurement system. For example, for boards with high surface flatness, a smaller error range, such as ±3 mm, can be set; for boards with some surface undulations, a slightly larger error range can be set. The set depth interval serves as the basis for determining whether the point cloud belongs to the board body.

[0039] Step b3: Delete all points in the first point cloud data whose depth values ​​are not within the depth range, and determine the remaining points as the second point cloud data.

[0040] Here, with the depth range defined, the first point cloud data can be filtered to retain points that match the depth characteristics of the board body and remove those that do not.

[0041] In this embodiment, each point in the first point cloud data is traversed to obtain the depth value (Z-axis coordinate) of each point. The depth value of each point is compared with the depth range set in step b2: if the depth value of the point is within the depth range, the point is retained; if the depth value of the point is outside the depth range, the point is deleted. After processing all points, the retained points are the second point cloud data. Since the point cloud depth values ​​of the slots are significantly different from the depth values ​​of the board surface (usually the depth values ​​of the slots are greater, i.e., farther from the scanner), these points are determined to be outside the depth range and are deleted. Therefore, the second point cloud data only contains the point cloud of the board surface to be tested and no longer contains the point cloud of the slots.

[0042] Further, determining the dimensions of the plate to be tested based on the second point cloud data and the plate support surface model includes: Step c1: Perform edge detection on the second point cloud data to determine the maximum bounding rectangle of the material to be tested, and determine the length and width of the material to be tested based on the corner coordinates of the maximum bounding rectangle.

[0043] Please see here. Figure 6 , Figure 6 This is a schematic diagram of the second point cloud data in an embodiment of this application. For example... Figure 6 As shown, the second point cloud data only contains the point cloud of the surface of the material being tested, excluding interference from the support surface and slots. Based on this pure point cloud data, the outline of the material can be identified using graphics methods, and then the dimensions of the material in the horizontal direction, namely its length and width, can be calculated. Since the Euclidean distance between points in the point cloud data is the actual distance between corresponding points in the real world, the dimensions calculated based on the point cloud coordinates are the true physical dimensions of the material.

[0044] In this embodiment, edge detection processing is performed on the second point cloud data to identify the edge contour of the board to be tested on the horizontal plane. Edge detection can be achieved by analyzing the distribution density changes or depth abrupt changes of the point cloud on the plane to find the set of points constituting the boundary of the board. Based on the detected edge contour, the smallest bounding rectangle that can contain the entire board is determined, and the four sides of this rectangle correspond to the actual length and width directions of the board, respectively. The point cloud coordinates of the four corner points of this largest bounding rectangle are obtained, and the length and width of the board to be tested can be determined based on the spatial distance between two adjacent corner points.

[0045] Step c2: Based on the second point cloud data fitting, obtain the plate planar model of the plate to be tested, and determine the thickness of the plate to be tested based on the plate planar model and the plate support surface model.

[0046] Here, the thickness of the board refers to the vertical distance between the upper surface of the board and the supporting surface below. To accurately calculate the thickness, the position of the upper surface of the board in space and the position of the supporting surface are needed. The second point cloud data provides coordinate information for a large number of points on the upper surface of the board. A plane can be fitted based on these points to represent the spatial position of the upper surface of the board. Combined with a pre-built model of the board's supporting surface, the vertical distance between the two planes can be calculated, which is the thickness of the board.

[0047] In this embodiment, the second point cloud data is used as input, and the least squares method is used for plane fitting to obtain the plane model of the material to be tested. The model describes the geometric position of the upper surface of the board in three-dimensional space using planar equations. Then, combined with a pre-constructed board support surface model, the vertical distance between the two planes is calculated. Specifically, a reference point can be selected on the upper surface of the board, and the corresponding depth values ​​are calculated in both planar models based on the planar coordinates of that point. The absolute value of the difference between the two depth values ​​is the thickness of the board to be measured. Since the upper surface of the board is approximately planar, this calculation result is the actual thickness of the board.

[0048] Further, determining the length and width of the material to be measured based on the corner coordinates of the largest bounding rectangle includes: Step d1: Obtain the point cloud coordinates of the four corner points of the maximum bounding rectangle.

[0049] Here, the maximum bounding rectangle of the material to be tested has been determined in step c1. This rectangle represents the minimum bounding boundary of the material on the horizontal plane. To calculate the actual length and width of the material, the precise positions of the four corner points of the rectangle in three-dimensional space are needed.

[0050] In this embodiment, the point cloud coordinates corresponding to the four corner points are extracted from the maximum bounding rectangle determined in step c1. These four corner points are located at the four actual corners of the board, and each corner point corresponds to a point with three-dimensional coordinates. For example, for a rectangular board, the four corner points of its maximum bounding rectangle correspond to the upper left, upper right, lower left, and lower right corners of the board, respectively. Obtaining the point cloud coordinates of each corner point yields the X, Y, and Z values ​​of that point in the scanner coordinate system. Since the Euclidean distance between points in the point cloud data is the actual distance between corresponding points in the real world, the distance calculated based on these corner coordinates is the actual size of the board.

[0051] Step d2: Calculate the Euclidean distance between two adjacent corner points, and use the two calculated distance values ​​as the length and width of the material to be tested, respectively.

[0052] Here, the length and width of the board material correspond to the lengths of the two adjacent sides of the largest bounding rectangle, respectively. These two dimensions can be directly obtained by calculating the Euclidean distance between adjacent corner points.

[0053] In this embodiment, for the obtained coordinates of the four corner points, the Euclidean distance between adjacent corner points is calculated. Adjacent corner points refer to two corner points that share the same rectangular side. For example, the distance between the top left and top right corners corresponds to one side of the board (e.g., width), and the distance between the top left and bottom left corners corresponds to another side of the board (e.g., length). Since the surface of the board is approximately planar, and the corner points are located on the same plane, the difference in Z-coordinates is small, but the calculation formula still includes the Z-coordinate to ensure the accuracy of the distance calculation. Of the two calculated distance values, the larger one can be used as the length of the board, and the smaller one can be used as the width of the board, or they can be distinguished according to the actual definition. For example, if the distance between the top left and top right corners is calculated to be 1200 mm, and the distance between the top left and bottom left corners is 600 mm, then the length of the board is determined to be 1200 mm, and the width is 600 mm.

[0054] Further, determining the thickness of the plate to be measured based on the plate planar model and the plate support surface model includes: Step e1: Select a second target point from the second point cloud data and obtain the planar coordinates of the second target point; the second target point is any point in the central target area of ​​the second point cloud data.

[0055] Here, the sheet thickness refers to the vertical distance between the top surface of the sheet and the supporting surface below. To calculate this distance, a representative point needs to be selected. The planar coordinates (X and Y) of this point will be used to calculate the corresponding depth value in two planar models. Since the top surface of the sheet is approximately a plane, selecting a point in the central region avoids the influence of potential warping at the edges or measurement noise, making the calculation results more representative.

[0056] In this embodiment, within the area of ​​the board material to be tested corresponding to the second point cloud data, the central target area of ​​the board material is identified. This area roughly corresponds to the vicinity of the geometric center of the board material. A point is randomly selected within this central target area as the second target point, and the planar coordinates of this point are obtained, namely, the X-axis coordinate value and Y-axis coordinate value of this point. Since subsequent calculations only need to use the X and Y coordinates of this point, it is not necessary to obtain its Z coordinate. For example, for the board material planar model obtained by fitting in step c2, a certain center point involved in the calculation during fitting can be selected, or a point located near the center of the board material can be selected from the first point cloud data.

[0057] Step e2: Substitute the planar coordinates of the second target point into the plate plane model and the plate support surface model respectively to calculate the first depth value of the second target point on the plate plane and the second depth value on the plate support surface.

[0058] Here, both the planar model of the board and the supporting surface model of the board are planar equations, in the form of: Given the planar coordinates of the second target point. The Z-value of the point on the plane can be obtained by substituting it into the plane equation, which is the depth value of the point projected perpendicularly onto the plane. In this way, the corresponding depths of the same plane coordinate position on the upper surface of the plate and the supporting surface can be calculated respectively.

[0059] In this embodiment, the X and Y coordinates of the second target point are substituted into the plate plane equation obtained by fitting in step c2, and the equation is solved to obtain the Z value, which is denoted as the first depth value. Specifically, it is expressed as: This value represents the depth of the upper surface of the board in the scanner coordinate system at the X and Y positions where the second target point is located. Simultaneously, substituting the same X and Y coordinates into the equation of the board support surface plane obtained in step a2, the Z value is obtained and recorded as the second depth value. Specifically, it is expressed as: This value represents the depth of the support surface (conveyor belt surface) in the scanner coordinate system at the same X and Y positions. Since both the plate plane and the support surface are spatial planes, for any given X and Y coordinates, both equations can uniquely solve for a Z value.

[0060] Step e3: Calculate the absolute value of the difference between the first depth value and the second depth value, and determine the absolute value as the thickness of the plate to be tested.

[0061] Here, the thickness of the board is defined as the vertical distance from the upper surface of the board to the supporting surface. Since both the board plane and the supporting surface are planes, and the planar coordinates of the second target point are the same, the vertical distance between the two planes at that point is the vertical distance between the two planes. The difference between the first depth value and the second depth value reflects the height difference between the upper surface of the board and the supporting surface; the absolute value of this difference is the thickness of the board.

[0062] In this embodiment, the first depth value and the second depth value calculated in step e2 are subtracted, and the absolute value is taken. The result is the thickness of the material to be measured. The calculation formula is: Since the board is located above the supporting surface, the first depth value (depth of the board's upper surface) is usually less than the second depth value (depth of the supporting surface), so the difference is a positive number. This thickness value is the actual physical thickness of the board, in millimeters. For example, if the calculated first depth value is 150 mm and the second depth value is 155 mm, then the board thickness is 5 mm.

[0063] Furthermore, the first point cloud data also includes the point cloud of holes and grooves on the test plate; the method further includes: Step f1: Compare the first point cloud data with the second point cloud data, and extract the points that do not appear in the second point cloud data from the first point cloud data as the hole and groove point cloud data of the test plate.

[0064] Here, the second point cloud data obtained after the second segmentation only contains the point cloud of the surface of the material to be tested, while the first point cloud data obtained after the first segmentation contains the point clouds of both the material body and the holes / grooves. By comparing these two sets of data, the point cloud of the holes / grooves can be separated, so that the holes / grooves can be measured separately in subsequent steps.

[0065] In this embodiment, the first point cloud data and the second point cloud data are compared point by point. Since the second point cloud data is obtained by removing the hole and slot point cloud from the first point cloud data, all points belonging to the board body in the first point cloud data should also exist in the second point cloud data, while points belonging to the hole and slot only exist in the first point cloud data. By comparing the spatial coordinates of each point, those points that only appear in the first point cloud data but not in the second point cloud data are identified. These points are extracted and combined into a new point cloud set, which is the hole and slot point cloud data. For example, for a circular hole on the board, the point cloud depth values ​​of the hole wall and bottom are significantly greater than the surface of the board body. These points are removed during the second segmentation, so they can be extracted by comparison.

[0066] Step f2: Perform edge detection on the hole and slot point cloud data, determine the maximum bounding rectangle of each hole and slot, and determine the length and width of the corresponding hole and slot based on the corner coordinates of each maximum bounding rectangle.

[0067] Please see here. Figure 7 , Figure 7 This is a schematic diagram of the point cloud data for the slots and holes in an embodiment of this application. For example... Figure 7 As shown, the hole and slot point cloud data may contain multiple independent holes and slots, each corresponding to a point cloud region. For each hole and slot, its length and width need to be measured separately, i.e., the opening size of the hole and slot in the horizontal direction.

[0068] In this embodiment, the point cloud data of the slots is first clustered to separate the point clouds belonging to different slots, resulting in an independent point cloud set for each slot. Then, edge detection is performed on the point cloud data of each slot to identify its edge contour on the horizontal plane. Based on the detected edge contour, the smallest bounding rectangle that can contain the slot is determined, with the length and width of this rectangle corresponding to the two main dimensions of the slot in the horizontal direction. The point cloud coordinates of the four corner points of each largest bounding rectangle are obtained, and the Euclidean distance between two adjacent corner points is calculated, yielding two distance values, which are used as the length and width of the slot, respectively. For example, for a rectangular slot, its largest bounding rectangle basically coincides with the actual contour of the slot, and the two calculated distance values ​​are the actual length and width of the slot; for a circular slot, its largest bounding rectangle is a square, and the two calculated distance values ​​are equal, representing the diameter of the circular hole.

[0069] Step f3: Locate the third target point in the point cloud data corresponding to each hole and groove, calculate the vertical distance from the third target point to the board plane model of the board to be tested, and use the calculated distance value as the depth of the hole and groove; the third target point is the point with the largest depth value in the point cloud data corresponding to the hole and groove.

[0070] Here, the depth of the slot refers to the vertical distance between the bottom of the slot and the top surface of the board. Since the bottom of the slot is usually the point farthest from the scanner in the entire slot area (i.e., the point with the largest depth value), the deepest point of the slot can be located by finding the point with the largest depth value, and the distance from that point to the top surface of the board is the slot depth.

[0071] In this embodiment, for each independent point cloud set segmented in step f2, all points in the set are traversed, and the depth value (Z-axis coordinate) of each point is compared. The point with the largest depth value is selected as the third target point. This point corresponds to the lowest point at the bottom of the slot (the position farthest from the scanner). The spatial coordinates of this point are then obtained. Then, based on the plate plane model obtained by fitting in step c2, the vertical distance from the point to the plate plane is calculated, which is the depth of the hole / groove. Specifically, it can be calculated using the formula shown below: For example, for a hole with a depth of 10 mm, the distance value obtained after substituting the coordinates of its deepest point into the formula should be 10 mm.

[0072] This application provides a method for measuring the dimensions of a sheet material, comprising: acquiring raw point cloud data; the raw point cloud data including the point cloud of the sheet material to be measured and the point cloud of the support surface supporting the sheet material; segmenting the raw point cloud data based on a constructed support surface model to obtain first point cloud data; segmenting the first point cloud data based on the first point cloud data and a preset depth range to obtain second point cloud data; and determining the dimensions of the sheet material to be measured based on the second point cloud data and the support surface model. In this way, through two segmentations based on the support surface model and the depth range, the point cloud of the sheet material to be measured is accurately separated, eliminating interference from the support surface and holes / grooves, thus improving the accuracy of sheet material dimension measurement.

[0073] Based on the same application concept, this application also provides a plate size measuring device corresponding to the plate size measuring method provided in the above embodiments. Since the principle of the device in this application is similar to the plate size measuring method in the above embodiments of this application, the implementation of the device can refer to the implementation of the method, and the repeated parts will not be described again.

[0074] Please see Figure 8 , Figure 8 This is one of the functional block diagrams of a sheet metal dimension measuring device provided in an embodiment of this application. As shown in the figure, the sheet metal dimension measuring device 800 provided in this embodiment includes: The data acquisition module 810 is used to acquire raw point cloud data; the raw point cloud data includes the point cloud of the test plate and the point cloud of the plate support surface supporting the test plate.

[0075] The first segmentation module 820 is used to segment the original point cloud data based on the constructed plate support surface model to obtain the first point cloud data.

[0076] The second segmentation module 830 is used to segment the first point cloud data based on the first point cloud data and a preset depth range to obtain the second point cloud data.

[0077] The size determination module 840 is used to determine the size of the plate to be tested based on the second point cloud data and the plate support surface model.

[0078] Furthermore, the first segmentation module 820 is also used to construct the plate support surface model according to the following steps: Obtain the point cloud data of the pre-scanned plate support surface; The least squares method is used to fit the point cloud data of the plate support surface to obtain the plane equation of the plate support surface model.

[0079] Furthermore, when the second segmentation module 830 segments the first point cloud data based on the first point cloud data and a preset depth range to obtain the second point cloud data, the second segmentation module 830 is specifically used for: Select a first target point from the first point cloud data and obtain the depth value of the first target point; the first target point is any point in the central target area of ​​the first point cloud data; The depth interval is defined with the depth value of the first target point as the numerical center and the preset depth as the error range. Delete all points in the first point cloud data whose depth values ​​are not within the depth range, and determine the remaining points as the second point cloud data.

[0080] Furthermore, when determining the dimensions of the plate to be measured based on the second point cloud data and the plate support surface model, the dimension determination module 840 is specifically used for: Edge detection is performed on the second point cloud data to determine the maximum bounding rectangle of the material to be tested, and the length and width of the material to be tested are determined based on the corner coordinates of the maximum bounding rectangle. The plate planar model of the plate to be tested is obtained by fitting the second point cloud data, and the thickness of the plate to be tested is determined based on the plate planar model and the plate support surface model.

[0081] Furthermore, when determining the length and width of the material to be measured based on the corner coordinates of the largest bounding rectangle, the size determination module 840 is specifically used for: Obtain the point cloud coordinates of the four corner points of the maximum bounding rectangle; Calculate the Euclidean distance between two adjacent corner points, and use the two calculated distance values ​​as the length and width of the material to be tested, respectively.

[0082] Furthermore, when determining the thickness of the plate to be measured based on the plate planar model and the plate support surface model, the dimension determination module 840 is specifically used for: Select a second target point from the second point cloud data and obtain the planar coordinates of the second target point; the second target point is any point in the central target region of the second point cloud data. Substitute the planar coordinates of the second target point into the plate plane model and the plate support surface model respectively to calculate the first depth value of the second target point on the plate plane and the second depth value on the plate support surface. Calculate the absolute value of the difference between the first depth value and the second depth value, and determine the absolute value as the thickness of the material to be tested.

[0083] Further, please refer to Figure 9 , Figure 9 This is a second functional block diagram of a sheet metal dimension measuring device provided in an embodiment of this application. Figure 9 As shown, the sheet metal size measuring device 800 also includes: The data comparison module 850 is used to compare the first point cloud data with the second point cloud data, and extract the points that do not appear in the second point cloud data from the first point cloud data as the hole and groove point cloud data of the test plate. The first determining module 860 is used to perform edge detection on the hole and slot point cloud data, determine the maximum bounding rectangle of each hole and slot, and determine the length and width of the corresponding hole and slot based on the corner coordinates of each maximum bounding rectangle. The second determining module 870 is used to find a third target point in the hole and slot point cloud data corresponding to each hole and slot, calculate the vertical distance from the third target point to the board plane model of the board to be tested, and use the calculated distance value as the depth of the hole and slot; the third target point is the point with the largest depth value in the hole and slot point cloud data corresponding to the hole and slot.

[0084] This application provides a sheet metal size measurement device, comprising: a data acquisition module for acquiring raw point cloud data; the raw point cloud data includes the point cloud of the sheet metal to be measured and the point cloud of the sheet metal support surface supporting the sheet metal; a first segmentation module for segmenting the raw point cloud data based on a constructed sheet metal support surface model to obtain first point cloud data; a second segmentation module for segmenting the first point cloud data based on the first point cloud data and a preset depth range to obtain second point cloud data; and a size determination module for determining the size of the sheet metal to be measured based on the second point cloud data and the sheet metal support surface model. Thus, through two segmentations based on the support surface model and the depth range, the point cloud of the sheet metal to be measured is accurately separated, eliminating interference from the support surface and holes / grooves, thereby improving the accuracy of sheet metal size measurement.

[0085] Based on the same application concept, please refer to Figure 10 , Figure 10 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Figure 10 As shown, the electronic device 1000 includes: a processor 1010, a memory 1020, and a bus 1030.

[0086] The memory 1020 stores machine-readable instructions executable by the processor 1010. When the electronic device 1000 is running, the processor 1010 and the memory 1020 communicate through the bus 1030. When the machine-readable instructions are executed by the processor 1010, they perform the steps of the plate size measurement method provided in the above embodiment. For specific implementation methods, please refer to the method embodiment, which will not be repeated here.

[0087] Based on the same concept, this application also provides a computer-readable storage medium storing a computer program. When the computer program is run by a processor, it executes the steps of the plate size measurement method provided in the above embodiments. For specific implementation details, please refer to the method embodiments, which will not be repeated here.

[0088] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working process of the above-described apparatus and unit can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.

[0089] In the embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. The apparatus embodiments described above are merely illustrative. For example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. Furthermore, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Additionally, the displayed or discussed mutual couplings, direct couplings, or communication connections may be through some communication interfaces; indirect couplings or communication connections between devices or units may be electrical, mechanical, or other forms.

[0090] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0091] In addition, the functional units in the embodiments provided in this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.

[0092] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0093] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures. In addition, the terms "first", "second", "third", etc. are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.

[0094] Finally, it should be noted that the above-described embodiments are merely specific implementations of this application, used to illustrate the technical solutions of this application, and not to limit them. The protection scope of this application is not limited thereto. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that any person skilled in the art can still modify or easily conceive of changes to the technical solutions described in the foregoing embodiments, or make equivalent substitutions for some of the technical features, within the scope of the technology disclosed in this application; and these modifications, changes, or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application. All should be covered within the protection scope of this application. Therefore, the protection scope of this application should be determined by the protection scope of the claims.

Claims

1. A method for measuring the dimensions of a sheet metal, characterized in that, The method includes: Acquire raw point cloud data; the raw point cloud data includes the point cloud of the material to be tested and the point cloud of the support surface of the material to be tested. Based on the constructed plate support surface model, the original point cloud data is segmented to obtain the first point cloud data; Based on the first point cloud data and the preset depth range, the first point cloud data is segmented to obtain the second point cloud data; Based on the second point cloud data and the plate support surface model, the dimensions of the plate to be tested are determined.

2. The method for measuring the dimensions of sheet metal according to claim 1, characterized in that, Construct the plate support surface model according to the following steps: Obtain the point cloud data of the pre-scanned plate support surface; The least squares method is used to fit the point cloud data of the plate support surface to obtain the plane equation of the plate support surface model.

3. The method for measuring the dimensions of sheet metal according to claim 1, characterized in that, The step of segmenting the first point cloud data based on the first point cloud data and a preset depth range to obtain second point cloud data includes: Select a first target point from the first point cloud data and obtain the depth value of the first target point; the first target point is any point in the central target area of ​​the first point cloud data; The depth interval is defined with the depth value of the first target point as the numerical center and the preset depth as the error range. Delete all points in the first point cloud data whose depth values ​​are not within the depth range, and determine the remaining points as the second point cloud data.

4. The method for measuring the dimensions of sheet metal according to claim 1, characterized in that, The step of determining the dimensions of the plate to be tested based on the second point cloud data and the plate support surface model includes: Edge detection is performed on the second point cloud data to determine the maximum bounding rectangle of the material to be tested, and the length and width of the material to be tested are determined based on the corner coordinates of the maximum bounding rectangle. The plate planar model of the plate to be tested is obtained by fitting the second point cloud data, and the thickness of the plate to be tested is determined based on the plate planar model and the plate support surface model.

5. The method for measuring the dimensions of sheet metal according to claim 4, characterized in that, Determining the length and width of the material to be measured based on the corner coordinates of the largest bounding rectangle includes: Obtain the point cloud coordinates of the four corner points of the maximum bounding rectangle; Calculate the Euclidean distance between two adjacent corner points, and use the two calculated distance values ​​as the length and width of the material to be tested, respectively.

6. The method for measuring the dimensions of sheet metal according to claim 4, characterized in that, Determining the thickness of the plate to be measured based on the plate planar model and the plate support surface model includes: Select a second target point from the second point cloud data and obtain the planar coordinates of the second target point; the second target point is any point in the central target region of the second point cloud data. Substitute the planar coordinates of the second target point into the plate plane model and the plate support surface model respectively to calculate the first depth value of the second target point on the plate plane and the second depth value on the plate support surface. Calculate the absolute value of the difference between the first depth value and the second depth value, and determine the absolute value as the thickness of the material to be tested.

7. The method for measuring the dimensions of sheet metal according to claim 6, characterized in that, The first point cloud data also includes the point cloud of holes and grooves on the test plate; the method further includes: The first point cloud data is compared with the second point cloud data, and the points that do not appear in the second point cloud data are extracted from the first point cloud data as the hole and groove point cloud data of the plate to be tested. Edge detection is performed on the hole and slot point cloud data to determine the maximum bounding rectangle of each hole and slot, and the length and width of the corresponding hole and slot are determined based on the corner coordinates of each maximum bounding rectangle. In the point cloud data of each hole groove, find the third target point, calculate the vertical distance from the third target point to the planar model of the board to be tested, and use the calculated distance value as the depth of the hole groove; the third target point is the point with the largest depth value in the point cloud data of the hole groove.

8. A sheet metal dimension measuring device, characterized in that, The plate size measuring device includes: The data acquisition module is used to acquire raw point cloud data; the raw point cloud data includes the point cloud of the board to be tested and the point cloud of the board support surface that supports the board to be tested. The first segmentation module is used to segment the original point cloud data based on the constructed plate support surface model to obtain the first point cloud data; The second segmentation module is used to segment the first point cloud data based on the first point cloud data and a preset depth range to obtain the second point cloud data. The size determination module is used to determine the size of the plate to be tested based on the second point cloud data and the plate support surface model.

9. An electronic device, characterized in that, include: The device includes a processor, a memory, and a bus. The memory stores machine-readable instructions executable by the processor. When the electronic device is running, the processor communicates with the memory via the bus. The machine-readable instructions are executed by the processor to perform the steps of the sheet metal dimension measurement method as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, performs the steps of the plate size measurement method as described in any one of claims 1 to 7.