A laser processing color parameter prediction and reverse design method, device and equipment
By constructing a nonlinear mapping between laser parameters and color output using a multilayer perceptron neural network model, the problem of inconsistent color control in laser color marking is solved, achieving high-precision and scalable laser color marking.
Patent Information
- Application Number
- CN202610153406.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-02-03
- Publication Date
- 2026-06-02
AI Technical Summary
In existing laser color marking technologies, there is a strong nonlinearity and parameter coupling effect between color output and laser parameters, which leads to a lack of consistency and repeatability in color control, making it difficult to achieve high precision and scalability.
A multilayer perceptron neural network model is adopted, and a 7-dimensional feature vector is constructed based on various laser scanning strategies. Nonlinear mapping is performed through the multilayer perceptron neural network model to achieve forward prediction and reverse design of laser parameters and color output data.
It significantly improves the consistency and intelligence of laser color marking, reduces parameter trial and error time, improves processing efficiency and color stability, and solves the problems of poor accuracy and scalability in laser color processing.
Smart Images

Figure CN122125357A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of materials processing technology, and in particular to a method, apparatus and equipment for predicting and reverse designing color parameters in laser processing. Background Technology
[0002] Laser color marking (LCM) is an advanced manufacturing technology that achieves pattern and color processing on the surface of materials such as metals using high precision and non-contact methods. Its core mechanisms mainly include laser-induced oxide film interference and surface structure manipulation, and it can be widely used in anti-counterfeiting marking, decorative processing, aircraft component coding, and electronic component identification. This technology not only enables high-resolution pattern output but also endows metal surfaces with specific optical functions, thus showing broad application prospects in industrial design, medical devices, and consumer electronics.
[0003] Traditional color generation relies on experimental methods, manually adjusting process parameters such as laser power, scanning speed, pulse frequency, and scanning path to obtain the target color. However, there is a strong nonlinearity and parameter coupling effect between color output and laser parameters. Different parameter combinations often result in similar colors or color shifts, leading to a lack of consistency and repeatability in color control, reducing process optimization efficiency, and greatly hindering the large-scale industrial application of color generation.
[0004] To address these issues, researchers have recently attempted to introduce artificial intelligence (AI) methods for modeling and prediction. Artificial Neural Networks (ANNs), as a nonlinear regression tool, have been initially used to predict the mapping between laser parameters and colors. However, their model performance is still limited by factors such as sample sparsity and poor generalization ability, making them unsuitable for widespread application in complex processing strategies and multi-material, multi-batch scenarios.
[0005] Furthermore, most existing research only focuses on color prediction and lacks a general solution for color reverse engineering (i.e., inputting a target color and working backward to deduce the optimal laser parameters). Especially when dealing with various scanning strategies and different metal surface conditions, the accuracy, efficiency, and scalability of color prediction and reverse engineering urgently need improvement.
[0006] There is currently no effective solution to the problems of poor accuracy and scalability in existing laser color processing technologies. Summary of the Invention
[0007] This invention provides a method, apparatus, and equipment for predicting and reverse designing color parameters in laser processing, which addresses the shortcomings of poor accuracy and scalability in existing related technologies for laser color processing, and enables high-precision modeling, forward prediction, and reverse design between color output and laser process parameters during laser color marking.
[0008] In a first aspect, the present invention provides a method for predicting and reverse-engineering color parameters in laser processing, comprising: Laser color marking was performed on a metal substrate using various laser scanning strategies, and color output data under different laser parameters were collected. Based on the laser scanning strategy, a 7-dimensional feature vector corresponding to the laser parameters is constructed; Based on the 7-dimensional feature vector, a multilayer perceptron neural network model is established, and a nonlinear mapping is performed between the laser parameters and the color output data; The target color value or target laser parameters are obtained by forward prediction or backward design using the multilayer perceptron neural network model.
[0009] According to the present invention, a laser processing color parameter prediction and reverse design method is provided, wherein the laser scanning strategy includes single scanning, dual scanning, orthogonal scanning, color scanning with first preprocessing parameters and color scanning with second preprocessing parameters.
[0010] According to the present invention, a method for predicting and reverse-engineering color parameters in laser processing is provided. This method employs multiple laser scanning strategies to perform laser color marking on a metal substrate surface and collects color output data under different laser parameters, including: Laser color marking was performed on a metal substrate using various laser scanning strategies, and color output data was collected under different laser power and scanning speed conditions. The colors in the output color data are represented using the three channels of lightness, red-green, and yellow-blue in the Lab color space, forming a dataset containing multiple combined samples.
[0011] According to the laser processing color parameter prediction and reverse design method provided by the present invention, a 7-dimensional feature vector corresponding to the laser parameters is constructed based on the laser scanning strategy, including: The laser scanning strategy is transformed into a discrete feature vector using one-hot encoding. By combining the two continuous variables, laser power and scanning speed, a 7-dimensional input feature vector is constructed.
[0012] According to the present invention, a method for predicting and reverse-engineering color parameters in laser processing is provided. Based on the 7-dimensional feature vector, a multilayer perceptron neural network model is established, and a nonlinear mapping is performed between the laser parameters and the color output data, including: Based on the 7-dimensional feature vectors, a multilayer perceptron neural network model containing at least three hidden layers is constructed. The laser parameters and the color output data are nonlinearly mapped using the ReLU activation function and batch normalization operation.
[0013] According to the laser processing color parameter prediction and reverse engineering method provided by the present invention, the multilayer perceptron neural network model is trained using the Adam optimizer, including: Set the initial learning rate and maximum number of training epochs for training the multilayer perceptron neural network model; An early stopping strategy is used to train the multilayer perceptron neural network model to avoid overfitting; The loss function during training is a combination of the L1 function and the Smooth L1 function.
[0014] According to the present invention, a method for predicting and reverse-engineering color parameters in laser processing is provided, which performs forward prediction using the multilayer perceptron neural network model, including: The laser parameters of the processing procedure are input into the multilayer perceptron neural network model to predict the target color value obtained based on the current laser parameters.
[0015] According to the present invention, a method for predicting and reverse-engineering color parameters in laser processing is provided, which performs reverse engineering using the multilayer perceptron neural network model, including: Using the target color value as the optimization objective / constraint, the multilayer perceptron neural network model is fed with fixed parameters. Gradient iteration is performed on the laser power and scanning speed to obtain the target laser parameters that minimize the color error.
[0016] Secondly, the present invention also provides a laser processing color parameter prediction and reverse design apparatus, comprising: The acquisition module is used to perform laser color marking on the surface of a metal substrate using various laser scanning strategies and to acquire color output data under different laser parameters. The processing module is used to construct a 7-dimensional feature vector corresponding to the laser parameters based on the laser scanning strategy. The construction module is used to establish a multilayer perceptron neural network model based on the 7-dimensional feature vector, and to perform nonlinear mapping between the laser parameters and the color output data; The execution module is used to perform forward prediction or backward design through the multilayer perceptron neural network model to obtain the target color value or target laser parameters.
[0017] Thirdly, the present invention also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the laser processing color parameter prediction and reverse design method as described in the first aspect above.
[0018] Fourthly, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the laser processing color parameter prediction and reverse design method as described in the first aspect above.
[0019] Fifthly, the present invention also provides a computer program product, including a computer program that, when executed by a processor, implements the laser processing color parameter prediction and reverse design method as described in the first aspect above.
[0020] Compared with the prior art, the present invention has the following beneficial effects: The laser processing color parameter prediction and reverse design method provided by this invention enables rapid color prediction and accurate reverse design, which can significantly improve the consistency and intelligence level of laser color marking, reduce parameter trial and error time, improve processing efficiency and color stability, and solve the problems of poor laser color processing accuracy and scalability in existing related technologies. Attached Figure Description
[0021] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0022] Figure 1 This is a flowchart of the laser processing color parameter prediction and reverse design method provided by the present invention; Figure 2 This is a schematic diagram of the laser color processing experimental platform and scanning arrangement in an embodiment of the present invention; Figure 3 This is a schematic diagram of five laser scanning strategies used in embodiments of the present invention; Figure 4 This is a graph showing the variation of training and testing errors when the multilayer perceptron neural network model performs a color prediction task in an embodiment of the present invention. Figure 5 This is a fitting graph of the prediction accuracy of the multilayer perceptron neural network model on the test dataset in an embodiment of the present invention; Figure 6This is a statistical graph of prediction error and color difference of the multilayer perceptron neural network model on the validation dataset in this embodiment of the invention; Figure 7 These are laser-processed surface microstructure images under different scanning strategies in embodiments of the present invention; Figure 8 This is a structural block diagram of the laser processing color parameter prediction and reverse design device provided by the present invention; Figure 9 This is a schematic diagram of the structure of the electronic device provided by the present invention. Detailed Implementation
[0023] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.
[0024] This invention provides a method for predicting and reverse-engineering color parameters in laser processing. Figure 1 This is a flowchart of the laser processing color parameter prediction and reverse design method provided by the present invention, such as... Figure 1 As shown, the method includes the following steps: Step S101: Laser color marking is performed on the surface of the metal substrate using various laser scanning strategies, and color output data under different laser parameters is collected. Step S102: Based on the laser scanning strategy, construct a 7-dimensional feature vector corresponding to the laser parameters; Step S103: Based on the 7-dimensional feature vector, establish a multilayer perceptron neural network model and perform nonlinear mapping on the laser parameters and color output data; Step S104: Forward prediction or backward design is performed using a multilayer perceptron neural network model to obtain the target color value or target laser parameters.
[0025] In this method, firstly, laser color marking experiments are conducted on a metal substrate surface using various laser scanning strategies to collect color output data under different laser parameter conditions. Then, based on the laser scanning strategies, a 7-dimensional feature vector corresponding to the laser parameters is constructed. Next, based on these 7-dimensional feature vectors, a neural network model incorporating a multilayer perceptron (MLP) is established to realize a nonlinear mapping relationship between laser parameters and color output data. Finally, forward prediction or backward design is performed using the MLP neural network model to obtain the target color value or target laser parameters. Through this process, rapid color prediction and accurate backward design are achieved, significantly improving the consistency and intelligence level of laser color marking, reducing parameter trial-and-error time, increasing processing efficiency and color stability, and solving the problems of poor accuracy and scalability in existing related technologies.
[0026] In the above methods, the laser scanning strategies include single scanning, dual scanning, orthogonal scanning, color scanning with first preprocessing parameters and color scanning with second preprocessing parameters.
[0027] In some embodiments, step S101 involves using multiple laser scanning strategies to perform laser color marking on the metal substrate surface and collecting color output data under different laser parameters. This includes: using multiple laser scanning strategies to perform laser color marking on the metal substrate surface and collecting color output data under different laser power and scanning speed conditions; the color of the color output data is represented by the luminance in the Lab color space. ), red and green ( ) and yellow and blue ( The three channels represent the data, forming a dataset containing multiple combined samples.
[0028] For example, Figure 2 This is a schematic diagram of the laser color processing experimental platform and scanning arrangement in an embodiment of the present invention, as shown below. Figure 2 As shown in Figure a, the sample undergoes pretreatment steps including mechanical polishing, ultrasonic cleaning, and oil-free blower drying, as well as high-density scanning performed on a fiber nanosecond laser processing platform. Figure 2 Figure b shows various stable color samples formed on the surface of stainless steel under different parameter conditions. Figure 2 c further demonstrates the micro-area scanning trajectory and arrangement pattern of each color group. This process possesses high repeatability and high-precision control capabilities, providing high-quality experimental samples for subsequent model training and ensuring the stability and reliability of the mapping relationship between the input laser parameters and the output color data.
[0029] In some embodiments, step S102, based on the laser scanning strategy, constructs a 7-dimensional feature vector corresponding to the laser parameters, including: converting the laser scanning strategy into a discrete feature vector through one-hot encoding; and constructing a 7-dimensional input feature vector by combining two continuous variables, laser power and scanning speed.
[0030] For example, Figure 3 This is a schematic diagram of five laser scanning strategies used in the embodiments of the present invention, namely single scanning, dual scanning, orthogonal scanning, color scanning with first preprocessing parameters and color scanning with second preprocessing parameters, and the specific parameters are shown in Table 1.
[0031] Table 1. Parameter illustrations for different laser scanning strategies
[0032] These strategies, by controlling the laser scanning direction, repetition path, and energy distribution, induce different surface morphologies under the same power and speed coloring conditions, thus significantly affecting the final color rendering effect. Embedding these scanning strategies into the model input in the form of one-hot encoding not only effectively expands the color space dimension but also provides the model with richer process semantic information, thereby significantly enhancing the model's learning ability and generalization performance. The parameters listed in Table 1 are examples or optional ranges of different scanning strategies; in specific implementation, parameters such as power, frequency, and scanning spacing can be adjusted according to the laser model and material batch.
[0033] In some embodiments, a multilayer perceptron neural network model is established based on the 7-dimensional feature vector, and a nonlinear mapping is performed on the laser parameters and color output data, including: constructing a multilayer perceptron neural network model containing at least three hidden layers based on the 7-dimensional feature vector; and performing a nonlinear mapping on the laser parameters and color output data using the ReLU activation function and batch normalization operation.
[0034] In this embodiment, the multilayer perceptron neural network model contains three hidden layers with 128, 64, and 32 neurons respectively, and the output is in color space. , and aisle, To improve fitting accuracy, a fully connected hidden layer containing 16 neurons is added to the channel.
[0035] Furthermore, the multilayer perceptron neural network model is trained using the Adam optimizer, including: setting the initial learning rate and the maximum number of training epochs for training the multilayer perceptron neural network model; employing an early stopping strategy to train the multilayer perceptron neural network model to avoid overfitting; and using a combination of the L1 function and the SmoothL1 function as the loss function during training.
[0036] In this embodiment, the initial learning rate is 0.0005, the maximum number of training epochs is 5000, and an early stopping strategy is used to avoid overfitting. The loss function is a combination of the L1 function and the Smooth L1 function, and the three-channel weighting ratio is... : : = 1:6:1.5.
[0037] Figure 4 This is a graph showing the variation of training and testing errors when the multilayer perceptron neural network model performs a color prediction task in an embodiment of the present invention. Figure 4 As shown, stable convergence was achieved within approximately 500 rounds, validating the effectiveness of the network structure design and training strategy. The multilayer perceptron neural network model employs a three-hidden-layer structure with 128, 64, and 32 neurons respectively, and introduces the ReLU activation function and batch normalization operation, effectively suppressing the gradient vanishing problem and improving the network's convergence speed and robustness.
[0038] Figure 5 This is a fitting graph of the prediction accuracy of the multilayer perceptron neural network model in this embodiment of the invention on the test dataset, where a is... A comparison chart of predicted and actual values for a channel; b represents... Comparison of prediction results for each channel; c represents... A comparison chart of prediction results for each channel. (For example...) Figure 5 As shown, the brightness channel Goodness of fit R 2 Up to 0.966, color channels and The values reached 0.853 and 0.948 respectively, both demonstrating good linear correlation. This indicates that the multilayer perceptron neural network model can accurately capture the nonlinear response of input parameters to color output, achieving significant improvements in accuracy and robustness compared to traditional linear regression and shallow neural network methods.
[0039] Figure 6 In this embodiment of the invention, the prediction error and color difference statistics of the multilayer perceptron neural network model on the validation dataset are shown in the figure, where ac represents... , , The prediction error comparison chart for each channel shows... , , The difference between the predicted and actual measured values; d is the minimum color error of each validation sample. (Indicating CIE Lab color difference) Overall color difference comparison chart. For example... Figure 6As shown, the industrial adaptability of the multilayer perceptron neural network model was evaluated from an error perspective. The mean absolute error (MAE) of all three color channels remained below 3. Figure 6 d The color difference diagram shows that the overall color difference in most test samples is below 7, which meets the industrial visual color difference tolerance threshold. This means that the multilayer perceptron neural network model constructed by this method has achieved an industrial-grade level of accuracy and can provide fast and reliable color pre-evaluation capabilities for laser-colored products.
[0040] Based on the above embodiments, step S104, which involves forward prediction using a multilayer perceptron neural network model, includes: inputting the laser parameters of the processing process into the multilayer perceptron neural network model and predicting the target color value obtained based on the current laser parameters.
[0041] The reverse design is performed using a multilayer perceptron neural network model, which includes: feeding the multilayer perceptron neural network model with the target color value as the optimization target / constraint; with the parameters of the trained model fixed, performing gradient iteration on the laser power and scanning speed to obtain the target laser parameters that minimize the color error; when the color error meets a preset threshold, the design is considered valid. The preset threshold can be set according to the application scenario (generally, the Euclidean distance is 7).
[0042] Figure 7 These are laser-processed surface microstructure images under different scanning strategies in the embodiments of the present invention. Among them, a1-g1 are macroscopic images from a super depth-of-field microscope, showing the microscopic color and structural morphology of the corresponding surfaces under single scan, double scan, orthogonal scan, first preprocessing parameter color scan, and second preprocessing parameter color scan; a2-g2 are scanning electron microscope (SEM) microscopic images of the corresponding areas.
[0043] As can be observed from the ultra-depth-of-field images (a1-g1) and SEM images (a2-g2), different scanning strategies directly affect the morphology, distribution density, and size of the surface microstructure. These factors further couple and influence the color interference formation mechanism and visual presentation effect. These particles are mainly formed during the laser-material interaction process, where local heating, vaporization, and ionization of the material surface generate high-pressure plasma expansion, which is then deposited through material ablation and plasma jetting. Through detailed experimental analysis, it is believed that the generation of this micro-protrusion structure is the result of the combined effect of recoil pressure and Marangoni flow during the laser-material interaction process. By reasonably controlling the laser energy density and the number of laser pulses (by changing the laser scanning rate), precise control of the laser-induced surface structure can be achieved. The experimental results verify the dominant role of the laser scanning strategy in the control of micro-nano structures and indirectly prove the rationality of introducing the "scanning strategy" as a discrete input variable in this invention. In particular, in the multilayer perceptron neural network model, the process parameters and structural strategies are co-encoded into the input, which effectively improves the color prediction accuracy and also enables the model to have a certain degree of structural perception capability, thereby supporting the parameter tracing of the target color in reverse design tasks.
[0044] The above method will now be described with specific examples: Example 1: 1. Cut the 304 stainless steel substrate into 10 mm × 10 mm square samples. Clean them sequentially with acetone, anhydrous ethanol, and deionized water using ultrasonic cleaning, each solution lasting 5 minutes, to remove surface oil and particulate matter. Then, dry the samples using an oil-free hairdryer to prevent secondary dust contamination.
[0045] 2. The sample was fixed on the laser processing platform and scanned using a nanosecond fiber laser with a wavelength of 1064 nm, a pulse width of 20 ns, a frequency of 30 kHz, an average power of 12 W, a scanning rate of 100 mm / s, a scanning spacing of 10 µm, and a scanning area of 5 mm × 7 mm. A single-scan strategy was used to construct the color sample.
[0046] 3. Use a spectrophotometer to measure the color parameters of this area. , , The input parameters include at least laser power, scanning speed and scanning strategy, and may further include process parameters such as pulse frequency, scanning spacing and pulse width.
[0047] 4. The above sample data was input into a multilayer perceptron neural network model for training and testing. A multilayer perceptron neural network structure with three hidden layers was used for training, with Adam as the optimizer and an early stopping strategy employed. The loss function was a combination of the L1 function and the Smooth L1 function. The model training results show that... channel R 2 It is 0.966. The channel value is 0.853. The number of channels is 0.948, all of which show good fitting results.
[0048] Example 2: 1. Cut the 304 stainless steel substrate into 15 mm × 15 mm pieces, use the same solvent system for ultrasonic cleaning, extend the time to 8 minutes per step to enhance the ability to remove surface contaminants, and then blow dry for later use.
[0049] 2. Laser parameters were adjusted as follows: pulse width 20 ns, wavelength 1064 nm, frequency 40 kHz, average power 15W, scanning speed 150 mm / s, and scanning spacing 10 µm. The scanning strategy adopted an "orthogonal scanning" mode, that is, the second scanning path is perpendicular to the first scanning path.
[0050] 3. Perform color detection on the processed samples and record the values for each channel, then use them for model training. This sample set is used to evaluate the model's prediction accuracy under complex paths.
[0051] 4. Test set validation results show that R 2 Value at , , The channels have values of 0.94, 0.93, and 0.84 respectively, representing the maximum color difference. A value below 7 indicates that the model prediction error is within the industrial color difference tolerance range.
[0052] Example 3: 1. Cut the 304 stainless steel sample into 20 mm × 20 mm pieces, and clean it in the same way as in Example 1.
[0053] 2. The laser parameters are: pulse width 20 ns, wavelength 1064 nm, frequency 50 kHz, power 18 W, scanning speed 80 mm / s, scanning spacing 20 µm, and "second preprocessing parameter coloring scan" is adopted. This strategy integrates variable spacing, multi-level overlap and special path design.
[0054] 3. The microstructure of the sample surface was characterized using an image acquisition system and SEM. A regular, periodic array of microstructures was formed on the sample surface, exhibiting excellent optical interference effects and color stability, providing structural basis for model prediction.
[0055] 4. The target color value is input back into the trained multilayer perceptron neural network model, which outputs a set of corresponding laser processing parameters. Laser processing is then performed on the new sample according to these parameters, and the measured color matches the target color. The result was below 7, which verifies the accuracy and practicality of this method in reverse engineering.
[0056] This invention provides a laser processing color parameter prediction and reverse design device. The laser processing color parameter prediction and reverse design device provided by this invention is described below. The laser processing color parameter prediction and reverse design device described below can be referred to in correspondence with the laser processing color parameter prediction and reverse design method described above. Figure 8 This is a structural block diagram of the laser processing color parameter prediction and reverse design device provided by the present invention, as shown below. Figure 8 As shown, the device includes: The acquisition module 801 is used to perform laser color marking on the surface of a metal substrate using various laser scanning strategies and to acquire color output data under different laser parameters. The processing module 802 is used to construct a 7-dimensional feature vector corresponding to the laser parameters based on the laser scanning strategy; Module 803 is used to build a multilayer perceptron neural network model based on the 7-dimensional feature vector and to perform nonlinear mapping between laser parameters and color output data; The execution module 804 is used to perform forward prediction or backward design through a multilayer perceptron neural network model to obtain the target color value or target laser parameters.
[0057] In operation, this device first employs various laser scanning strategies to conduct laser color marking experiments on a metal substrate, acquiring color output data under different laser parameter conditions. Then, the processing module 802 constructs a 7-dimensional feature vector corresponding to the laser parameters based on the laser scanning strategies. Next, the construction module 803 establishes a multilayer perceptron neural network model based on these 7-dimensional feature vectors, realizing a nonlinear mapping relationship between laser parameters and color output data. Finally, the execution module 804 performs forward prediction or backward design using the multilayer perceptron neural network model to obtain the target color value or target laser parameters. Through this process, rapid color prediction and accurate backward design are achieved, significantly improving the consistency and intelligence level of laser color marking, reducing parameter trial-and-error time, increasing processing efficiency and color stability, and solving the problems of poor laser color processing accuracy and scalability in existing related technologies.
[0058] Figure 9 An example is a schematic diagram of the physical structure of an electronic device, such as... Figure 9As shown, the electronic device may include: a processor 901, a communication interface 902, a memory 903, and a communication bus 904. The processor 901, communication interface 902, and memory 903 communicate with each other via the communication bus 904. The processor 901 can call logical instructions from the memory 903 to execute a laser processing color parameter prediction and reverse engineering method. This method includes: Laser color marking was performed on a metal substrate using various laser scanning strategies, and color output data under different laser parameters were collected. Based on the laser scanning strategy, a 7-dimensional feature vector corresponding to the laser parameters is constructed. Based on the 7-dimensional feature vector, a multilayer perceptron neural network model is established, and nonlinear mapping is performed on the laser parameters and color output data; The target color value or target laser parameters are obtained by forward prediction or backward design using a multilayer perceptron neural network model.
[0059] Furthermore, the logical instructions in the aforementioned memory 903 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0060] On the other hand, the present invention also provides a computer program product, which includes a computer program that can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer is able to execute the laser processing color parameter prediction and reverse design method provided by the above methods, the method including: Laser color marking was performed on a metal substrate using various laser scanning strategies, and color output data under different laser parameters were collected. Based on the laser scanning strategy, a 7-dimensional feature vector corresponding to the laser parameters is constructed. Based on the 7-dimensional feature vector, a multilayer perceptron neural network model is established, and nonlinear mapping is performed on the laser parameters and color output data; The target color value or target laser parameters are obtained by forward prediction or backward design using a multilayer perceptron neural network model.
[0061] In another aspect, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the laser processing color parameter prediction and reverse design method provided by the above methods, the method comprising: Laser color marking was performed on a metal substrate using various laser scanning strategies, and color output data under different laser parameters were collected. Based on the laser scanning strategy, a 7-dimensional feature vector corresponding to the laser parameters is constructed. Based on the 7-dimensional feature vector, a multilayer perceptron neural network model is established, and nonlinear mapping is performed on the laser parameters and color output data; The target color value or target laser parameters are obtained by forward prediction or backward design using a multilayer perceptron neural network model.
[0062] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.
[0063] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.
[0064] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for predicting and reverse-engineering color parameters in laser processing, characterized in that, include: Laser color marking was performed on a metal substrate using various laser scanning strategies, and color output data under different laser parameters were collected. Based on the laser scanning strategy, a 7-dimensional feature vector corresponding to the laser parameters is constructed; Based on the 7-dimensional feature vector, a multilayer perceptron neural network model is established, and a nonlinear mapping is performed between the laser parameters and the color output data; The target color value or target laser parameters are obtained by forward prediction or backward design using the multilayer perceptron neural network model.
2. The laser processing color parameter prediction and reverse design method according to claim 1, characterized in that, The laser scanning strategy includes single scanning, dual scanning, orthogonal scanning, color scanning with first preprocessing parameters and color scanning with second preprocessing parameters.
3. The laser processing color parameter prediction and reverse design method according to claim 1, characterized in that, Laser color marking was performed on a metal substrate surface using various laser scanning strategies, and color output data under different laser parameters were collected, including: Laser color marking was performed on a metal substrate using various laser scanning strategies, and color output data was collected under different laser power and scanning speed conditions. The colors in the output color data are represented using the three channels of lightness, red-green, and yellow-blue in the Lab color space, forming a dataset containing multiple combined samples.
4. The laser processing color parameter prediction and reverse design method according to claim 3, characterized in that, Based on the laser scanning strategy, a 7-dimensional feature vector corresponding to the laser parameters is constructed, including: The laser scanning strategy is encoded as a 5-dimensional one-heat vector and concatenated with two continuous variables, laser power and scanning speed, to construct a 7-dimensional input feature vector.
5. The laser processing color parameter prediction and reverse design method according to claim 1, characterized in that, Based on the 7-dimensional feature vector, a multilayer perceptron neural network model is established, and a nonlinear mapping is performed between the laser parameters and the color output data, including: Based on the 7-dimensional feature vectors, a multilayer perceptron neural network model containing at least three hidden layers is constructed. The laser parameters and the color output data are nonlinearly mapped using the ReLU activation function and batch normalization operation.
6. The laser processing color parameter prediction and reverse design method according to claim 1, characterized in that, The multilayer perceptron neural network model is trained using the Adam optimizer, including: Set the initial learning rate and maximum number of training epochs for training the multilayer perceptron neural network model; An early stopping strategy is used to train the multilayer perceptron neural network model to avoid overfitting; The loss function during training is a combination of the L1 function and the Smooth L1 function.
7. The laser processing color parameter prediction and reverse design method according to claim 1, characterized in that, Forward prediction using the multilayer perceptron neural network model includes: The laser parameters of the processing procedure are input into the multilayer perceptron neural network model to predict the target color value obtained based on the current laser parameters.
8. The laser processing color parameter prediction and reverse design method according to claim 1, characterized in that, Reverse engineering using the aforementioned multilayer perceptron neural network model includes: Using the target color value as the optimization objective / constraint, the multilayer perceptron neural network model is fed with fixed parameters. Gradient iteration is performed on the laser power and scanning speed to obtain the target laser parameters that minimize the color error.
9. A device for predicting and reverse-engineering color parameters in laser processing, characterized in that, include: The acquisition module is used to perform laser color marking on the surface of a metal substrate using various laser scanning strategies and to acquire color output data under different laser parameters. The processing module is used to construct a 7-dimensional feature vector corresponding to the laser parameters based on the laser scanning strategy. The construction module is used to establish a multilayer perceptron neural network model based on the 7-dimensional feature vector, and to perform nonlinear mapping between the laser parameters and the color output data; The execution module is used to perform forward prediction or backward design through the multilayer perceptron neural network model to obtain the target color value or target laser parameters.
10. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the laser processing color parameter prediction and reverse design method as described in any one of claims 1 to 8.