Contour extraction and generation method, system and device and electronic equipment
The contour extraction and generation method addresses the inaccuracies in traditional visual positioning by precisely capturing laser target positions and generating adaptive processing trajectories, enhancing accuracy and adaptability in product processing.
Patent Information
- Application Number
- CN202411303862.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-18
- Publication Date
- 2024-12-27
- Estimated Expiration
- 2044-09-18
AI Technical Summary
Traditional visual positioning technology fails to accurately capture the corresponding laser target position on products, preventing the generation of adaptive laser image files and customized processing trajectories, which cannot meet customer requirements.
A method involving contour extraction and generation, including acquiring multiple contour images, fitting reference points, adjusting a standard contour line based on these points, and generating an actual processing contour line, using a system with XYR platforms, top and side shooting modules, and processing modules to ensure precise alignment and adaptation to product shapes and sizes.
Enhances processing accuracy, reduces errors, and adapts to diverse product shapes, improving production efficiency and quality by ensuring each product meets design specifications and customer requirements.
Smart Images

Figure CN119205828A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of visual positioning, and in particular to a contour extraction and generation method, system, device and electronic equipment. Background Art
[0002] Traditional visual positioning technology uses traditional visual means in imaging. The camera cannot accurately capture the corresponding laser target position on the product to be processed, which makes it impossible for the algorithm to fit the grasping benchmark and actively generate an adaptive laser image file for each incoming material. Furthermore, before the laser, the equipment has the disadvantage of being unable to actively generate a separate trajectory for each product, which cannot meet the customer's process requirements. Summary of the invention
[0003] In view of this, the purpose of this application is to overcome the shortcomings of the prior art and to provide a contour extraction generation method, system, device and electronic equipment. Through the method of this application, the corresponding target position to be laser-processed on the product to be processed can be captured, and an adaptive laser image file can be actively generated for each product to be processed, thereby meeting the customer's process requirements.
[0004] This application provides the following technical solutions:
[0005] In a first aspect, an embodiment of the present application provides a contour extraction generation method, the contour extraction generation method comprising:
[0006] Acquire multiple contour images of the area to be processed, a standard contour line of the area to be processed, and reference points on the standard contour line, wherein the reference points include a standard starting endpoint and a standard ending endpoint;
[0007] Acquire multiple contour reference points based on the multiple contour images; wherein the multiple contour reference points are distributed on the actual contour line of the area to be processed; the contour reference points include a starting end contour reference point and an ending end contour reference point;
[0008] Fitting a plurality of the contour reference points based on a plurality of the contour images to generate a contour reference point image file;
[0009] The standard contour line is placed in the contour reference point drawing file, and based on the starting end contour reference point and the ending end contour reference point, the standard contour line is adjusted according to a preset adjustment rule, and based on the adjusted standard contour line, a plurality of reference points are updated to obtain a plurality of actual reference points;
[0010] Determine the matching reference point corresponding to the contour reference point, and based on the connection trend of multiple actual reference points between any two adjacent matching reference points, synchronously generate a line segment connection between the contour reference points corresponding to the current two adjacent matching reference points to generate the actual processing contour line of the area to be processed.
[0011] In one embodiment of the first aspect, the step of acquiring a plurality of contour images on the area to be processed includes:
[0012] Acquire the number of shots of the area to be processed, and determine the shooting points of the area to be processed based on the number of shots;
[0013] The area to be processed is photographed sequentially according to the photographing points to obtain a plurality of the contour images.
[0014] In one embodiment of the first aspect, the step of obtaining a standard contour line of the area to be processed and a reference point on the standard contour line includes:
[0015] Loading a standard drawing of the area to be processed on the product to be processed; wherein the standard drawing includes the standard contour line; the standard drawing is a plane unfolding diagram;
[0016] The standard contour line is segmented at preset intervals, and intersection points of the segmented intervals on the standard contour line are obtained, wherein the reference point is the intersection point of the segmentation on the standard contour line.
[0017] In one embodiment of the first aspect, the step of acquiring a plurality of contour reference points based on a plurality of contour images includes:
[0018] Determining the first and last contour images and the middle contour image based on the acquisition order of the plurality of contour images;
[0019] Searching for line segments and arcs on the first and last contour images and the middle contour image, and constructing auxiliary straight lines for the searched line segments and arcs according to preset rules;
[0020] The intersection point between the auxiliary straight line and the line segment and the intersection point between the auxiliary straight line and the arc are determined as contour reference points.
[0021] In one embodiment of the first aspect, in the step of fitting the plurality of contour reference points based on the plurality of contour images to generate a contour reference point image file, the step includes:
[0022] Obtaining the distance between two adjacent shooting points in the area to be processed, and determining the center coordinates of each contour image;
[0023] Obtaining the relative coordinates of the contour reference points in the current contour image, and determining the actual coordinates of each of the contour reference points according to the center coordinates of the current contour image;
[0024] According to the acquisition order of the plurality of contour images, all the contour reference points are fitted and recorded to form a contour reference point image file.
[0025] In one of the embodiments of the first aspect, the step of adjusting the standard contour line according to a preset adjustment rule based on the starting end contour reference point and the terminating end contour reference point includes: adjusting the standard contour line so that the standard starting endpoint coincides with the starting end contour reference point, or the standard terminating endpoint coincides with the terminating end contour reference point, and the lateral distance between the standard starting endpoint and the standard terminating endpoint is the same as the lateral distance between the starting end contour reference point and the terminating end contour reference point.
[0026] In one embodiment of the first aspect, in the step of adjusting the standard contour line so that the standard starting endpoint and the starting end contour reference point coincide with each other, or the standard terminating endpoint and the terminating end contour reference point coincide with each other, and making the lateral distance between the standard starting endpoint and the standard terminating endpoint the same as the lateral distance between the starting end contour reference point and the terminating end contour reference point, and updating the multiple reference points based on the adjusted standard contour line to obtain the multiple actual reference points, the step includes:
[0027] Determine an adjustment reference point; wherein the adjustment reference point is the starting end contour reference point or the ending end contour reference point;
[0028] If the adjustment reference point is the starting end contour reference point, the standard starting end point is adjusted to coincide with the adjustment reference point; if the adjustment reference point is the ending end contour reference point, the standard ending end point is adjusted to coincide with the adjustment reference point;
[0029] According to the actual transverse distance between the starting end contour reference point and the ending end contour reference point, and the standard distance between the standard starting end point and the standard ending end point, the standard contour line is extended and retracted so that the standard distance is the same as the actual transverse distance;
[0030] Based on the numerical ratio of the scaling process, the coordinate values of the multiple reference points are updated synchronously to obtain the coordinate values of the multiple actual reference points.
[0031] In a second aspect, the present application also provides a contour extraction and generation system, the system comprising:
[0032] An information acquisition module, the information acquisition module is used to acquire a plurality of contour images on the area to be processed, a standard contour line of the area to be processed, and reference points on the standard contour line, wherein the reference points include a standard starting endpoint and a standard ending endpoint;
[0033] A contour reference point capture module, the contour reference point capture module is used to obtain a plurality of contour reference points based on a plurality of contour images; wherein the plurality of contour reference points are distributed on an actual contour line of the area to be processed; the contour reference points include a starting end contour reference point and an ending end contour reference point;
[0034] A drawing generation module, the drawing generation module is used to fit the plurality of contour reference points based on the plurality of contour images to generate a contour reference point drawing;
[0035] A drawing matching module, the drawing matching module is used to place the standard contour line in the contour reference point drawing, and adjust the standard contour line according to a preset adjustment rule based on the starting end contour reference point and the ending end contour reference point, and update the multiple reference points based on the adjusted standard contour line to obtain multiple actual reference points;
[0036] A contour fitting generation module is used to determine a matching reference point corresponding to the contour reference point, and based on the connection trend of multiple actual reference points between any two adjacent matching reference points, synchronously generate a line segment connection between the contour reference points corresponding to two currently adjacent matching reference points to generate an actual processing contour line of the area to be processed.
[0037] In a third aspect, the present application further provides a contour extraction and generation device, the contour extraction and generation device comprising an XYR platform, a top shooting module, a side shooting module and a processing module, the XYR platform, the top shooting module, and the side shooting module are electrically connected to the processing module respectively;
[0038] The top shooting module is located above the XYR platform, and is used to obtain an upper view of the product to be processed mounted on the XYR platform;
[0039] The side shooting module is located on the side of the XYR platform, and the side shooting module is used to obtain a side view of the product to be processed installed on the XYR platform;
[0040] The processing module is used to execute the contour extraction and generation method as described in any one of the above embodiments.
[0041] In a fourth aspect, an embodiment of the present application further provides an electronic device, including:
[0042] Memory, used to store computer programs;
[0043] A processor is used to execute the computer program to implement the contour extraction and generation method as described in any one of the above embodiments.
[0044] The embodiments of the present application have the following advantages:
[0045] The present application provides a contour extraction and generation method. First, the product to be processed is placed and fixed on the processing platform to ensure that it is stable and does not shift. Subsequently, a high-resolution camera or scanning device is used to shoot the side of the product to be processed, especially the area to be processed, from a preset perspective to capture a detailed contour image of the area in a digital way. This step uses optical technology and image acquisition hardware to complete the conversion of physical form to digital information. Secondly, through the image processing algorithm, the system automatically identifies and marks a series of key points, namely contour reference points, in the obtained contour image. These points are located at the key turning points of the contour line or the positions with obvious features, which help to define the geometric structure of the contour. Finally, the system has or receives a pre-set standard contour line, which defines the ideal processing contour shape and size. Next, the previously generated reference contour points are accurately mapped to this standard contour line through geometric transformation technology. In this process, the system automatically adjusts the position of each point on the standard contour line so that it coincides with the corresponding reference contour point. This step may include rotation, scaling and / or translation operations to ensure that the final contour line meets the design specifications and takes into account the individual differences of the actual products to be processed.
[0046] Therefore, through precise contour extraction and alignment, it is ensured that the actual contour of the product can be strictly followed during laser processing, which greatly improves the processing accuracy and reduces the processing errors caused by inaccurate positioning. In addition, this method can automatically adjust the processing path for products of different shapes and sizes to be processed, enhance the flexibility and adaptability of the processing system, and meet the needs of customized and batch diversified production. In addition, the automated process reduces the reliance on manual visual inspection and manual adjustment, which not only improves production efficiency, but also reduces the cost loss caused by manual errors. The precise contour matching enables the processing of each product to meet the design standards, improves the consistency and quality of the finished product, and enhances customer satisfaction.
[0047] The present application also relates to a system, a device and an electronic device. Since the above-mentioned contour extraction and generation method has the above-mentioned technical effects, a system, a device, an electronic device and a storage medium including the contour extraction and generation method should have the same technical effects, which will not be repeated here.
[0048] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and understandable, preferred embodiments are given below and described in detail with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0049] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0050] Figure 1 A schematic diagram of the structure of the contour extraction and generation system is shown;
[0051] Figure 2 A structural schematic diagram showing a perspective of a product to be processed;
[0052] Figure 3 The schematic diagram of the principle of method 1 for calculating the coordinates of the geometric center is shown;
[0053] Figure 4 The schematic diagram of the principle of the second method for calculating the geometric center coordinates is shown;
[0054] Figure 5 A first flow chart of a contour extraction and generation method is shown;
[0055] Figure 6 A schematic diagram showing the standard contour line is shown;
[0056] Figure 7 A schematic diagram showing the actual contour line;
[0057] Figure 8 A schematic diagram showing the machining contour line is shown;
[0058] Fig. 9 A structural schematic diagram showing another perspective of the product to be processed;
[0059] Fig.10 A schematic diagram of a first contour image is shown;
[0060] Fig.11 shows a schematic diagram of a second contour image;
[0061] Fig.12 A second flow chart of the contour extraction and generation method is shown;
[0062] Fig.13 A third flow chart of the contour extraction and generation method is shown;
[0063] Fig.14 A fourth flow chart of the contour extraction and generation method is shown;
[0064] Fig.15A fifth flow chart of the contour extraction and generation method is shown;
[0065] Fig.16 A sixth flow chart of the contour extraction and generation method is shown;
[0066] Fig.17 Shows a structural block diagram of the contour extraction and generation system;
[0067] Fig.18 Shows the internal structure of an electronic device.
[0068] Description of main component symbols:
[0069] 100-XYR platform; 200-top shooting module; 300-side shooting module; 400-product to be processed; 410-area to be processed; 411-processing end; 412-processing start; 413-starting section; 4131-first edge fitting line segment; 4132-first intermediate contour reference point; 4133-second edge fitting line segment; 4134-second intermediate contour reference point; 4135-first perpendicular midline; 4136-starting end contour reference point; 4137-third edge fitting line segment; 414-middle section; 4141-fourth edge fitting line segment; 4142-fourth intermediate contour reference point; 4143-fifth edge fitting line segment; 4144-fifth intermediate contour reference point; 415-terminal section; 4151 -sixth intermediate contour reference point; 4152-seventh intermediate contour reference point; 4153-termination end contour reference point; 500-standard contour line; 510-standard starting endpoint; 520-standard termination endpoint; 530-intermediate endpoint; 600-actual contour line; 700-processed contour line; 800-contour extraction generation system; 810-information acquisition module; 820-contour reference point capture module; 830-image generation module; 840-image matching module; 850-contour fitting generation module; 900-electronic device; 910-processor; 920-memory; 921-operating system; 922-computer program; 930-power supply; 940-communication interface; 950-input and output interface; 960-communication bus. DETAILED DESCRIPTION
[0070] The embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present application, and cannot be understood as limiting the present application.
[0071] It should be noted that when an element is referred to as being "fixed to" another element, it may be directly on the other element or there may be a central element. When an element is considered to be "connected to" another element, it may be directly connected to the other element or there may be a central element at the same time. In contrast, when an element is referred to as being "directly on" another element, there is no intermediate element. The terms "vertical", "horizontal", "left", "right" and similar expressions used herein are for illustrative purposes only.
[0072] In this application, unless otherwise clearly specified and limited, the terms "installed", "connected", "connected", "fixed" and the like should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements. For ordinary technicians in this field, the specific meanings of the above terms in this application can be understood according to specific circumstances.
[0073] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of this application, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.
[0074] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein in the specification of the template are only for the purpose of describing specific embodiments and are not intended to limit this application. The term "and / or" used herein includes any and all combinations of one or more of the related listed items.
[0075] In the related technologies, as smart wearable products are changing with each passing day, the technology of smart wearable products (smart watches) is constantly improving, and the requirements for high-quality process technology for process equipment are also increasing. That is, the innovation requirements from the traditional mechanical method to the intelligent method (high precision, high efficiency, high quality, and universality) have become an unstoppable trend in technological advancement.
[0076] Traditional visual positioning technology uses traditional visual means in imaging. The camera cannot accurately capture the corresponding laser target position on the product 400 to be processed, which makes it impossible for the algorithm to fit the grasping reference and actively generate an adaptive laser image file for each incoming material. Furthermore, before the laser, the equipment cannot actively generate a separate trajectory for each product, which cannot meet the customer's process requirements.
[0077] like Figure 1 and Figure 2 As shown, in some embodiments, the embodiments of the present application provide a contour extraction and generation device, which includes an XYR platform 100, a top shooting module 200, a side shooting module 300 and a processing module, and the XYR platform 100, the top shooting module 200, and the side shooting module 300 are electrically connected to the processing module respectively;
[0078] The top shooting module 200 is located above the XYR platform 100, and the top shooting module 200 captures an upper view of the product to be processed 400 mounted on the XYR platform 100;
[0079] The side shooting module 300 is located at the side of the XYR platform 100 , and the side shooting module 300 captures a side view of the product to be processed 400 mounted on the XYR platform 100 .
[0080] The design of the contour extraction and generation device integrates multiple key components, aiming to achieve efficient and accurate extraction and analysis of the contour of the product 400 to be processed placed on the XYR platform 100. The following is a detailed description of each part of the device and an overview of the workflow:
[0081] XYR platform 100: This is the core component for placing and positioning the product 400 to be processed, where "XYR" usually means that the platform can move in the X-axis and Y-axis directions, and can rotate in the R-axis, so that the product 400 to be processed has different angles and different positions in the contour extraction and generation device. Such a design greatly enhances the flexibility and scope of application of the device, so that the product 400 to be processed can be photographed and analyzed in all directions. The XYR platform 100 usually refers to a high-precision positioning or alignment platform, which is widely used in fields that require precise position control and adjustment, such as semiconductor manufacturing, electronic assembly, optical inspection, precision measurement, and biomedical engineering. The core feature of this type of platform is that it has the linear motion capability of the XY axes and the rotational motion of the R axis (usually refers to the rotation axis, such as the θz axis), which can achieve precise positioning and alignment in three-dimensional space.
[0082] Top shooting module 200: installed directly above the XYR platform 100, usually equipped with a high-definition camera or industrial camera, responsible for capturing the top surface view of the product to be processed 400 from an upper perspective. This perspective is crucial for obtaining the overall shape, size and top surface features of the product to be processed 400.
[0083] The side shooting module 300 is located on one side of the XYR platform 100 and is also equipped with a high-quality imaging device. Its task is to record the contour information of the area to be processed 410 on the side of the product to be processed 400 from the side, and to record the processing end end 411 and the processing start end 412 of the area to be processed 410. The side view is very important for understanding the side feature details of the product to be processed 400.
[0084] Processing module: As the data processing center of the device, the processing module is electrically connected to the top shooting module 200 and the side shooting module 300 respectively, and receives image data from these two modules. It usually includes a high-performance computing unit, image processing software and artificial intelligence algorithms for image preprocessing, feature extraction, contour recognition and necessary data analysis. Based on the acquired data, the processing module can generate an accurate contour model of the product to be processed 400, and support further acquisition of the contour line of the area to be processed 410 on the side of the product to be processed 400.
[0085] For ease of understanding, the workflow is provided as follows:
[0086] The product 400 to be processed is precisely mounted on the XYR platform 100 and adjusted to an ideal observation position through the movement of the platform.
[0087] The top shooting module 200 and the side shooting module 300 are respectively started to capture images of the product to be processed 400 from above and from the side. By moving and / or rotating the platform, multiple viewing angle images of the product to be processed 400 can be obtained to ensure full coverage.
[0088] The captured image data is transferred to the processing module, where the image undergoes preprocessing steps such as denoising, enhancement, and contrast adjustment for subsequent feature extraction.
[0089] The processing module controls the side shooting module 300 to shoot, and uses advanced image processing algorithms (such as edge detection, shape recognition, template matching, etc.) and machine learning technology to extract the contour information of the product 400 to be processed.
[0090] The processed contour data can be output in various forms, such as two-dimensional graphics, etc., providing intuitive and accurate information for quality control and production process optimization.
[0091] For example, a detailed embodiment is provided:
[0092] Step 1: Use the top camera module 200 to take a photo from a bird's-eye view of the product 400 to calculate the geometric center of the product. In the next step, when the side camera module 300 captures the processing area 410 on the side of the product 400, the XYR platform 100 drives the product 400 to move in the X and Y directions, so that the geometric center M of the product 400 coincides with the rotation center of the XYR platform 100; Figure 3 As shown, the method for calculating the geometric center coordinates is as follows:
[0093] 1) The product 400 to be processed is loaded and clamped by the fixture, and the XYR platform 100 drives the product 400 to be processed to move to the top shooting module 200 for taking pictures;
[0094] 2) Taking a photo of the product to be processed 400 from a top-down direction to obtain a top view;
[0095] 3) Using the conventional straight line search algorithm of machine vision, line segments L1, L2, L3, and L4 are searched respectively;
[0096] 4) The intersection points A, B, C, and D are constructed by line segments L1, L2, L3, and L4, i.e., the mechanical coordinates (X A , Y A )、(X B , Y B )、(X C , Y C )、(X D , Y D );
[0097] 5) Calculate the mechanical coordinates (X, Y) of the geometric center M:
[0098]
[0099] Obviously, the coordinates of the geometric center can be obtained through the above calculation.
[0100] Or, if Figure 4 As shown, the second method for calculating the geometric center coordinates is as follows:
[0101] 1) The product 400 to be processed is clamped by the fixture, and the XYR platform 100 drives the product 400 to be processed to move to the top camera shooting position;
[0102] 2) From the top view, the processed product 400 is viewed in the order of FOV-01→FOV-02→FOV-03→FOV-04, and the XY axis moves back to the photo position, and takes photos 4 times in sequence, and the following is obtained: Figure 4 As shown in the figure;
[0103] 3) In each image taken and positioned, the conventional straight line search algorithm of machine vision is used to find the line segments L1′ and L2′ respectively;
[0104] 4) Construct the intersection point A' through line segments L1' and L2'. Similarly, take four photos to obtain B', C', and D', which are the mechanical coordinates of the four corner points of the product rectangle (X A ′,Y A ′)、(X B ′,Y B ′)、(X C ′,Y C ′)、(X D ′,Y D ′);
[0105] 5) Calculate the mechanical coordinates (X, Y) of the geometric center M:
[0106]
[0107] Obviously, the coordinates of the geometric center can be obtained through the above calculation.
[0108] Through the XYR platform 100, in a three-axis linkage manner, ensure that each photographing position is moved to the field of view of the side shooting module 300, and ensure that the focus is clear (the photographing points are set in advance manually, and after the setting is completed, the XYR point values of each position are saved) to take pictures, and the area to be processed 410 on the product to be processed 400 is rotated in the direction of the processing starting end 412 → the processing ending end 411 to take pictures. With three-axis linkage, the side shooting module 300 takes pictures multiple times (the number of pictures can be set arbitrarily, and the more pictures are taken, the more accurate the restoration of the contour features of the product laser area is). This application takes 15 pictures as an example.
[0109] like Figure 5 As shown, the embodiment of the present application also provides a contour extraction generation method, which includes the following steps:
[0110] Step S100, obtaining a plurality of contour images on the area to be processed 410, a standard contour line 500 of the area to be processed 410, and reference points on the standard contour line 500.
[0111] Reference Figure 2 In this embodiment, the area to be processed 410 is a part of the product to be processed 400. The product to be processed 400 takes the frame of an electronic watch as an example, and the side of the product to be processed 400 has the area to be processed 410. The two ends of the area to be processed 410 respectively have a processing start end 412 and a processing end end 411. When acquiring multiple contour images on the area to be processed 410, the images are taken in the direction from the processing start end 412 to the processing end end 411. Of course, it can also be other products with similar structures, which are not specifically limited here.
[0112] The product 400 to be processed is fixed on the XYR platform 100 to ensure that the product 400 to be processed remains stable during subsequent operations. A high-precision camera or scanning device is used to capture a detailed image of the area 410 to be processed from the side.
[0113] For example, the XYR platform 100 is used to determine the center of the product 400 to be processed by using the top shooting module 200 in a three-axis linkage manner, and then the XYR platform is controlled to move so that the geometric center of the XYR platform is aligned with the center of the product 400 to be processed. After that, the product 400 to be processed is driven to rotate around the center, and the side shooting module 300 is used to shoot the side of the product 400 to be processed, so as to obtain multiple images of the area 410 to be processed. For example, the number of shots is 15 times. Of course, the number of shots is not limited. The more shots are taken, the more accurate the restoration of the contour features of the laser area of the product 400 to be processed is. It can be understood that in other embodiments, the number of shots can also be set to 16 times, 18 times, 19 times, 20 times, 21 times, 22 times, etc.
[0114] Reference Figure 6 The standard contour line 500 of the area to be processed 410 and the reference points on the standard contour line 500 are obtained by loading the standard drawing of the product to be processed 400. The standard drawing is output by the three-dimensional software after plane expansion calculation of the area to be processed 410 in the standard three-dimensional structure of the product to be processed 400. The standard drawing is a drawing in the form of a two-dimensional plane, and the standard drawing contains the standard contour line 500 of the area to be processed 410. The reference points are points at different positions on the standard contour line 500, and the reference points include a standard starting endpoint 510, a standard ending endpoint 520, and a plurality of intermediate endpoints 530.
[0115] In one embodiment, referring to Fig.12 , in the step of acquiring a plurality of contour images on the area to be processed 410, comprising:
[0116] Step S110 , obtaining the number of shots of the area to be processed 410 , and determining the shooting points of the area to be processed 410 based on the number of shots.
[0117] Step S120 , photographing the area to be processed 410 in sequence according to the photographing points to obtain a plurality of contour images.
[0118] In this embodiment, the number of shots required for shooting the entire area to be processed is set according to the size and shape of the area to be processed 410, as well as the accuracy requirements and processing efficiency requirements. The specific position of each shooting point is calculated according to the required number of shots and the size of the area to be processed 410, and the multiple shooting points are kept as evenly distributed as possible in the entire area to be processed 410, ensuring that multiple positions in the entire area to be processed 410 are shot. If the area to be processed 410 is large and the accuracy requirements for shooting and recognition are high, multiple shots may be required.
[0119] Specifically, after determining the number of shots, set the interval angles from different shooting points to the center of the product to be processed 400, save the XYR point values at each position, control the rotation angle of the rotating shaft in the XYR platform 100, and switch between different shooting points in the direction from the processing start end 412 to the processing end end 411 through three-axis linkage. Combined with the three-dimensional image of the product to be processed 400, the interval angles of each shot can be the same or different. The side shooting module 300 takes multiple shots, and the number of shots can be set arbitrarily. The more shots are taken, the more accurate the restoration of the contour features of the product laser area is.
[0120] The first shooting point is a point set in advance, the second shooting point is the position after the XYR platform 100 is rotated by a set angle, and so on, so that the rotation of different shooting points can be controlled. The distance between different shooting points in the area to be processed 410 is obtained by calculating the corresponding line segment distance on the unfolded standard drawing (two-dimensional plane) using the rotation angle set between different shooting points.
[0121] For example, during the contour extraction process, if the area to be processed 410 is large in size, multiple shots are required. The product to be processed 400 is driven by the XYR platform 100, so that the shooting points at different positions in the area to be processed of the product to be processed 400 can be moved to the position of the side shooting module 300, ensuring that each shot accurately covers the area where the current shooting point is located. After the shooting is completed, each contour image is preprocessed so that the contour reference point can be accurately extracted in the subsequent steps. This segmented shooting method can ensure that the necessary contour images can be accurately obtained even on a larger area to be processed 410, thereby improving the accuracy and reliability of the entire contour extraction generation method. This method is particularly suitable for products to be processed 400 that are large in size or irregular in shape, and can effectively overcome the limitations brought about by single-angle shooting.
[0122] In another embodiment, referring to Fig. 9, obtaining multiple contour images on the area to be processed 410 includes: dividing the area to be processed 410 into a starting segment 413, a middle segment 414 and a terminal segment 415 in its extension direction, and obtaining a first contour image of the starting segment 413 of the area to be processed 410, a second contour image of the middle segment 414 and a third contour image of the terminal segment 415.
[0123] In this embodiment, the contour image acquisition process of the area to be processed 410 is refined, and the accuracy and completeness of contour recognition are improved through a segmentation strategy. In this embodiment, the area to be processed 410 is logically divided into three parts along its circumferential extension direction: a starting section 413, a middle section 414, and a terminal section 415. Such division helps to analyze and process complex contours more carefully, especially when the product to be processed 400 is irregular in shape or contains multiple features.
[0124] For each segment, the corresponding contour image is acquired independently; among them, the first contour image of the starting segment 413 focuses on the starting edge of the area to be processed 410 to capture the characteristic details of this part. The second contour image of the middle segment 414 records the information of the middle part of the side of the product to be processed 400, which is often the shape change or special processing requirements; the third contour image of the terminal segment 415 focuses on the end boundary of the area to be processed 410 to ensure the closure and integrity of the contour. Image integration and analysis: After each contour image is initially processed, it is integrated into a complete contour image of the area to be processed 410 through image stitching or feature fusion technology.
[0125] This method helps to process and optimize the image quality of different parts separately, reduce the interference caused by factors such as shadows and reflections, and thus obtain a clearer and more accurate overall contour. In addition, segmented acquisition can optimize parameters such as exposure and focal length in a targeted manner, and has a stronger ability to capture the subtle differences of complex contours, avoiding the loss or blurring of certain local details caused by the overall perspective. Obviously, for the complex and changeable shapes of the product 400 to be processed, segmented processing can better adapt to various contour features, especially in areas with large curvature changes or special structures, which improves the versatility and robustness of the algorithm. Although the image acquisition step is increased, the actual processing time may not increase significantly through parallel processing or multi-threading technology. On the contrary, the overall processing efficiency is improved due to targeted processing. In addition, segmented analysis helps to accurately distinguish the natural features and defects on the surface of the product 400 to be processed, reduce the risk of misidentifying the features of the product 400 to be processed as processing errors, and ensure the accuracy of subsequent processing.
[0126] It should be noted that, exemplarily, the number of first contour images is set to be multiple, and the multiple first contour images respectively obtain various parts in the extension direction of the starting segment 413; for example, the number of first contour images is set to one, two, three, four, five, etc., and is not specifically limited here.
[0127] The number of second contour images is set to be multiple, and the multiple first contour images respectively obtain various parts in the extension direction of the middle section 414; for example, the number of second contour images is set to one, two, three, four, five, etc., which is not specifically limited here.
[0128] The number of third contour images is set to be multiple, and the multiple third contour images respectively obtain various parts in the extension direction of the terminal segment 415; for example, the number of third contour images is set to one, two, three, four, five, etc., which is not specifically limited here.
[0129] Exemplarily, in this embodiment, the number of contour images in the present application is 15; of course, in other embodiments, the number of contour images in the present application is 16, 17, 18, 19, etc.
[0130] It should be noted that the number of contour images can be set arbitrarily, but the greater the number of contour images, the more accurate the restoration of the contour features of the laser area of the product will be.
[0131] Reference Fig.13 , in the step of obtaining the standard contour line 500 of the area to be processed 410 and the reference points on the standard contour line 500, including:
[0132] Step S130 , loading a standard drawing of the area to be processed 410 on the product to be processed 400 .
[0133] Step S140 , dividing the standard contour line 500 into preset intervals, and obtaining intersection points of the interval divisions on the standard contour line 500 .
[0134] Among them, the standard drawing is a plane unfolding diagram, and the reference point is the intersection of the segmentation on the standard contour line 500. In this embodiment, a three-dimensional design drawing of the product to be processed 400, such as a CAD file, is loaded. The area to be processed 410 in the three-dimensional design drawing is plane unfolded using three-dimensional software to form a two-dimensional plane unfolding diagram. The plane unfolding diagram contains detailed information of the area to be processed 410, such as size, shape, edge contour, etc. For example, assuming that there is a complex metal part that needs to be processed, the CAD file of the part is used to plane unfold the surface to be processed through three-dimensional software to obtain a plane unfolding diagram of the processing area.
[0135] In this embodiment, the reference point on the standard contour line 500 is to cut the standard contour line 500 shown in the figure with a cutting line in the X direction at equal intervals (for example, 0.02 mm spacing, which can be adjusted arbitrarily according to the accuracy requirements), and the point where each cutting line intersects with the standard contour line 500 is the reference point. Among them, there is only one intersection point between the leftmost and rightmost edges of the standard contour line 500, namely, the standard starting endpoint 510 and the standard ending endpoint 520. There are two intersection points between other positions of the standard contour line 500 and the cutting line, namely, the middle endpoint 530. The equidistant cutting method can also be other methods, such as using a grid for cutting, and the cutting method is not specifically limited.
[0136] Cut in the X direction, first ensure that there is an intersection point at the leftmost edge, that is, the standard starting endpoint 510. Depending on the cutting accuracy, if there is no intersection point at the rightmost edge of the standard contour line 500, that is, the rightmost edge of the standard contour line 500 is located between two cutting lines. The average of the Y values of the two intersection points corresponding to the rightmost cutting line is used as the Y value of the standard termination endpoint 520. The X value of the standard termination endpoint 520 can be selected from the X values of the two intersection points corresponding to the rightmost cutting line, or a precision distance can be added to the X values of the two intersection points corresponding to the rightmost cutting line. The specific calculation method can be adjusted according to the accuracy, and the coordinates of multiple reference points on the standard contour line 500 will eventually be obtained.
[0137] Continue to refer to Figure 5 and Figure 7 , the contour extraction generation method comprises the following steps:
[0138] Step S200, acquiring multiple contour reference points based on multiple contour images.
[0139] The plurality of contour reference points are distributed on the actual contour line 600 of the to-be-processed area 410 in the contour image.
[0140] Among them, the contour reference points include a starting contour reference point 4136 , an ending contour reference point 4153 and multiple intermediate contour reference points, and the multiple intermediate contour reference points are located on the contour line between the starting contour reference point 4136 and the ending contour reference point 4153 .
[0141] In this embodiment, a plurality of contour reference points are identified and captured in each contour image, and these points are evenly distributed on the actual contour line 600 of the entire area to be processed 410 .
[0142] In this embodiment, in the acquired contour image, the software will automatically or manually identify and capture a series of key points as contour reference points of the actual contour line 600 on the area to be processed 410.
[0143] Reference Fig.14 , in the step of acquiring a plurality of contour reference points based on a plurality of contour images, comprising:
[0144] Step S210: determining the first and last contour images and the middle contour image based on the acquisition order of the plurality of contour images.
[0145] Step S220 , searching for line segments and arcs on the first and last contour images and the middle contour image, and constructing auxiliary straight lines for the searched line segments and arcs according to preset rules.
[0146] Step S230: determining the intersection point between the auxiliary straight line and the line segment and the intersection point between the auxiliary straight line and the arc as the contour reference point.
[0147] Among them, according to the shooting order, the first image taken is regarded as the first contour image, the last image taken is regarded as the last contour image, and the remaining images taken are regarded as the middle contour images. For example, according to the shooting order, assuming there are 5 contour images, which are numbered 1 to 5 in sequence. Then the first image (image 1) and the fifth image (image 5) are regarded as the first and last contour images respectively, and images 2, 3, and 4 are regarded as the middle contour images.
[0148] Using a visual search algorithm, line segments and arcs are searched for the captured images acquired in the order of shooting. There are straight line segments and arc segments in the head and tail contour images, while there are only straight line segments in the middle contour image. Therefore, in the head and tail contour images, the starting end contour reference point 4136 and the ending end contour reference point 4153 located on the arc segment, as well as the middle contour reference point can be identified; and in the middle contour image, the middle contour reference point can be identified. It can be understood that the use of a visual search algorithm to search for line segments and arcs in the captured images in this embodiment is only exemplary, and other methods that can clearly obtain line segments and arcs in the captured images can also be used, which are not specifically limited here.
[0149] Specifically, in the first and last contour images and the middle contour images, edge detection algorithms (such as Canny edge detection) are applied to identify line segments and arcs. For the found line segments and arcs, auxiliary straight lines are constructed according to preset rules, and the intersection points between the auxiliary straight lines and the identified line segments, and the intersection points between the auxiliary straight lines and the identified arcs are used to determine the contour reference points.
[0150] Reference Fig.10 and Fig.11In this embodiment, the first contour image is subjected to contour reference point capture processing, i.e., the first contour image. The first edge fitting line segment 4131, the second edge fitting line segment 4133, and the third edge fitting line segment 4137 in the first contour image are captured using the conventional straight line search algorithm and circle search algorithm of machine vision. The first edge fitting line segment 4131 is located at the upper edge of the contour line, the second edge fitting line segment 4133 is located at the lower edge of the contour line, and the third edge fitting line segment 4137 is located at the left edge of the contour line.
[0151] The straight line search algorithm outputs the midpoint of the first edge fitting line segment 4131, and uses the midpoint as the first intermediate contour reference point 4132 on the first edge fitting line segment 4131. The first intermediate contour reference point 4132 is used as a perpendicular midline, which is the constructed auxiliary straight line, namely the first perpendicular midline 4135. The first perpendicular midline 4135 intersects with the second edge fitting line segment 4133, and the intersection is used as the second intermediate contour reference point 4134 on the second edge fitting line segment 4133.
[0152] A perpendicular midline is drawn again on the first perpendicular midline 4135 so that the perpendicular midline intersects with the third edge fitting line segment 4137, and the intersection is used as the starting end contour reference point 4136 on the third edge fitting line segment 4137. In this embodiment, the contour reference point capture process is performed on the middle contour image, which is the same as the straight line portion in the contour reference point capture process in the first contour image. That is, the fourth edge fitting line segment 4141 and the fifth edge fitting line segment 4143 in the middle contour image are captured through the straight line search algorithm. The fourth edge fitting line segment 4141 is located at the upper edge of the contour line, and the fifth edge fitting line segment 4143 is located at the lower edge of the contour line.
[0153] The straight line search algorithm outputs the midpoint of the fourth edge fitting line segment 4141, and uses the midpoint as the fourth intermediate contour reference point 4142 on the fourth edge fitting line segment 4141. The fourth intermediate contour reference point 4142 is used as a perpendicular midline, and the perpendicular midline is the constructed auxiliary straight line. The auxiliary straight line intersects with the fifth edge fitting line segment 4143, and the intersection is used as the fifth intermediate contour reference point 4144 on the fifth edge fitting line segment 4143.
[0154] There are multiple intermediate contour images in this embodiment, so there are multiple fourth edge fitting line segments 4141 , fifth edge fitting line segments 4143 , fourth intermediate contour reference points 4142 , and fifth intermediate contour reference points 4144 that are actually captured.
[0155] In this embodiment, the contour reference point capture process for the tail contour image is the same as the contour reference point capture process for the first contour image, which will not be described in detail. Finally, the sixth middle contour reference point 4151, the seventh middle contour reference point 4152 and the terminal contour reference point 4153 in the tail contour image are captured.
[0156] Continue to refer to Figure 5 , the contour extraction generation method comprises the following steps:
[0157] Step S300, based on the multiple contour images, multiple contour reference points are fitted to generate a contour reference point image file.
[0158] In this step, according to the acquisition order of the multiple contour images and the multiple contour reference points obtained, the coordinate values of the multiple contour reference points are used to directly perform position fitting of the contour reference points to form a contour reference point image file.
[0159] Reference Fig.15 In the step of fitting multiple contour reference points to generate contour reference point drawing files based on multiple contour images, the method includes:
[0160] Step S310, obtaining the distance between two adjacent shooting points in the area to be processed 410, and determining the center coordinates of each shot image.
[0161] Step S320, obtaining the relative coordinates of the contour reference points in the current contour image, and determining the actual coordinates of each contour reference point according to the center coordinates of the current captured image.
[0162] Step S330 , fitting and recording all the contour reference points according to the acquisition sequence of the multiple contour images to form a contour reference point image file.
[0163] Among them, the first shooting point is pre-set, and the first shooting point of the product to be processed 400 is moved to the position of the side shooting module 300 for shooting. For the first shot image, the coordinates of the center of the shooting field of view are set to (0,0). Through the control of the XYR platform 100, each shooting point corresponds to the shooting field of view center of the current shot image. Since the interval angle between different shooting points is also pre-set, the plane unfolding diagram of the area to be processed 410 in the standard drawing of the product to be processed 400 can be used to calculate the spacing between the centers of the fields of view of the images shot at adjacent shooting points. Using the shooting sequence, the coordinates of the center points of the images shot at different shooting points can be calculated. For example, the spacing between the first point and the second shooting point is 10 mm, so the center coordinates of the second shot image are (10,0).
[0164] Since the contour reference points are obtained in different captured images, the distance of each contour reference point relative to the center of the field of view of the current captured image can be calculated through the pixel value, thereby obtaining the coordinates of each contour reference point. For all contour reference points, fitting is performed according to the coordinate values to obtain a contour reference point file of the distribution of contour reference points. For example, in the second captured image, the coordinates of the contour reference points obtained relative to the center of the field of view of the second captured image are (-1, 9) and (1, -10), respectively, then the actual coordinates of the contour reference points in the second captured image are (9, 9) and (11, -10). And so on, so as to obtain the actual coordinates of each contour reference point. And fitting is performed according to the actual coordinates to obtain the contour reference point file.
[0165] Step S400, places the standard contour line 500 in the contour reference point drawing, and adjusts the standard contour line 500 according to the preset adjustment rules based on the starting contour reference point 4136 and the ending contour reference point 4153, and updates multiple reference points based on the adjusted standard contour line 500 to obtain multiple actual reference points.
[0166] In this step, in order to compare the actual difference between the standard contour line 500 and the actual contour line 600, the standard contour line 500 is placed in the contour reference point file, and then the standard contour line 500 is scaled based on the leftmost and rightmost sides of the actual contour line 600.
[0167] After the standard contour line 500 is scaled, the coordinates of the original multiple reference points in the standard contour line 500 are scaled synchronously according to the value of the scaling change, so as to obtain the coordinates of the multiple actual reference points after the scaling process.
[0168] In some embodiments, based on the starting end contour reference point 4136 and the terminating end contour reference point 4153, adjusting the standard contour line 500 according to a preset adjustment rule includes: adjusting the standard contour line 500 so that the standard starting endpoint 510 coincides with the starting end contour reference point 4136, or the standard terminating endpoint 520 coincides with the terminating end contour reference point 4153, and making the lateral distance between the standard starting endpoint 510 and the standard terminating endpoint 520 the same as the lateral distance between the starting end contour reference point 4136 and the terminating end contour reference point 4153. It can be understood that in step S400, the standard contour line 500 is placed in the contour reference point drawing file, and then the position and size of the standard contour line 500 are adjusted so that the standard starting endpoint 510 and the starting end contour reference point 4136 coincide with each other, or the standard ending endpoint 520 and the ending end contour reference point 4153 coincide with each other, and the lateral distance between the standard starting endpoint 510 and the standard ending endpoint 520 is the same as the lateral distance between the starting end contour reference point 4136 and the ending end contour reference point 4153, so as to facilitate subsequent actual difference comparison.
[0169] Reference Fig.16 In the step of adjusting the standard contour line 500 so that the standard starting endpoint 510 coincides with the starting contour reference point 4136, or the standard ending endpoint 520 coincides with the ending contour reference point 4153, and the lateral distance between the standard starting endpoint 510 and the standard ending endpoint 520 is the same as the lateral distance between the starting contour reference point 4136 and the ending contour reference point 4153, and updating the multiple reference points based on the adjusted standard contour line 500 to obtain the multiple actual reference points, the steps include:
[0170] Step S410, determining an adjustment reference point.
[0171] Step S420, if the adjustment reference point is the starting end contour reference point 4136, the standard starting endpoint 510 is adjusted to coincide with the adjustment reference point; if the adjustment reference point is the ending end contour reference point 4153, the standard ending endpoint 520 is adjusted to coincide with the adjustment reference point.
[0172] Step S430, based on the actual lateral distance between the starting contour reference point 4136 and the ending contour reference point 4153, and the standard distance between the standard starting endpoint 510 and the standard ending endpoint 520, the standard contour line 500 is scaled so that the standard distance and the actual lateral distance are the same.
[0173] Step S440 , based on the numerical ratio of the scaling process, the coordinate values of the multiple reference points are synchronously updated to obtain the coordinate values of the multiple actual reference points.
[0174] When the contour reference points are fitted to generate the contour reference point drawing file, the fitting is performed using the coordinates of the contour reference points. Then, for the contour reference point drawing file generated by fitting, the lateral length of the actual contour reference point distribution track is the lateral distance between the starting end contour reference point 4136 and the ending end contour reference point 4153. The actual lateral distance can be calculated using the coordinates.
[0175] The standard contour line 500 is obtained by loading a standard document, and the standard distance between the standard starting endpoint 510 and the standard ending endpoint 520 can be calculated and output when the standard drawing file is generated.
[0176] Exemplarily, before the standard contour line 500 is stretched or retracted, the adjustment reference point of the standard contour line 500 can be first determined; wherein the adjustment reference point is the starting end contour reference point 4136, or the ending end contour reference point 4153 of the actual contour line 600; if the adjustment reference point is the starting end contour reference point 4136, then the standard starting end point 510 of the standard contour line 500 is coincident with the adjustment reference point; if the adjustment reference point is the ending end contour reference point 4153, then the standard ending end point 520 of the standard contour line 500 is coincident with the adjustment reference point.
[0177] After adjusting the standard starting endpoint 510 to coincide with the starting end contour reference point 4136, or the standard ending endpoint 520 to coincide with the ending end contour reference point 4153, if the standard distance is smaller than the actual lateral distance, the standard contour line 500 is stretched; if the standard distance is larger than the actual lateral distance, the standard contour line 500 is shortened.
[0178] By performing the stretching process on the standard contour line 500, the standard distance and the actual horizontal distance are made the same, that is, in order to better compare the contour reference point drawing with the standard contour line 500 in the standard drawing more accurately. In addition, after the stretching process of the standard distance, the multiple reference points on the standard contour line 500 are also synchronously stretched. That is, the coordinate value of the reference point is changed to the coordinate value of the actual reference point after stretching.
[0179] Reference Figure 5 and Figure 8 , the contour extraction generation method comprises the following steps:
[0180] Step S500, determine the matching reference point corresponding to the contour reference point, and based on the connection trend of multiple actual reference points between any two adjacent matching reference points, synchronously generate the line segment connection between the contour reference points corresponding to the current two adjacent matching reference points to generate the actual processing contour line 700 of the area to be processed 410.
[0181] The matching reference point is a part of the multiple actual reference points in the standard contour line 500. Since the standard contour line 500 has been stretched and retracted, and the position of the standard contour line 500 has been adjusted, the captured contour reference point and the multiple actual reference points can be used for matching.
[0182] In this embodiment, the horizontal coordinate value is used as the object of matching, that is, among the multiple actual reference points on the standard contour line 500, the actual reference point with the same horizontal coordinate as the contour reference point is retrieved and matched, and is determined as the matching reference point. In combination with the accuracy of the reference point of the standard contour line 500 during cutting and division, if the horizontal coordinate of the contour reference point is not matched to an actual reference point with the same coordinate value among the multiple actual reference points on the standard contour line 500, the actual reference point with the closest horizontal coordinate value can also be selected as the matching reference point.
[0183] These matching reference points can help evaluate the deviation between the actual contour and the standard contour, so that the actual processing contour line can be generated more accurately. Specifically, at this time, the contour reference point and the matching reference point are the same or closest in the horizontal coordinate, and the difference between the contour reference point and the matching reference point in the vertical coordinate is the actual difference of the product to be processed 400. The difference in the edge of the actual processing contour will not change suddenly. Therefore, the connection trend of multiple actual reference points between two adjacent matching reference points, that is, the edge distribution trend of the standard contour line 500, is used to synchronously generate the edge connection distribution between the current two contour reference points, that is, the actual contour edge distribution.
[0184] In this embodiment, multiple corresponding points between the current two contour reference points are calculated and generated based on multiple actual reference points between two adjacent matching reference points to obtain new edge contour data, and then the corresponding points are connected using line segments to ultimately form a line segment connection between the current two contour reference points, that is, the actual edge contour line.
[0185] The edge contour data are connected front and back with small line segments to finally obtain the processing contour line 700, that is, after connecting all adjacent contour reference points with line segments, the actual processing contour line 700 of the entire processing area 410 is finally formed. This fine adjustment ensures that the processing contour can adapt to the slight variation of the actual product 400 to be processed, and improves the adaptability and accuracy of the processing.
[0186] Obviously, this application proposes an innovative contour extraction and generation method, which aims to solve the problem that traditional visual positioning technology cannot accurately locate the target position before laser processing, which in turn affects the automatic generation of laser processing trajectories and the difficulty of adapting to diversified product needs.
[0187] In addition, this method significantly improves the positioning accuracy and adaptability before laser processing through intelligent image processing and contour analysis, ensuring that even complex and changeable products can achieve personalized, high-precision laser processing, perfectly meeting the customer's specific process requirements. This method not only improves production efficiency, but also reduces the scrap rate caused by inaccurate positioning, and has high practical value and market potential.
[0188] like Fig.17 As shown, in some embodiments, the present application further provides a contour extraction generation system 800, the system comprising:
[0189] The information acquisition module 810 is used to acquire a plurality of contour images on the area to be processed 410 , a standard contour line 500 of the area to be processed 410 , and reference points on the standard contour line 500 .
[0190] The contour reference point capture module 820 is used to obtain multiple contour reference points based on multiple contour images; wherein the multiple contour reference points are distributed on the actual contour line of the area to be processed; the contour reference points include the starting end contour reference point and the ending end contour reference point.
[0191] The image file generating module 830 is used to generate an outline reference point image file by fitting multiple outline reference points based on multiple outline images.
[0192] The image matching module 840 is used to place the standard contour line 500 in the contour reference point image, and adjust the standard contour line 500 according to a preset adjustment rule based on the starting end contour reference point 4136 and the ending end contour reference point 4153, and update multiple reference points based on the adjusted standard contour line to obtain multiple actual reference points;
[0193] The contour fitting generation module 850 is used to determine the matching reference point corresponding to the contour reference point, and based on the connection trend of multiple actual reference points between any two adjacent matching reference points, synchronously generate the line segment connection between the contour reference points corresponding to the current two adjacent matching reference points to generate the actual processing contour line 700 of the area to be processed 410.
[0194] In some embodiments, Fig.18 As shown, an electronic device 900 is provided, including a memory 920 and a processor 910, wherein the memory 920 is used to store a computer program 922; and the processor 910 is used to execute the computer program 922 to implement a contour extraction and generation method.
[0195] It should be noted that Fig.18This is a structural diagram of an electronic device 900 according to an exemplary embodiment. The content in the diagram cannot be regarded as any limitation on the scope of use of the present application.
[0196] Specifically, the electronic device 900 may include: at least one processor 910, at least one memory 920, a power supply 930, a communication interface 940, an input / output interface 950, and a communication bus 960. The memory 920 is used to store a computer program 922, which is loaded and executed by the processor 910 to implement the relevant steps in the contour extraction and generation method disclosed in any of the aforementioned embodiments. In addition, the electronic device 900 in this embodiment may specifically be an electronic computer.
[0197] In this embodiment, the power supply 930 is used to provide working voltage for each hardware device on the electronic device 900; the communication interface 940 can create a data transmission channel between the electronic device 900 and external devices, and the communication protocol it follows is any communication protocol that can be applied to the technical solution of the present application, and is not specifically limited here; the input and output interface 950 is used to obtain external input data or output data to the outside world, and its specific interface type can be selected according to specific application needs and is not specifically limited here.
[0198] In addition, the memory 920, as a carrier for storing resources, can be a read-only memory 920, a random access memory 920, a disk or an optical disk, etc. The resources stored thereon can include an operating system 921, a computer program 922, etc., and the storage method can be temporary storage or permanent storage.
[0199] The operating system 921 is used to manage and control the hardware devices and computer programs 922 on the electronic device 900, and can be Windows Server, Netware, Unix, Linux, etc. In addition to the computer program 922 that can be used to complete the contour extraction and generation method disclosed in any of the aforementioned embodiments, the computer program 922 can further include a computer program 922 that can be used to complete other specific tasks.
[0200] In one embodiment, a computer readable storage medium is provided for storing a computer program 922, which implements the aforementioned disclosed contour extraction and generation method when executed by the processor 910. The specific steps of the method can refer to the corresponding contents disclosed in the aforementioned embodiment, and will not be repeated here.
[0201] In this specification, each embodiment is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the embodiments can be referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part.
[0202] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0203] The steps of the methods or algorithms described in conjunction with the embodiments disclosed herein may be implemented directly using hardware, software modules executed by the processor 910, or a combination of the two. The software modules may be placed in a random access memory 920 (RAM), a memory, a read-only memory 920 (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
[0204] In all examples shown and described herein, any specific values should be interpreted as merely exemplary and not as limiting, and thus other examples of the exemplary embodiments may have different values.
[0205] It should be noted that similar reference numerals and letters denote similar items in the following drawings, and therefore, once an item is defined in one drawing, further definition and explanation thereof is not required in subsequent drawings.
[0206] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application.
Claims
1. A contour extraction and generation method, characterized in that: The contour extraction generation method comprises: Acquire multiple contour images of the area to be processed, a standard contour line of the area to be processed, and reference points on the standard contour line, wherein the reference points include a standard starting endpoint and a standard ending endpoint; Acquire multiple contour reference points based on the multiple contour images; wherein the multiple contour reference points are distributed on the actual contour line of the area to be processed; the contour reference points include a starting end contour reference point and an ending end contour reference point; Fitting a plurality of the contour reference points based on a plurality of the contour images to generate a contour reference point image file; The standard contour line is placed in the contour reference point drawing file, and based on the starting end contour reference point and the ending end contour reference point, the standard contour line is adjusted according to a preset adjustment rule, and based on the adjusted standard contour line, a plurality of reference points are updated to obtain a plurality of actual reference points; Determine the matching reference point corresponding to the contour reference point, and based on the connection trend of multiple actual reference points between any two adjacent matching reference points, synchronously generate a line segment connection between the contour reference points corresponding to the current two adjacent matching reference points to generate the actual processing contour line of the area to be processed.
2. The contour extraction and generation method according to claim 1, characterized in that: The step of acquiring a plurality of contour images on the area to be processed includes: Acquire the number of shots of the area to be processed, and determine the shooting points of the area to be processed based on the number of shots; The area to be processed is photographed sequentially according to the photographing points to obtain a plurality of the contour images.
3. The contour extraction and generation method according to claim 1, characterized in that: The step of obtaining the standard contour line of the area to be processed and the reference points on the standard contour line includes: Loading a standard drawing of the area to be processed on the product to be processed; wherein the standard drawing includes the standard contour line; the standard drawing is a plane unfolding diagram; The standard contour line is segmented into preset intervals, and intersection points of the segmented intervals on the standard contour line are obtained, wherein the reference point is the intersection point of the segmentation on the standard contour line.
4. The contour extraction and generation method according to claim 2, characterized in that: The step of acquiring a plurality of contour reference points based on a plurality of contour images comprises: Determining the first and last contour images and the middle contour image based on the acquisition order of the plurality of contour images; Searching for line segments and arcs on the first and last contour images and the middle contour image, and constructing auxiliary straight lines for the searched line segments and arcs according to preset rules; The intersection point between the auxiliary straight line and the line segment and the intersection point between the auxiliary straight line and the arc are determined as contour reference points.
5. The contour extraction and generation method according to claim 4, characterized in that: In the step of fitting the plurality of contour reference points based on the plurality of contour images to generate a contour reference point drawing file, the step includes: Acquire the distance between two adjacent shooting points in the area to be processed, and determine the center coordinates of each contour image; Obtaining the relative coordinates of the contour reference points in the current contour image, and determining the actual coordinates of each of the contour reference points according to the center coordinates of the current contour image; According to the acquisition order of the plurality of contour images, all the contour reference points are fitted and recorded to form a contour reference point image file.
6. The contour extraction and generation method according to claim 1, characterized in that: The step of adjusting the standard contour line according to a preset adjustment rule based on the starting end contour reference point and the terminating end contour reference point includes: Adjust the standard contour line so that the standard starting endpoint and the starting end contour reference point coincide with each other, or the standard ending endpoint and the ending end contour reference point coincide with each other, and the lateral distance between the standard starting endpoint and the standard ending endpoint is the same as the lateral distance between the starting end contour reference point and the ending end contour reference point.
7. The contour extraction and generation method according to claim 6, characterized in that: The step of adjusting the standard contour line so that the standard starting endpoint and the starting end contour reference point coincide with each other, or the standard ending endpoint and the ending end contour reference point coincide with each other, and making the lateral distance between the standard starting endpoint and the standard ending endpoint the same as the lateral distance between the starting end contour reference point and the ending end contour reference point, and updating the plurality of reference points based on the adjusted standard contour line to obtain the plurality of actual reference points includes: Determine an adjustment reference point; wherein the adjustment reference point is the starting end contour reference point or the ending end contour reference point; If the adjustment reference point is the starting end contour reference point, the standard starting end point is adjusted to coincide with the adjustment reference point; if the adjustment reference point is the ending end contour reference point, the standard ending end point is adjusted to coincide with the adjustment reference point; According to the actual transverse distance between the starting end contour reference point and the ending end contour reference point, and the standard distance between the standard starting end point and the standard ending end point, the standard contour line is extended and retracted so that the standard distance is the same as the actual transverse distance; Based on the numerical ratio of the scaling process, the coordinate values of the multiple reference points are updated synchronously to obtain the coordinate values of the multiple actual reference points.
8. A contour extraction and generation system, characterized in that: The system comprises: An information acquisition module, the information acquisition module is used to acquire a plurality of contour images on the area to be processed, a standard contour line of the area to be processed, and reference points on the standard contour line, wherein the reference points include a standard starting endpoint and a standard ending endpoint; A contour reference point capture module, the contour reference point capture module is used to obtain a plurality of contour reference points based on a plurality of contour images; wherein the plurality of contour reference points are distributed on an actual contour line of the area to be processed; the contour reference points include a starting end contour reference point and an ending end contour reference point; A drawing generation module, the drawing generation module is used to fit the plurality of contour reference points based on the plurality of contour images to generate a contour reference point drawing; A drawing matching module, the drawing matching module is used to place the standard contour line in the contour reference point drawing, and adjust the standard contour line according to a preset adjustment rule based on the starting end contour reference point and the ending end contour reference point, and update the multiple reference points based on the adjusted standard contour line to obtain multiple actual reference points; A contour fitting generation module is used to determine a matching reference point corresponding to the contour reference point, and based on the connection trend of multiple actual reference points between any two adjacent matching reference points, synchronously generate a line segment connection between the contour reference points corresponding to two currently adjacent matching reference points to generate an actual processing contour line of the area to be processed.
9. A contour extraction and generation device, characterized in that: The contour extraction and generation device comprises an XYR platform, a top shooting module, a side shooting module and a processing module, wherein the XYR platform, the top shooting module and the side shooting module are electrically connected to the processing module respectively; The top shooting module is located above the XYR platform, and the top shooting module is used to obtain an upper end view of the product to be processed mounted on the XYR platform; The side shooting module is located on the side of the XYR platform, and the side shooting module is used to obtain a side view of the product to be processed installed on the XYR platform; The processing module is used to execute the contour extraction and generation method as described in any one of claims 1 to 7.
10. An electronic device, characterized in that: include: Memory, used to store computer programs; A processor, configured to execute the computer program to implement the contour extraction and generation method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Cube characterization method based on target group recognition and form judgment
CN116012629A
Method and apparatus for determining and storing the position and orientation of antenna structures
US20140205205A1
Image processing apparatus, image processing method, and storage medium
US20200057907A1
Cited By
Image processing method, electronic equipment and computer readable storage medium
CN119722721A
Fabric layout pattern overlapping detection method and system
CN120707524A
Marine observation data intelligent processing system
CN121213682A
