Workpiece surface profile tolerance detection method and system, electronic equipment and storage medium
By acquiring the measurement data set of the workpiece through laser scanning and performing contour fitting and calculation, the problems of slow detection speed and low accuracy of traditional three-dimensional coordinate measuring machines are solved, and efficient and accurate workpiece surface contour detection is achieved.
Patent Information
- Application Number
- CN202510631899.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-16
- Publication Date
- 2025-09-09
AI Technical Summary
Traditional three-dimensional coordinate measuring machines have slow detection speed and low accuracy, making it difficult to measure small chamfers and large batches of workpieces, and have low detection efficiency.
The measurement data set is acquired through laser scanning, contour fitting is performed, the optimal contour data is determined, and the detection result is determined based on the workpiece surface contour, preset standard value and threshold.
The accuracy and efficiency of workpiece surface profile detection are improved, and it is able to identify small contours and directly compare contour fitting to improve the accuracy of detection results.
Smart Images

Figure CN120609293A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of workpiece detection, and in particular to a method, system, device and storage medium for detecting workpiece surface profile. Background Art
[0002] After the workpiece is produced, the surface profile of the workpiece needs to be inspected to determine whether the workpiece is qualified. Traditional surface profile detection uses a three-dimensional coordinate measuring machine to measure the workpiece, but the measurement speed of the three-dimensional coordinate measuring machine is slow and the point interval is large. It cannot measure small chamfers in the workpiece and has low detection accuracy. It is also difficult to apply to the detection of large quantities of workpieces and has low detection efficiency. Summary of the Invention
[0003] The main purpose of the embodiments of the present invention is to provide a workpiece surface profile detection method, system, electronic equipment and storage medium, which can improve detection efficiency and detection accuracy.
[0004] To achieve the above object, an embodiment of the present invention provides a method for detecting a workpiece surface profile, the method comprising:
[0005] Acquire a measurement data set; wherein the measurement data set is determined by laser scanning the workpiece to be measured according to preset parameters;
[0006] Performing contour fitting based on the measurement data set and preset standard contour data to determine optimal contour data, and performing calculation based on the optimal contour data and the measurement data set to determine the workpiece surface contour;
[0007] The workpiece detection result is determined according to the workpiece surface profile, a preset standard value and a preset threshold value.
[0008] In some embodiments, performing contour fitting based on the measurement data set and preset standard contour data to determine optimal contour data specifically includes:
[0009] performing difference calculation based on the measurement data set and the preset standard contour data to determine a contour deviation value set, and sorting the contour deviation value set to determine a target deviation value;
[0010] The data set to be measured is corrected according to the target deviation value to determine a corrected measurement data set; and fitting is performed according to the target deviation value and the corrected measurement data set to determine the optimal contour data.
[0011] In some embodiments, the calculating based on the optimal profile data and the measurement data set to determine the workpiece surface profile specifically includes:
[0012] Calculating based on the optimal contour data and the preset deviation value, respectively determining the upper deviation value of the surface contour and the lower deviation value of the surface contour;
[0013] performing difference calculations based on the measurement data set and the upper deviation value of the surface profile to determine a first difference set; performing difference calculations based on the measurement data set and the lower deviation value of the surface profile to determine a second difference set;
[0014] The first difference value set is sorted to determine a first deviation value; the second deviation value set is sorted to determine a second deviation value; and the workpiece surface profile is determined by calculation based on the first deviation value and the second deviation value.
[0015] In some embodiments, determining the workpiece detection result according to the workpiece surface profile, a preset standard value, and a preset threshold value specifically includes:
[0016] Calculating the difference between the workpiece surface profile and the preset standard value to determine a profile error value, and comparing the profile error value with the preset threshold value;
[0017] If the contour error value is greater than the preset threshold, determining that the workpiece detection result is unqualified;
[0018] If the contour error value is less than or equal to the preset threshold, the workpiece detection result is determined to be qualified.
[0019] In some embodiments, the method further comprises:
[0020] Performing feature recognition on the workpiece to be measured to determine groove feature information of the workpiece;
[0021] Determining a groove data set by comparing the workpiece groove feature information with the measurement data set, and determining groove profile data by performing calculations based on the groove data set;
[0022] Calculation is performed based on the groove profile data and the measurement data set to determine the workpiece profile data, and the workpiece profile data and preset standard profile data are sent to the front-end device so that the front-end device displays them based on the workpiece profile data and the standard profile data.
[0023] To achieve the above-mentioned purpose, another aspect of an embodiment of the present invention provides a workpiece surface profile detection system, the system comprising a measuring module and a processing module; wherein,
[0024] The measurement module is used to perform group laser scanning on the workpieces to be measured to generate several groups of measurement data sets;
[0025] The processing module is used to execute the method according to any one of claims 1 to 5.
[0026] In some embodiments, the system further includes a control module; the control module is configured to obtain user input and generate system parameters based on the user input; wherein the system parameters include preset parameters, preset standard values, and preset thresholds.
[0027] In some embodiments, the system further includes a display module, and the display module is used to display the preset standard contour data and the workpiece contour data, and to present the workpiece detection result.
[0028] To achieve the above-mentioned purpose, another aspect of an embodiment of the present application provides an electronic device, which includes a memory and a processor, wherein the memory stores a computer program, and the processor implements the above-mentioned method when executing the computer program.
[0029] To achieve the above objectives, another aspect of an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method described above is implemented.
[0030] Implementation of the embodiments of the present invention includes the following beneficial effects: The embodiments of the present invention provide a workpiece surface profile detection method, system, electronic device, and storage medium. The scheme obtains a measurement data set generated by scanning a workpiece requiring surface profile detection according to preset parameters; then, profile fitting is performed based on the workpiece's measurement data set and standard profile data preset in the system to obtain optimal profile data corresponding to the workpiece's measurement data set, and calculations are performed based on the obtained optimal profile data and the workpiece's measurement data to determine the workpiece surface profile corresponding to the workpiece; finally, calculations are performed based on the obtained workpiece surface profile, a preset standard value in the system, and a preset threshold to determine the detection result of the workpiece surface profile. Obtaining measurement data through laser scanning can identify small contours and improve detection accuracy; contour fitting is performed based on the preset standard contour data and measurement data, and the surface profile is calculated based on the fitted contour to determine the detection result of the workpiece. Through direct contour comparison, detection efficiency and detection accuracy are improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] Figure 1 This is a schematic flow chart of the steps of a workpiece surface profile detection method provided by an embodiment of the present invention;
[0032] Figure 2 This is a schematic flow chart of the steps for determining optimal profile data in a workpiece surface profile detection method provided by an embodiment of the present invention;
[0033] Figure 3This is a schematic flow chart of the steps for determining the workpiece surface profile in a workpiece surface profile detection method provided by an embodiment of the present invention;
[0034] Figure 4 This is a schematic flow chart of the steps for determining a workpiece detection result in a workpiece surface profile detection method provided by an embodiment of the present invention;
[0035] Figure 5 This is a schematic flow chart of the steps of displaying contour data in a workpiece surface contour detection method provided by an embodiment of the present invention;
[0036] Figure 6 This is a schematic structural diagram of a detection device in a specific embodiment provided by an embodiment of the present invention;
[0037] Figure 7 is a schematic diagram of a cylindrical workpiece in a specific embodiment provided by an embodiment of the present invention;
[0038] Figure 8 is a schematic diagram of fitting the actual contour of a workpiece in a specific embodiment provided by an embodiment of the present invention;
[0039] Figure 9 Schematic diagram of the structure of a workpiece surface profile detection system provided by an embodiment of the present invention;
[0040] Figure 10 This is a schematic structural diagram of an algorithm module in a workpiece surface profile detection system provided by an embodiment of the present invention;
[0041] Figure 11 1 is a schematic diagram of the hardware structure of an electronic device provided by an embodiment of the present invention;
[0042] Among them, a is the upper deviation line of the surface contour, b is the measured dense point contour, and c is the lower deviation line of the surface contour. DETAILED DESCRIPTION
[0043] The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. The step numbers in the following embodiments are provided for ease of description only and do not limit the order of the steps. The order of execution of the steps in the embodiments can be adaptively adjusted based on the understanding of those skilled in the art.
[0044] In the following description, reference is made to “some embodiments”, which describes a subset of all possible embodiments, but it will be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.
[0045] In the following description, the terms "first\second\third" are merely used to distinguish similar objects and do not represent a specific ordering of the objects. It is understandable that "first\second\third" can be interchanged with a specific order or sequence where permitted, so that the embodiments of the present invention described herein can be implemented in an order other than that illustrated or described herein.
[0046] Unless otherwise defined, all technical and scientific terms used in the embodiments of the present invention have the same meanings as those commonly understood by those skilled in the art to which the present invention pertains. The terms used in the embodiments of the present invention are for the purpose of describing the embodiments of the present invention only and are not intended to limit the present invention.
[0047] Figure 1 This is an optional flow chart of a workpiece surface profile detection method provided by an embodiment of the present invention. Figure 1 The method may include but is not limited to steps S101 to S103.
[0048] Step S101, obtaining a measurement data set; wherein the measurement data set is determined by laser scanning the workpiece to be measured according to preset parameters;
[0049] Step S102, performing contour fitting based on the measurement data set and the preset standard contour data to determine the optimal contour data, and performing calculation based on the optimal contour data and the measurement data set to determine the workpiece surface profile;
[0050] Step S103 , determining a workpiece detection result according to the workpiece surface profile, a preset standard value, and a preset threshold value.
[0051] In steps S101 to S103 illustrated in the embodiment of the present application, the user places the workpiece to be inspected on a system that applies a workpiece surface profile detection method provided by an embodiment of the present invention, and starts the system to inspect the workpiece; the system performs a laser scan on the cross-section of the workpiece using pre-set system parameters to obtain measurement data of the workpiece; then, the system performs contour fitting based on the scanned measurement data and preset standard contour data, such as the drawing data of the workpiece; the error between the actual contour of the workpiece and the preset standard contour is calculated based on the measurement data and the preset standard contour data, and the optimal position of the actual contour of the workpiece is fitted, and the surface profile of the current cross-section of the workpiece is obtained by calculation based on the obtained optimal position of the actual contour and the measurement data of the workpiece; then, based on whether the error between the calculated surface profile of the workpiece and the system preset standard value is within the allowable error range, it is determined whether the surface profile detection of the workpiece is qualified, as the detection result of the workpiece.
[0052] In step S101 of some embodiments, a cross section of the workpiece can be arbitrarily selected for laser scanning, and after obtaining measurement data, the workpiece surface profile can be detected. Alternatively, the system can be configured to set a measurement starting point and measurement step length, and continuous laser scanning can be automatically performed according to the system settings to obtain measurement data for multiple sets of different workpiece cross sections for detection, without limitation.
[0053] See also Figure 2 In some embodiments, step S102 may include but is not limited to steps S201 to S202:
[0054] Step S201, performing difference calculation based on the measurement data set and the preset standard contour data to determine a contour deviation value set, and sorting the contour deviation value set to determine a target deviation value;
[0055] Step S202 , correcting the dataset to be measured according to the target deviation value to determine a corrected measurement dataset; fitting the target deviation value and the corrected measurement dataset to determine optimal contour data.
[0056] In step S201 of some embodiments, after the system obtains the measurement data of the workpiece cross section, it performs difference calculation based on the measurement data and the preset standard contour data in the system to determine the deviation between the actual contour of the workpiece and the standard contour, and performs synchronous positioning between the actual workpiece and the standard contour based on the deviation value between the actual contour and the standard contour; by sorting the calculated deviations, the measurement point with the smallest deviation value between the actual contour and the standard contour is selected, and the workpiece is synchronously positioned based on the measurement point; at the same time, the actual contour of the workpiece is fitted according to the deviation value corresponding to the measurement point.
[0057] In step S202 of some embodiments, the measurement data obtained by laser scanning is corrected according to the deviation value of the measurement point, with the same deviation value; based on the corrected measurement data, the various measurement points are connected to fit the optimal contour data of the workpiece; in this embodiment, the number of measurement points in the measurement data can be changed by setting system parameters, thereby adjusting the fitting accuracy; illustratively, the workpiece is scanned once every 0.5 degrees to obtain 720 measurement point data of the workpiece cross section; the workpiece can also be scanned once every 0.2 degrees to obtain 1800 measurement point data of the workpiece cross section to improve measurement accuracy and fitting accuracy.
[0058] See also Figure 3 In some embodiments, step 102 may also include but is not limited to steps S301 to S303:
[0059] Step S301, performing calculations based on the optimal contour data and the preset deviation values to determine the upper deviation value and the lower deviation value of the surface contour respectively;
[0060] Step S302, performing difference calculation based on the measurement data set and the upper deviation value of the surface contour to determine a first difference value set; performing difference calculation based on the measurement data set and the lower deviation value of the surface contour to determine a second difference value set;
[0061] Step S303 , sorting the first difference value set to determine the first deviation value; sorting the second deviation value set to determine the second deviation value; and calculating based on the first deviation value and the second deviation value to determine the workpiece surface profile.
[0062] In step S301 of some embodiments, after fitting the optimal contour data of the workpiece, the system performs calculations according to the deviation value set in the system to obtain a deviation area set based on the optimal contour data, which includes upper and lower limit values, and the upper and lower limit values are used as the upper deviation value and the lower deviation value of the surface contour; illustratively, the upper offset is set to 0.1 and the lower offset is set to 0.1 to obtain an area with a width of 0.2, and the surface contour of the workpiece is calculated based on the measurement data of the area and the workpiece cross section.
[0063] In step S302 of some embodiments, the system performs difference calculations on the measurement data of each measurement point and the calculated upper deviation value and lower deviation value of the surface profile, and calculates the absolute value of the difference, that is, calculates the distance from each measurement point to the set deviation area boundary; and sorts out the distance of each measurement point data to the upper boundary of the deviation area and the distance to the lower boundary of the deviation area to obtain a first difference set and a second difference set, which are used for subsequent calculation of the surface profile of the workpiece.
[0064] In step S303 of some embodiments, the first difference set obtained is sorted to determine the measurement point farthest from the upper boundary of the deviation area in the measurement data of the workpiece cross section and the corresponding distance; similarly, the second difference set obtained is sorted to determine the measurement point farthest from the lower boundary of the deviation area in the measurement data of the workpiece cross section and the corresponding distance; then, the deviation values corresponding to the determined test points are summed and calculated to obtain the workpiece surface profile of the current cross section of the workpiece.
[0065] See also Figure 4 In some embodiments, step S103 may include but is not limited to steps S401 to S403:
[0066] Step S401, performing difference calculation based on the workpiece surface profile and a preset standard value to determine a profile error value, and comparing the profile error value with a preset threshold value;
[0067] Step S402: If the contour error value is greater than a preset threshold, the workpiece detection result is determined to be unqualified;
[0068] Step S403: If the contour error value is less than or equal to the preset threshold, the workpiece detection result is determined to be qualified.
[0069] In step S401 of some embodiments, after obtaining the surface profile of the current cross-section of the workpiece, the system calculates the difference between the preset standard surface profile and the calculated surface profile of the current cross-section of the workpiece as the error value of the surface profile of the workpiece, and compares the calculated error value with the acceptable error threshold set in the system to determine whether the current cross-section of the workpiece meets the requirements.
[0070] In step S402 of some embodiments, the system compares the calculated error value with a preset error threshold and determines that the calculated error value is greater than the preset error threshold, indicating that the surface profile detection result of the current cross-section of the workpiece is unqualified. The system can mark the detection result of the current cross-section of the workpiece or send a reminder message to the user.
[0071] In step S403 of some embodiments, the system compares the calculated error value with a preset error threshold to determine that the calculated error value is less than or equal to the preset error threshold, indicating that the surface profile error of the current cross-section of the workpiece is within an acceptable error range, and determines that the surface profile detection result of the current cross-section of the workpiece is qualified. The system can record the current detection result or send a prompt message to the user.
[0072] See also Figure 5 In some embodiments, a workpiece surface profile detection method provided by an embodiment of the present invention may further include but is not limited to steps S501 to S503:
[0073] Step S501, performing feature recognition on the workpiece to be measured to determine the groove feature information of the workpiece;
[0074] Step S502 , comparing the workpiece groove feature information with the measurement data set to determine the groove data set, and performing calculations based on the groove data set to determine the groove profile data;
[0075] Step S503 , performing calculations based on the groove profile data and the measurement data set to determine the workpiece profile data, and sending the workpiece profile data and the preset standard profile data to the front-end device so that the front-end device can display the workpiece profile data and the standard profile data.
[0076] In step S501 of some embodiments, the system obtains measurement data by scanning the workpiece that needs to be tested for surface contour, and performs feature recognition on the scanned measurement data through the system's built-in program or algorithm to determine feature information such as grooves on the workpiece surface; illustratively, for irregular and asymmetric cylindrical workpieces, there are grooves on their surfaces, and through scanning and recognition, the feature information of the grooves of such workpieces, such as the position of the grooves, the diameter of the grooves, the depth, and other information, is determined to improve the accuracy of subsequent fitting of the workpiece contour.
[0077] In step S502 of some embodiments, the system compares the characteristic information of the groove obtained by scanning with the measurement data of the workpiece cross section to determine the measurement data corresponding to the groove characteristic information in the measurement data; the system compares and determines the portion of the measurement data corresponding to the groove characteristic information as a groove data set; the system calculates and processes the obtained groove data set and the identified groove characteristic information to obtain the contour data of the workpiece at the groove position.
[0078] In step S503 of some embodiments, the system performs calculations based on the obtained contour data at the groove position and the measurement data of the current cross-section of the workpiece to obtain actual contour data of the workpiece, which includes the groove contour data; the system sends the obtained actual contour data of the workpiece and the standard contour data pre-set in the system to the front-end display device, and displays them to the user through the display device.
[0079] The following describes the solution of the embodiment of the present invention in detail with reference to specific application examples:
[0080] See also Figure 6 , Figure 6The invention relates to a detection device for a workpiece surface profile detection method provided by an embodiment of the present invention. The device in the figure includes a laser measuring head 2-1, which adopts a high-precision laser sensor to measure the surface profile of the workpiece to be measured by emitting a laser beam and receiving a reflected signal, with a measurement accuracy of 0.001 mm; a moving stepping device 2-2, which includes a high-precision stepping motor in the three directions of X, Y, and Z, for controlling the spatial positioning of the laser measuring head 2-1 to achieve accurate scanning of the workpiece to be measured; a high-precision pneumatic chuck motor 2-3, for clamping the workpiece to be measured; a display screen 2-4, for displaying the operating system interface of the detection device and displaying the parameter settings and detection results of the workpiece detection; an operating device 2-5, connected to the detection device, for user human-computer interaction and adjustment of the parameter settings of the workpiece detection; a program acquisition and algorithm module 2-6, including a data acquisition module 6.1, for receiving measurement data from the laser measuring head, including the cylinder diameter, groove diameter, etc. of the workpiece to be measured. Position, transition R value, depth and other information; Feature recognition module 6.2, used to identify the semicircular groove feature on the cylindrical surface of the workpiece to be measured, calculate its diameter and depth through laser feedback, form a number of points, and connect the points to form the actual contour of the workpiece to be measured; Surface profile analysis module 6.3, used to set the measurement path, step length, starting position, and interval distance by yourself. For example: start measuring 15mm from the left end of the workpiece to be measured, measure a contour every 5mm, and measure a total of 7 sections; you can also set it to start measuring 15mm from the left end, measure a contour every 3mm, and set a total of 10 sections. The detection equipment will automatically measure the data of the workpiece to be measured according to the set parameters; Qualification judgment module 6.4, this module supports the import of dxl format data, and requires that the imported graphic is a complete closed drawing, that is, a 360° circle, and the lines cannot be interrupted or overlapped. Set the surface contour according to the requirements, and the surface contour can be adjusted according to the requirements.
[0081] After setting the system parameters, place the workpiece to be tested on the high-precision pneumatic chuck motor for clamping. Figure 7 As shown; users adjust the detection parameters in the detection equipment according to measurement requirements, such as Figure 8As shown, the cylindrical surface has a uniformly distributed irregular profile divided into four equal parts, with a smooth transition. Measurements are taken starting 15 mm from the left end of the cylindrical workpiece and every 5 mm, for a total of seven measurements. The inspection equipment measures the workpiece according to the set parameters. The inspection equipment processes the laser reflection data received by the laser measuring head in real time, namely the point cloud data, identifies the cylindrical features, calculates the profile, and after determining the surface profile of the current segment, controls the mobile stepper to step to the next section for measurement. This continues until the set number of sections are measured, and the inspection results for the cylindrical workpiece are output. In the measurement of each section, the detection equipment measures a point every 0.5 degrees according to the setting, and obtains 720 sets of comparison data. The detection equipment processes the detected comparison data and determines that the data with the smallest comparison data is the data with the highest profile fit. This is used to automatically judge the coincidence and fit the best position. The upper deviation line and the lower deviation line of the surface profile are determined according to the set surface profile and upper and lower deviation values, and are marked on the display device. The surface profile of the current section is calculated according to the reflection data received by the laser measuring head and the marked upper deviation line and lower deviation line of the surface profile. The surface profile of the current section is then judged whether the error between the surface profile and the standard surface profile set by the detection equipment is within an acceptable range. The surface profile of the current section of the workpiece is then judged whether it is qualified by judging the detection results of the surface profile of all detected sections.
[0082] Implementation of the embodiments of the present invention includes the following beneficial effects: The embodiments of the present invention provide a workpiece surface profile detection method, system, electronic device, and storage medium. The scheme scans a workpiece requiring surface profile detection according to preset parameters to determine a measurement data set for the workpiece. Then, profile fitting is performed based on the workpiece measurement data set and standard profile data preset in the system to obtain optimal profile data corresponding to the workpiece measurement data set. Calculation is performed based on the obtained optimal profile data and the workpiece measurement data to determine the workpiece surface profile corresponding to the workpiece. Finally, calculation is performed based on the obtained workpiece surface profile, a preset standard value in the system, and a preset threshold to determine the surface profile detection result of the workpiece. Acquiring measurement data through laser scanning can identify fine contours and improve detection accuracy. Profile fitting is performed based on the preset standard contour data and measurement data, and the surface profile is calculated based on the fitted contour to determine the detection result of the workpiece. Through direct contour comparison, detection efficiency and detection accuracy are improved.
[0083] like Figure 9 As shown, an embodiment of the present invention further provides a workpiece surface profile detection system, comprising a measuring module and a processing module; wherein,
[0084] The measurement module is used to perform group laser scanning on the workpieces to be measured to generate several groups of measurement data sets;
[0085] The processing module is used to execute any one of the methods provided in the above method embodiments.
[0086] It can be seen that the contents of the above method embodiments are all applicable to the present system embodiments. The functions specifically implemented by the present system embodiments are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above method embodiments.
[0087] See also Figure 10 In some embodiments, the algorithm module in the workpiece surface profile detection system provided by the embodiment of the present invention may include but is not limited to a data acquisition submodule, a feature recognition submodule, a surface profile analysis submodule, and a qualification determination submodule; wherein,
[0088] The data acquisition submodule is used to acquire several groups of measurement data sets generated by the measurement module;
[0089] The feature recognition submodule is used to generate workpiece contour data according to the system parameters and several groups of measurement data sets;
[0090] The surface profile analysis submodule is used to determine the surface profile according to the preset standard profile data and the workpiece profile data;
[0091] The qualification determination submodule is used to determine the workpiece detection result according to the system parameters and the surface profile.
[0092] In some embodiments, the data acquisition submodule receives the measurement data of the workpiece from the measurement module via wired or wireless means, and sends it to the feature recognition submodule to perform feature recognition processing on the measurement data, identify the semicircular groove features on the surface of the cylindrical workpiece, calculate the diameter and depth of the semicircular groove, form a number of points, and obtain the actual contour of the semicircular groove by connecting the points; the measurement data is then analyzed and processed by the surface contour analysis submodule to obtain the surface contour of the cylindrical workpiece; finally, the qualification judgment submodule determines whether the workpiece is qualified based on the workpiece surface contour output by the surface contour analysis submodule based on the imported workpiece drawing data.
[0093] In some embodiments, a workpiece surface profile detection system provided by an embodiment of the present invention may also include but is not limited to a control module, which is used to obtain user input and generate system parameters based on the user input; wherein the system parameters include preset parameters, preset standard values and preset thresholds.
[0094] In some embodiments, the system is also provided with a control module, which is connected to the system's external device, obtains the user's external input, and generates system parameters based on the user's input information; illustratively, the user inputs the diameter and length of the current batch of workpieces through the external device, inputs the measurement of the current batch of tools every 0.5 degrees, and enters parameters to determine that the first measurement starts from 15 mm on the left side of the workpiece, and enters the number of measurement segments; the system's control module generates corresponding system parameters based on the user's input, and automatically measures the current batch of workpieces based on the system parameters, and gives corresponding detection results.
[0095] In some embodiments, a workpiece surface profile detection system provided by an embodiment of the present invention may further include, but is not limited to, a display module, wherein the display module is used to display the preset standard profile data and the workpiece profile data, and to present the workpiece detection result.
[0096] In some embodiments, the system is provided with a display module to extract the workpiece contour from the imported workpiece drawing, and compare and display the actual workpiece contour detected by the system with the workpiece contour in the drawing, so as to facilitate the user to intuitively understand the surface contour detection results of the workpiece.
[0097] The present application also provides an electronic device comprising a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the aforementioned workpiece surface profile detection method. The electronic device can be any smart terminal, such as a tablet computer or an in-vehicle computer.
[0098] It can be understood that the contents of the above method embodiments are applicable to the present device embodiments, the functions specifically implemented by the present device embodiments are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above method embodiments.
[0099] See also Figure 11 , Figure 11 The hardware structure of an electronic device according to another embodiment is shown. The electronic device includes:
[0100] The processor 1101 can be implemented as a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of the present application.
[0101] The memory 1102 can be implemented in the form of a read-only memory (ROM), a static storage device, a dynamic storage device, or a random access memory (RAM). The memory 1102 can store an operating system and other application programs. When the technical solutions provided in the embodiments of this specification are implemented through software or firmware, the relevant program code is stored in the memory 1102 and is called by the processor 1101 to execute a workpiece surface profile detection method according to the embodiments of this application.
[0102] Input / output interface 1103, used to implement information input and output;
[0103] Communication interface 1104, used to implement communication interaction between this device and other devices, which can be achieved through wired means (such as USB, network cable, etc.) or wireless means (such as mobile network, WiFi, Bluetooth, etc.);
[0104] Bus 1105 , which transmits information between various components of the device (e.g., processor 1101 , memory 1102 , input / output interface 1103 , and communication interface 1104 );
[0105] The processor 1101 , the memory 1102 , the input / output interface 1103 and the communication interface 1104 are connected to each other in communication within the device via a bus 1105 .
[0106] An embodiment of the present application further provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the above-mentioned workpiece surface profile detection method is implemented.
[0107] It can be understood that the contents of the above method embodiments are all applicable to the present storage medium embodiment, the functions specifically implemented by the present storage medium embodiment are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above method embodiments.
[0108] Among them, the memory is a non-transient computer-readable storage medium that can be used to store non-transient software programs and non-transient computer executable programs. The memory may include a high-speed random access memory and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some embodiments, the memory optionally includes a remote memory remotely arranged relative to the processor, and these remote memories can be connected to the processor via a network. Examples of the above-mentioned network include but are not limited to the Internet, an intranet, a local area network, a mobile communication network and a combination thereof.
[0109] In addition, the embodiments of the present application further disclose a computer program product or computer program, which is stored in a computer-readable storage medium. The processor of a computer device can read the computer program from the computer-readable storage medium, and the processor executes the computer program, so that the computer device performs the above-mentioned method. Similarly, the contents of the above-mentioned method embodiment are all applicable to the present storage medium embodiment, and the functions specifically implemented by the present storage medium embodiment are the same as those of the above-mentioned method embodiment, and the beneficial effects achieved are also the same as those achieved by the above-mentioned method embodiment.
[0110] It is understood that all or some steps, systems in the disclosed method above can be implemented as software, firmware, hardware and appropriate combinations thereof. Some physical components or all physical components can be implemented as software by a processor, such as a central processing unit, a digital signal processor or a microprocessor, or implemented as hardware, or implemented as an integrated circuit, such as an application specific integrated circuit. Such software can be distributed on a computer-readable medium, and the computer-readable medium can include computer storage media (or non-transitory media) and communication media (or temporary media). As known to those of ordinary skill in the art, the term computer storage medium is included in any method or technology for storing information (such as computer-readable instructions, data structures, program modules or other data) and is volatile and non-volatile, removable and non-removable media. Computer storage media includes but is not limited to RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disk (DVD) or other optical disk storage, magnetic cassette, magnetic tape, disk storage or other magnetic storage device, or can be used to store desired information and any other medium that can be accessed by a computer. Furthermore, as is well known to those skilled in the art, communication media typically embodies computer-readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media.
[0111] The above is a specific description of the preferred implementation of the present invention, but the invention is not limited to the embodiments. Those skilled in the art can make various equivalent modifications or substitutions without violating the spirit of the present invention. These equivalent modifications or substitutions are all included in the scope defined by the claims of this application.
Claims
1. A method for detecting the profile of a workpiece surface, characterized in that: The method comprises: Acquire a measurement data set; wherein the measurement data set is determined by laser scanning the workpiece to be measured according to preset parameters; Performing contour fitting based on the measurement data set and preset standard contour data to determine optimal contour data, and performing calculation based on the optimal contour data and the measurement data set to determine the workpiece surface contour; The workpiece detection result is determined according to the workpiece surface profile, a preset standard value and a preset threshold value.
2. The method according to claim 1, characterized in that The performing contour fitting according to the measurement data set and the preset standard contour data to determine the optimal contour data specifically includes: performing difference calculation based on the measurement data set and the preset standard contour data to determine a contour deviation value set, and sorting the contour deviation value set to determine a target deviation value; The data set to be measured is corrected according to the target deviation value to determine a corrected measurement data set; and fitting is performed according to the target deviation value and the corrected measurement data set to determine the optimal contour data.
3. The method according to claim 1, characterized in that The calculating based on the optimal profile data and the measurement data set to determine the workpiece surface profile specifically includes: Calculating based on the optimal contour data and the preset deviation value, respectively determining the upper deviation value of the surface contour and the lower deviation value of the surface contour; performing difference calculations based on the measurement data set and the upper deviation value of the surface profile to determine a first difference set; performing difference calculations based on the measurement data set and the lower deviation value of the surface profile to determine a second difference set; The first difference value set is sorted to determine a first deviation value; the second deviation value set is sorted to determine a second deviation value; and the workpiece surface profile is determined by calculation based on the first deviation value and the second deviation value.
4. The method according to claim 1, wherein The determining of the workpiece detection result according to the workpiece surface profile, the preset standard value and the preset threshold value specifically includes: Calculating the difference between the workpiece surface profile and the preset standard value to determine a profile error value, and comparing the profile error value with the preset threshold value; If the contour error value is greater than the preset threshold, determining that the workpiece detection result is unqualified; If the contour error value is less than or equal to the preset threshold, the workpiece detection result is determined to be qualified.
5. The method according to claim 1, wherein The method further comprises: Performing feature recognition on the workpiece to be measured to determine groove feature information of the workpiece; Determining a groove data set by comparing the workpiece groove feature information with the measurement data set, and determining groove profile data by performing calculations based on the groove data set; Calculation is performed based on the groove profile data and the measurement data set to determine the workpiece profile data, and the workpiece profile data and preset standard profile data are sent to the front-end device so that the front-end device displays them based on the workpiece profile data and the standard profile data.
6. A workpiece surface profile detection system, characterized in that: The system includes a measurement module and a processing module; wherein the measurement module is used to perform group laser scanning on the workpiece to be measured to generate several groups of measurement data sets; The processing module is used to execute the method according to any one of claims 1 to 5.
7. The system according to claim 6, characterized in that The system further includes a control module; the control module is configured to obtain user input and generate system parameters according to the user input; wherein the system parameters include preset parameters, preset standard values, and preset thresholds.
8. The system according to claim 6, wherein: The system further includes a display module, which is used to display the preset standard contour data and the workpiece contour data, and to present the workpiece detection result.
9. An electronic device, characterized in that: include: at least one processor; at least one memory for storing at least one program; When the at least one program is executed by the at least one processor, the at least one processor implements the method according to any one of claims 1 to 5.
10. A computer-readable storage medium storing a program executable by a processor, characterized in that: The processor-executable program is used to perform the method according to any one of claims 1 to 5 when executed by the processor.