Data processing method and device, equipment and medium

By optimizing the learning rate through the calculation of first and second derivative information and iteratively updating the neural network model parameters using the gradient update function, the problem of local optima in neural network model training is solved, thereby improving the model's generalization ability and processing efficiency.

CN121767692APending Publication Date: 2026-03-31SHANDONG YUNHAI GUOCHUANG CLOUD COMPUTING EQUIP IND INNOVATION CENT CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-29
Publication Date
2026-03-31

AI Technical Summary

Technical Problem

In existing technologies, improper selection of the learning rate of neural network models can easily lead to local optima during training, failing to achieve optimal performance and affecting the accuracy and efficiency of image data processing.

Method used

By calculating the first and second derivative information, the learning rate is adaptively optimized, and the parameters of the neural network model are iteratively updated in combination with the gradient update function. The target model parameters are set to overcome local optima and improve the generalization ability of the model.

Benefits of technology

It effectively overcomes the local optimum dilemma in the learning rate optimization process, improves the verification logic and generalization ability of neural network models, and enhances the accuracy and efficiency of image data processing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121767692A_ABST
    Figure CN121767692A_ABST
Patent Text Reader

Abstract

The invention discloses a data processing method and device, equipment and a medium, and belongs to the technical field of data processing.The method comprises the steps that a neural network model is created according to an image data set, and a cost function is determined according to the neural network model; calculating a target learning rate according to the cost function; calculating model parameters of the neural network model; determining a gradient updating function according to the target learning rate and model parameters of the neural network model; performing iterative updating on model parameters of the neural network model through the gradient updating function; determining a target neural network model according to the target model parameters of the neural network model when the number of times of iterative updating of the model parameters of the neural network model reaches a first threshold value; and processing image data through the target neural network model. According to the method, local optimum embarrassment in the learning rate optimization process can be overcome, the verification logic of the neural network model is improved, and the method has certain generalization ability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of data processing technology, and in particular to a data processing method, apparatus, device and medium. Background Technology

[0002] Currently, neural network models are widely used in image data processing. In particular, convolutional neural networks (CNNs) have become an indispensable tool in tasks such as image classification, object detection, and face recognition, achieving remarkable results. Through neural network models, feature extraction, pattern recognition, and semantic understanding of images can be achieved, thus enabling automated image recognition and analysis. Therefore, optimizing and training neural networks is a crucial task that plays a decisive role in their performance.

[0003] The adjustment of the learning rate is crucial for training neural networks. An excessively large learning rate may cause the model to skip the optimal solution during training, preventing it from converging to its best performance. In this case, the model's training results may oscillate around extreme points, failing to achieve the desired accuracy and thus reducing the precision of image data processing. Conversely, an excessively small learning rate, while allowing the model to gradually approach the optimal solution, will make the training process extremely slow, and may even cause the model to stagnate at local optima, failing to reach global optimal performance and thus reducing the efficiency of image data processing. Furthermore, the choice of learning rate is closely related to the model's generalization ability; it may lead to overfitting or underfitting the data, resulting in decreased generalization ability and inaccurate image data processing. Summary of the Invention

[0004] To overcome the aforementioned technical deficiencies, the purpose of this application is to provide a data processing method, apparatus, device, and medium. The method includes: acquiring an image dataset; creating a neural network model based on the image dataset; determining a cost function based on the neural network model; calculating first-order derivative information and second-order derivative information based on the cost function; calculating a target learning rate based on the first-order derivative information and second-order derivative information; calculating model parameters of the neural network model based on the first-order derivative information and second-order derivative information; determining a gradient update function based on the target learning rate and the model parameters of the neural network model; iteratively updating the model parameters of the neural network model using the gradient update function; in response to the number of iterations of the model parameters of the neural network model reaching a first threshold, setting the neural network model parameters corresponding to the number of iterations reaching the first threshold as target model parameters of the neural network model; determining a target cost function based on the target model parameters of the neural network model; determining a target neural network model based on the target cost function; and processing image data using the target neural network model. This application can overcome the local optimum dilemma in the learning rate optimization process, improve the verification logic of the neural network model, and has a certain generalization ability.

[0005] The specific technical solutions provided in this application are as follows:

[0006] In a first aspect, this application provides a data processing method, the method comprising:

[0007] Obtain the image dataset;

[0008] A neural network model is created based on the image dataset, and a cost function is determined based on the neural network model.

[0009] The first-order derivative information and the second-order derivative information are determined based on the cost function, and the target learning rate is determined based on the first-order derivative information and the second-order derivative information.

[0010] The model parameters of the neural network model are determined based on the first-order derivative information and the second-order derivative information.

[0011] The gradient update function is determined based on the target learning rate and the model parameters of the neural network model;

[0012] The model parameters of the neural network model are iteratively updated using the gradient update function;

[0013] In response to the neural network model's model parameter iteration update count reaching a first threshold, the neural network model parameters corresponding to the first threshold's model parameter iteration update count are set as the neural network model target model parameters.

[0014] The target cost function is determined based on the target model parameters of the neural network model, and the target neural network model is determined based on the target cost function;

[0015] The image data is processed using the target neural network model.

[0016] In one embodiment, determining the cost function based on the neural network model includes:

[0017] Obtain historical image data x, and the weights w of each neuron in the neural network model;

[0018] Obtain the predicted value h based on historical image data and the weights of each neuron. w (x), the true value y corresponding to the historical image data;

[0019] Obtain the regularization coefficient μ, the number of historical image data S, and the weight w of the i-th neuron. i ;

[0020] Through formula Calculate the cost function J(w), where, This is a regularization term.

[0021] In one embodiment, determining the first derivative information and the second derivative information based on the cost function, and determining the target learning rate based on the first derivative information and the second derivative information, includes:

[0022] Obtain the cost function J(w), and the weights w of each neuron in the neural network model;

[0023] Through formula Calculate the first derivative information α;

[0024] Through formula Calculate the second derivative information β;

[0025] Obtain the exponential decay rate p and the first derivative α at the current time. n The first derivative information α relative to the current time and the previous time. n-1 The number of iterations is n, where p is a positive number less than 1;

[0026] Through formula Calculate the current first learning rate l n ;

[0027] Obtain the aggravation coefficient c and the second derivative information β at the current time. n , where the value of c conforms to the uniform distribution function U(0,1);

[0028] Through formula r n=r (n-1) -cr (n-1) β n Calculate the current second learning rate r n , where r (n-1) The second learning rate is relative to the previous time step;

[0029] Through formula λ n =max(l n ,r n Determine the target learning rate λ. n .

[0030] In one embodiment, determining the model parameters of the neural network model based on the first-order derivative information and the second-order derivative information includes:

[0031] Obtaining first-order momentum information and calculating equations The first derivative information α of the previous time relative to the current time. n-1 ;

[0032] Through formula Calculate the current first-order momentum information m n ;

[0033] Calculation equation for obtaining second-order momentum information The second derivative information β relative to the current time point of the previous time point n-1 ;

[0034] Through formula Calculate the current second-order momentum information v n ;

[0035] Wherein, the first-order momentum information m and the second-order momentum information v are the model parameters of the neural network model.

[0036] In one embodiment, determining the gradient update function based on the target learning rate and the model parameters of the neural network model includes:

[0037] Obtain the target learning rate λ n Current first-order momentum information m n The current second-order momentum information v n ;

[0038] Obtain the regularization coefficient μ, and the number of historical image data S;

[0039] Obtain the weights w of each neuron in the neural network model. n In a neural network model, the weights w of each neuron relative to the previous time step are... n-1 ;

[0040] Through formula Determine the gradient update function.

[0041] In one embodiment, determining the target cost function based on the target model parameters of the neural network model includes:

[0042] When the number of iterations of the model parameters of the neural network model is the first threshold, the model parameters of the neural network model are m. m v m ;

[0043] Through formula Inversely determine the first derivative information α' of the target;

[0044] Through formula Inversely determine the target's second derivative information β';

[0045] Through formula The objective cost function J(w)' is determined in reverse.

[0046] In one embodiment, the processing of image data through the target neural network model includes:

[0047] The image data is converted into the format corresponding to the target neural network model. The conversion process includes adjusting the image size, normalizing pixel values, and rotating and translating to increase the robustness of the model.

[0048] The target neural network model is determined according to the task requirements, wherein the target neural network model includes a convolutional neural network;

[0049] The target neural network model is configured with convolutional layers, pooling layers, and fully connected layers, wherein the convolutional layers are used to extract image features, the pooling layers are used to reduce spatial dimensions, and the fully connected layers are used for decision-making in classification tasks.

[0050] The target neural network model is trained;

[0051] Training the target neural network model includes:

[0052] Determine the target loss function of the target neural network model based on the image data processing task type;

[0053] An optimization algorithm for updating the target neural network model, wherein the optimization algorithm includes a stochastic gradient descent algorithm;

[0054] The target neural network model is trained using a training dataset, and the target loss function is adjusted by adjusting the network weights through backpropagation.

[0055] The target neural network model is improved by adjusting the form of parameters, wherein the parameters include learning rate, batch size, number of layers, and number of nodes;

[0056] The performance of the target neural network model was verified using a test dataset;

[0057] The target neural network model is trained to predict or classify image data after format conversion.

[0058] After predicting or classifying the converted image data using the trained target neural network model, the process includes:

[0059] The target neural network model is optimized using model compression and quantization techniques.

[0060] Secondly, this application also provides a data processing apparatus, the apparatus comprising:

[0061] The acquisition module is used to acquire image datasets;

[0062] The first determining module is used to create a neural network model based on the image dataset, determine a cost function based on the neural network model, and determine a gradient update function based on the target learning rate and the model parameters of the neural network model.

[0063] The calculation module is used to determine the first-order derivative information and the second-order derivative information according to the cost function, determine the target learning rate according to the first-order derivative information and the second-order derivative information, and determine the model parameters of the neural network model according to the first-order derivative information and the second-order derivative information.

[0064] The update module is used to iteratively update the model parameters of the neural network model through the gradient update function;

[0065] The setting module is used to set the neural network model parameters corresponding to the number of iterations of the neural network model parameters reaching the first threshold as the target model parameters of the neural network model in response to the number of iterations of the neural network model parameters reaching the first threshold.

[0066] The second determining module is used to determine a target cost function based on the target model parameters of the neural network model, and to determine a target neural network model based on the target cost function;

[0067] The processing module is used to process image data through the target neural network model.

[0068] Thirdly, a data processing apparatus is also provided, comprising:

[0069] One or more processors;

[0070] Storage device for storing one or more programs;

[0071] When the one or more programs are executed by the one or more processors, the one or more processors implement the data processing method as described in any of the first aspects.

[0072] Fourthly, this application also provides a computer device, the device comprising:

[0073] A memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of the data processing method as described in any of the first aspects.

[0074] Fifthly, this application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the data processing method described in any of the first aspects.

[0075] Sixthly, this application also provides a computer storage medium, the medium comprising:

[0076] It stores a computer program that, when executed by a processor, implements the steps of any of the data processing methods described in the first aspect.

[0077] Compared with existing technologies, the method of the technical solution provided in this application includes: acquiring an image dataset; creating a neural network model based on the image dataset, and determining a cost function based on the neural network model; calculating first-order derivative information and second-order derivative information based on the cost function, and calculating a target learning rate based on the first-order derivative information and second-order derivative information; calculating model parameters of the neural network model based on the first-order derivative information and second-order derivative information; determining a gradient update function based on the target learning rate and the model parameters of the neural network model; iteratively updating the model parameters of the neural network model through the gradient update function; in response to the number of iterations of the model parameters of the neural network model reaching a first threshold, setting the neural network model parameters corresponding to the number of iterations of the model parameters of the neural network model reaching the first threshold as the target model parameters of the neural network model; determining a target cost function based on the target model parameters of the neural network model, and determining a target neural network model based on the target cost function; and processing image data through the target neural network model. This application, based on a hybrid learning rate optimization design pattern, can overcome the local optimum dilemma in the learning rate optimization process, improve the verification logic of the neural network model, and has a certain generalization ability.

[0078] The technical solution provided in this application embodiment is based on the first-order derivative information and second-order derivative information of the optimized position, and coordinates the learning rate in the entire design process to adaptively optimize the neural network function, improve the optimization efficiency of the neural network, and overcome local optima.

[0079] The technical solution provided in this application proposes a learning rate alternation optimization method based on gradient change. In the optimization process of the neural network, the neural network parameters are adaptively and quickly updated and optimized, and a certain optimization insurance function and generalization ability are provided, resulting in better application effect. Attached Figure Description

[0080] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0081] Figure 1 A flowchart of the data processing method provided in Embodiment 1 of this application;

[0082] Figure 2 This is a structural diagram of the data processing apparatus provided in Embodiment 3 of this application;

[0083] Figure 3 This is an exemplary system provided for Embodiment Seven of this application, which can be used to implement the various embodiments described in this application. Detailed Implementation

[0084] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0085] It should be noted that, unless the context explicitly requires it, the words "comprising," "including," and similar terms in the entire specification and claims should be interpreted as encompassing rather than being exclusive or exhaustive; that is, meaning "including but not limited to."

[0086] Furthermore, in the description of this application, unless otherwise stated, "a plurality of" means two or more.

[0087] Example 1

[0088] This application provides a data processing method, such as... Figure 1 As shown, the method includes:

[0089] Obtain the image dataset;

[0090] A neural network model is created based on the image dataset, and a cost function is determined based on the neural network model.

[0091] The first-order derivative information and the second-order derivative information are calculated based on the cost function, and the target learning rate is calculated based on the first-order derivative information and the second-order derivative information.

[0092] The model parameters of the neural network model are calculated based on the first-order derivative information and the second-order derivative information.

[0093] The gradient update function is determined based on the target learning rate and the model parameters of the neural network model;

[0094] The model parameters of the neural network model are iteratively updated using the gradient update function;

[0095] In response to the neural network model's model parameter iteration update count reaching a first threshold, the neural network model parameters corresponding to the first threshold's model parameter iteration update count are set as the neural network model target model parameters.

[0096] The target cost function is determined based on the target model parameters of the neural network model, and the target neural network model is determined based on the target cost function;

[0097] The image data is processed using the target neural network model.

[0098] Specifically, this application proposes a gradient-based learning rate alternation optimization method, which adaptively and rapidly updates the neural network parameters during the optimization process, and provides certain optimization insurance functions and generalization capabilities, resulting in better application performance.

[0099] The technical solution of this application is mainly based on the first-order derivative information and second-order derivative information of the optimization position, and coordinates the learning rate in the entire process of design to adaptively optimize the neural network function and improve the optimization efficiency of the neural network. The proposed learning rate alternation optimization method, based on a hybrid learning rate optimization design mode, overcomes the local optimum dilemma in the optimization process to a certain extent and improves the verification logic of the neural network model.

[0100] First-order optimization algorithms use the gradient values ​​of each parameter to minimize or maximize the loss function. When calculating the derivative of a multivariable function, the gradient is used instead of the derivative, and partial derivatives are used to calculate the gradient. A key difference between the gradient and the derivative is that the gradient of a function forms a vector field.

[0101] Second-order optimization algorithms use the second derivative to minimize or maximize the loss function, such as Newton's method;

[0102] This application is based on the Adam (Adaptive Moment Estimation) algorithm. The Adam algorithm is a gradient descent algorithm used to optimize neural network models. It combines the characteristics of momentum method and adaptive learning rate and is widely used in the field of deep learning. The core idea of ​​the algorithm is to dynamically adjust the learning rate of each parameter so that it can adapt to the gradient of different parameters and maintain two exponentially weighted moving average estimates, namely the first moment estimate and the second moment estimate.

[0103] The first-order moment estimate represents the average value of the gradient, while the second-order moment estimate represents the variance of the gradient.

[0104] The Adam algorithm can adaptively adjust the learning rate based on the gradient of each parameter, thereby improving the optimization effect. By maintaining the first-order moment estimate and the second-order moment estimate, the Adam algorithm can converge to the local optimum more quickly.

[0105] The Adam algorithm is well-adapted to different parameters and can handle various types of neural network models and data. However, in some cases, the Adam algorithm may suffer from excessively large or small learning rates, requiring parameter tuning and experimentation. Furthermore, the Adam algorithm lacks a clear learning rate decay strategy, necessitating adjustments based on the specific problem.

[0106] The beneficial effects of the technical solutions provided in this application are:

[0107] This application is based on a hybrid learning rate optimization design pattern, which can overcome the local optimum dilemma in the learning rate optimization process, improve the verification logic of the neural network model, and has a certain generalization ability.

[0108] The technical solution provided in this application embodiment is based on the first-order derivative information and second-order derivative information of the optimized position, and coordinates the learning rate in the entire design process to adaptively optimize the neural network function, improve the optimization efficiency of the neural network, and overcome local optima.

[0109] The technical solution provided in this application proposes a learning rate alternation optimization method based on gradient change. In the optimization process of the neural network, the neural network parameters are adaptively and quickly updated and optimized, and a certain optimization insurance function and generalization ability are provided, resulting in better application effect.

[0110] Example 2

[0111] This application provides a data processing method, such as... Figure 1 As shown, the method includes:

[0112] Step S01: Obtain the image dataset;

[0113] A neural network model is created based on the image dataset, and a cost function is determined based on the neural network model.

[0114] Step S01 also includes:

[0115] Step S011: Obtain historical image data x and the weights w of each neuron in the neural network model;

[0116] Obtain the predicted value h based on historical image data and the weights of each neuron. w (x), the true value y corresponding to the historical image data;

[0117] Obtain the regularization coefficient μ, the number of historical image data S, and the weight w of the i-th neuron. i ;

[0118] Through formula Calculate the cost function J(w), where, This is a regularization term.

[0119] Step S02: Calculate the first-order derivative information and the second-order derivative information based on the cost function, and calculate the target learning rate based on the first-order derivative information and the second-order derivative information.

[0120] Step S02 also includes:

[0121] Step S021: Obtain the cost function J(w) and the weights w of each neuron in the neural network model;

[0122] Through formula Calculate the first derivative information α;

[0123] Through formula Calculate the second derivative information β;

[0124] Obtain the exponential decay rate p and the first derivative α at the current time. n The first derivative information α relative to the current time and the previous time. n-1 The number of iterations is n, where p is a positive number less than 1;

[0125] Through formula Calculate the current first learning rate l n ;

[0126] Obtain the aggravation coefficient c and the second derivative information β at the current time. n , where the value of c conforms to the uniform distribution function U(0,1);

[0127] Through formula rn =r (n-1) -cr (n-1) β n Calculate the current second learning rate r n , where r (n-1) The second learning rate is relative to the previous time step;

[0128] Through formula λ n =max(l n ,r n Determine the target learning rate λ. n .

[0129] Here, through the formula Calculate the current second learning rate r n ;

[0130] When calculating the first derivative information, p can be 0.9; when calculating the second derivative information, p can be 0.999.

[0131] Current second derivative information β n The second derivative information β relative to the current time point of the previous time point n-1 ;

[0132] The value of c conforms to the uniform distribution function U(0,1), and its value is between (0,1).

[0133] Step S03: Calculate the model parameters of the neural network model based on the first-order derivative information and the second-order derivative information.

[0134] Step S03 also includes:

[0135] Step S031: Obtain first-order momentum information and calculate the equation. The first derivative information α of the previous time relative to the current time. n-1 ;

[0136] Through formula Calculate the current first-order momentum information m n ;

[0137] Calculation equation for obtaining second-order momentum information The second derivative information β relative to the current time point of the previous time point n-1 ;

[0138] Through formula Calculate the current second-order momentum information v n ;

[0139] Wherein, the first-order momentum information m and the second-order momentum information v are the model parameters of the neural network model.

[0140] Step S04: Determine the gradient update function based on the target learning rate and the model parameters of the neural network model.

[0141] Step S04 also includes:

[0142] Step S041, obtain the target learning rate λ n Current first-order momentum information m n The current second-order momentum information v n ;

[0143] Obtain the regularization coefficient μ, and the number of historical image data S;

[0144] Obtain the weights w of each neuron in the neural network model. n In a neural network model, the weights w of each neuron relative to the previous time step are... n-1 ;

[0145] Through formula Determine the gradient update function.

[0146] Step S05: Iteratively update the model parameters of the neural network model using the gradient update function;

[0147] In response to the neural network model's model parameter iteration update count reaching a first threshold, the neural network model parameters corresponding to the first threshold's model parameter iteration update count are set as the neural network model target model parameters.

[0148] The target cost function is determined based on the target model parameters of the neural network model, and the target neural network model is determined based on the target cost function.

[0149] Specifically, the neural network model parameters are iteratively updated through the gradient update function. If the model parameters meet a preset condition, the model parameters that meet the preset condition are used as the final model parameters of the neural network model.

[0150] Preset condition: Determine whether the number of iterations for updating the model parameters of the neural network model has reached a first threshold (preset number of iterations, such as ten to hundreds of times);

[0151] If the first threshold is reached, the neural network model achieves the expected performance, and training ends early.

[0152] Finally, the target image data is processed using the neural network model whose model parameters have been iterated and updated a first threshold number of times.

[0153] Step S05 also includes:

[0154] Step S051: When the number of iterations of the model parameters of the neural network model is the first threshold, the model parameters of the neural network model are m. m v m ;

[0155] Through formula Inversely determine the first derivative information α' of the target;

[0156] Through formula Inversely determine the target's second derivative information β';

[0157] Through formula The objective cost function J(w)' is determined in reverse.

[0158] Step S06: Process the image data using the target neural network model.

[0159] Step S06 also includes:

[0160] Step S061: Convert the image data into the format corresponding to the target neural network model. The conversion process includes adjusting the image size, normalizing pixel values, and rotating and translating to increase the robustness of the model.

[0161] The target neural network model is determined according to the task requirements, wherein the target neural network model includes a convolutional neural network;

[0162] The target neural network model is configured with convolutional layers, pooling layers, and fully connected layers, wherein the convolutional layers are used to extract image features, the pooling layers are used to reduce spatial dimensions, and the fully connected layers are used for decision-making in classification tasks.

[0163] The target neural network model is trained;

[0164] Training the target neural network model includes:

[0165] Determine the target loss function of the target neural network model based on the image data processing task type;

[0166] An optimization algorithm for updating the target neural network model, wherein the optimization algorithm includes a stochastic gradient descent algorithm;

[0167] The target neural network model is trained using a training dataset, and the target loss function is adjusted by adjusting the network weights through backpropagation.

[0168] The target neural network model is improved by adjusting the form of parameters, wherein the parameters include learning rate, batch size, number of layers, and number of nodes;

[0169] The performance of the target neural network model was verified using a test dataset;

[0170] The target neural network model is trained to predict or classify image data after format conversion.

[0171] After predicting or classifying the converted image data using the trained target neural network model, the process includes:

[0172] The target neural network model is optimized using model compression and quantization techniques.

[0173] Specifically, collect image data relevant to the task; this data can be obtained from publicly available datasets or collected independently.

[0174] Converting images into a format suitable for input into neural networks typically involves resizing, normalizing pixel values ​​(e.g., scaling pixel values ​​to between 0 and 1), and augmenting (e.g., rotation, translation) to increase the model's robustness.

[0175] Choose the appropriate neural network architecture based on the task requirements; for example, Convolutional Neural Network (CNN);

[0176] The model defines convolutional layers, pooling layers, fully connected layers, etc.; convolutional layers are used to extract image features, pooling layers are used to reduce spatial dimensions, and fully connected layers are used for decision-making in classification tasks.

[0177] Choose an appropriate loss function based on the task type (classification, regression, etc.);

[0178] Choose an optimization algorithm for updating the weights, such as stochastic gradient descent (SGD), Adam, etc.

[0179] The neural network model is trained using the training dataset, and the loss function is minimized by adjusting the network weights through backpropagation. After each epoch, the performance of the neural network model is evaluated on the validation set to prevent overfitting.

[0180] Adjust hyperparameters such as learning rate, batch size, number of layers, and number of nodes to improve the performance of neural network models;

[0181] Use a test set to evaluate the final performance of the model and ensure that the neural network model has good generalization ability;

[0182] Apply a trained neural network model to new data to perform tasks such as data prediction or classification.

[0183] Deploying a trained neural network model to a production environment requires considering techniques such as model compression and quantization to improve efficiency.

[0184] Commonly used deep learning frameworks include TensorFlow, PyTorch, and Keras, which provide the tools and APIs needed to build and train neural networks.

[0185] This application acquires an image dataset; creates a neural network model based on the image dataset, and determines a cost function based on the neural network model; calculates first-order and second-order derivative information based on the cost function, and calculates a target learning rate based on the first-order and second-order derivative information; calculates model parameters of the neural network model based on the first-order and second-order derivative information; determines a gradient update function based on the target learning rate and the model parameters of the neural network model; iteratively updates the model parameters of the neural network model using the gradient update function; in response to the number of iterations of the model parameters of the neural network model reaching a first threshold, the neural network model parameters corresponding to the number of iterations reaching the first threshold are set as target model parameters of the neural network model; a target cost function is determined based on the target model parameters of the neural network model, and a target neural network model is determined based on the target cost function; and image data is processed using the target neural network model.

[0186] This application proposes a gradient-based alternating learning rate optimization method. During the optimization process of the neural network, the neural network parameters are adaptively and rapidly updated, and a certain optimization insurance function and generalization ability are provided, resulting in better application performance.

[0187] Furthermore, the image data processing method further includes:

[0188] Load image files into memory using the OpenCV or Pillow (PIL) library;

[0189] Display the image data using the Matplotlib library; scale, rotate, and flip the image;

[0190] The boundaries in the image are determined using the Sobel operator and Canny edge detection technology.

[0191] Key information is extracted from the image using algorithms, including HOG (Histogram of Oriented Gradients), SIFT (Scale-Invariant Feature Transform), and SURF (Speeded UpRobust Features).

[0192] The image is divided into different regions using K-means clustering, region growing algorithms, or deep learning methods such as U-Net;

[0193] Noise in the image is removed using Gaussian filtering and median filtering techniques.

[0194] The image is cleaned using dilation and erosion morphological operations;

[0195] The image task is processed by learning a model using convolutional neural networks (CNNs); wherein the image task includes complex image classification, object detection, and semantic segmentation.

[0196] Here, for each of the above technologies, there are corresponding Python libraries to support them. For example, OpenCV is used for basic image processing, scikit-image is used for more advanced functions, and TensorFlow or PyTorch is used to build and train deep learning models.

[0197] Processing image data requires selecting appropriate tools and technology stacks based on specific processing needs, and may also require adjusting parameters to optimize model performance.

[0198] The data processing method provided in the embodiments of this application can be improved and optimized in several ways without departing from the technical solution of this application, and these improvements and optimizations should also be considered within the scope of protection of this application.

[0199] The beneficial effects of the technical solutions provided in this application are:

[0200] This application is based on a hybrid learning rate optimization design pattern, which can overcome the local optimum dilemma in the learning rate optimization process, improve the verification logic of the neural network model, and has a certain generalization ability.

[0201] The technical solution provided in this application embodiment is based on the first-order derivative information and second-order derivative information of the optimized position, and coordinates the learning rate in the entire design process to adaptively optimize the neural network function, improve the optimization efficiency of the neural network, and overcome local optima.

[0202] The technical solution provided in this application proposes a learning rate alternation optimization method based on gradient change. In the optimization process of the neural network, the neural network parameters are adaptively and quickly updated and optimized, and a certain optimization insurance function and generalization ability are provided, resulting in better application effect.

[0203] Example 3

[0204] This application provides a data processing apparatus, such as... Figure 2 As shown, the device includes an acquisition module, a first determination module, a calculation module, an update module, a setting module, a second determination module, and a processing module.

[0205] In this embodiment, the acquisition module is used to acquire an image dataset;

[0206] The first determining module is used to create a neural network model based on the image dataset, determine a cost function based on the neural network model, and determine a gradient update function based on the target learning rate and the model parameters of the neural network model.

[0207] The calculation module is used to calculate the first-order derivative information and the second-order derivative information according to the cost function, calculate the target learning rate according to the first-order derivative information and the second-order derivative information, and calculate the model parameters of the neural network model according to the first-order derivative information and the second-order derivative information.

[0208] The update module is used to iteratively update the model parameters of the neural network model through the gradient update function;

[0209] The setting module is used to set the neural network model parameters corresponding to the number of iterations of the neural network model parameters reaching the first threshold as the target model parameters of the neural network model in response to the number of iterations of the neural network model parameters reaching the first threshold.

[0210] The second determining module is used to determine a target cost function based on the target model parameters of the neural network model, and to determine a target neural network model based on the target cost function;

[0211] The processing module is used to process image data through the target neural network model.

[0212] In one embodiment, the first determining module is used to acquire historical image data x and the weights w of each neuron in the neural network model;

[0213] Obtain the predicted value h based on historical image data and the weights of each neuron. w (x), the true value y corresponding to the historical image data;

[0214] Obtain the regularization coefficient μ, the number of historical image data S, and the weight w of the i-th neuron. i ;

[0215] Through formula Calculate the cost function J(w), where, This is a regularization term.

[0216] In one embodiment, a calculation module is used to obtain the cost function J(w) and the weights w of each neuron in the neural network model;

[0217] Through formula Calculate the first derivative information α;

[0218] Through formula Calculate the second derivative information β;

[0219] Obtain the exponential decay rate p and the first derivative α at the current time. n The first derivative information α relative to the current time and the previous time. n-1 The number of iterations is n, where p is a positive number less than 1;

[0220] Through formula Calculate the current first learning rate l n ;

[0221] Obtain the aggravation coefficient c and the second derivative information β at the current time. n , where the value of c conforms to the uniform distribution function U(0,1);

[0222] Through formula r n =r (n-1) -cr (n-1) β n Calculate the current second learning rate r n , where r (n-1) The second learning rate is relative to the previous time step;

[0223] Through formula λ n =max(l n ,r n Determine the target learning rate λ. n .

[0224] In one embodiment, the calculation module is used to obtain the first-order momentum information calculation equation. The first derivative information α of the previous time relative to the current time. n-1 ;

[0225] Through formula Calculate the current first-order momentum information m n ;

[0226] Calculation equation for obtaining second-order momentum information The second derivative information β relative to the current time point of the previous time point n-1 ;

[0227] Through formula Calculate the current second-order momentum information v n ;

[0228] Wherein, the first-order momentum information m and the second-order momentum information v are the model parameters of the neural network model.

[0229] In one embodiment, the second determining module is used to obtain the target learning rate λ. nCurrent first-order momentum information m n The current second-order momentum information v n ;

[0230] Obtain the regularization coefficient μ, and the number of historical image data S;

[0231] Obtain the weights w of each neuron in the neural network model. n In a neural network model, the weights w of each neuron relative to the previous time step are... n-1 ;

[0232] Through formula Determine the gradient update function.

[0233] In one embodiment, the second determining module is configured to determine the model parameters of the neural network model as m when the number of iterations of the model parameters of the neural network model is a first threshold. m v m ;

[0234] Through formula Inversely determine the first derivative information α' of the target;

[0235] Through formula Inversely determine the target's second derivative information β';

[0236] Through formula The objective cost function J(w)' is determined in reverse.

[0237] In one embodiment, the processing module is used to convert the image data into a format corresponding to the target neural network model. The conversion process includes adjusting the image size, normalizing pixel values, and rotating and translating to increase the robustness of the model.

[0238] The target neural network model is determined according to the task requirements, wherein the target neural network model includes a convolutional neural network;

[0239] The target neural network model is configured with convolutional layers, pooling layers, and fully connected layers, wherein the convolutional layers are used to extract image features, the pooling layers are used to reduce spatial dimensions, and the fully connected layers are used for decision-making in classification tasks.

[0240] The target neural network model is trained;

[0241] Training the target neural network model includes:

[0242] Determine the target loss function of the target neural network model based on the image data processing task type;

[0243] An optimization algorithm for updating the target neural network model, wherein the optimization algorithm includes a stochastic gradient descent algorithm;

[0244] The target neural network model is trained using a training dataset, and the target loss function is adjusted by adjusting the network weights through backpropagation.

[0245] The target neural network model is improved by adjusting the form of parameters, wherein the parameters include learning rate, batch size, number of layers, and number of nodes;

[0246] The performance of the target neural network model was verified using a test dataset;

[0247] The target neural network model is trained to predict or classify image data after format conversion.

[0248] After predicting or classifying the converted image data using the trained target neural network model, the process includes:

[0249] The target neural network model is optimized using model compression and quantization techniques.

[0250] The beneficial effects of the technical solutions provided in this application are:

[0251] This application is based on a hybrid learning rate optimization design pattern, which can overcome the local optimum dilemma in the learning rate optimization process, improve the verification logic of the neural network model, and has a certain generalization ability.

[0252] The technical solution provided in this application embodiment is based on the first-order derivative information and second-order derivative information of the optimized position, and coordinates the learning rate in the entire design process to adaptively optimize the neural network function, improve the optimization efficiency of the neural network, and overcome local optima.

[0253] The technical solution provided in this application proposes a learning rate alternation optimization method based on gradient change. In the optimization process of the neural network, the neural network parameters are adaptively and quickly updated and optimized, and a certain optimization insurance function and generalization ability are provided, resulting in better application effect.

[0254] Example 4

[0255] The present invention also provides a data processing apparatus, comprising:

[0256] One or more processors;

[0257] Storage device for storing one or more programs;

[0258] When the one or more programs are executed by the one or more processors, the one or more processors perform the following data processing method:

[0259] Obtain the image dataset;

[0260] A neural network model is created based on the image dataset, and a cost function is determined based on the neural network model.

[0261] The first-order derivative information and the second-order derivative information are calculated based on the cost function, and the target learning rate is calculated based on the first-order derivative information and the second-order derivative information.

[0262] The model parameters of the neural network model are calculated based on the first-order derivative information and the second-order derivative information.

[0263] The gradient update function is determined based on the target learning rate and the model parameters of the neural network model;

[0264] The model parameters of the neural network model are iteratively updated using the gradient update function;

[0265] In response to the neural network model's model parameter iteration update count reaching a first threshold, the neural network model parameters corresponding to the first threshold's model parameter iteration update count are set as the neural network model target model parameters.

[0266] The target cost function is determined based on the target model parameters of the neural network model, and the target neural network model is determined based on the target cost function;

[0267] The image data is processed using the target neural network model.

[0268] The beneficial effects of the technical solutions provided in this application are:

[0269] This application is based on a hybrid learning rate optimization design pattern, which can overcome the local optimum dilemma in the learning rate optimization process, improve the verification logic of the neural network model, and has a certain generalization ability.

[0270] The technical solution provided in this application embodiment is based on the first-order derivative information and second-order derivative information of the optimized position, and coordinates the learning rate in the entire design process to adaptively optimize the neural network function, improve the optimization efficiency of the neural network, and overcome local optima.

[0271] The technical solution provided in this application proposes a learning rate alternation optimization method based on gradient change. In the optimization process of the neural network, the neural network parameters are adaptively and quickly updated and optimized, and a certain optimization insurance function and generalization ability are provided, resulting in better application effect.

[0272] Example 5

[0273] This application provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it can perform the following data processing method:

[0274] Obtain the image dataset;

[0275] A neural network model is created based on the image dataset, and a cost function is determined based on the neural network model.

[0276] The first-order derivative information and the second-order derivative information are calculated based on the cost function, and the target learning rate is calculated based on the first-order derivative information and the second-order derivative information.

[0277] The model parameters of the neural network model are calculated based on the first-order derivative information and the second-order derivative information.

[0278] The gradient update function is determined based on the target learning rate and the model parameters of the neural network model;

[0279] The model parameters of the neural network model are iteratively updated using the gradient update function;

[0280] In response to the neural network model's model parameter iteration update count reaching a first threshold, the neural network model parameters corresponding to the first threshold's model parameter iteration update count are set as the neural network model target model parameters.

[0281] The target cost function is determined based on the target model parameters of the neural network model, and the target neural network model is determined based on the target cost function;

[0282] The image data is processed using the target neural network model.

[0283] The beneficial effects of the technical solutions provided in this application are:

[0284] This application is based on a hybrid learning rate optimization design pattern, which can overcome the local optimum dilemma in the learning rate optimization process, improve the verification logic of the neural network model, and has a certain generalization ability.

[0285] The technical solution provided in this application embodiment is based on the first-order derivative information and second-order derivative information of the optimized position, and coordinates the learning rate in the entire design process to adaptively optimize the neural network function, improve the optimization efficiency of the neural network, and overcome local optima.

[0286] The technical solution provided in this application proposes a learning rate alternation optimization method based on gradient change. In the optimization process of the neural network, the neural network parameters are adaptively and quickly updated and optimized, and a certain optimization insurance function and generalization ability are provided, resulting in better application effect.

[0287] Example 6

[0288] This application also provides a computer program product, including a computer program that, when executed by a processor, can implement the following data processing method:

[0289] Obtain the image dataset;

[0290] A neural network model is created based on the image dataset, and a cost function is determined based on the neural network model.

[0291] The first-order derivative information and the second-order derivative information are calculated based on the cost function, and the target learning rate is calculated based on the first-order derivative information and the second-order derivative information.

[0292] The model parameters of the neural network model are calculated based on the first-order derivative information and the second-order derivative information.

[0293] The gradient update function is determined based on the target learning rate and the model parameters of the neural network model;

[0294] The model parameters of the neural network model are iteratively updated using the gradient update function;

[0295] In response to the neural network model's model parameter iteration update count reaching a first threshold, the neural network model parameters corresponding to the first threshold's model parameter iteration update count are set as the neural network model target model parameters.

[0296] The target cost function is determined based on the target model parameters of the neural network model, and the target neural network model is determined based on the target cost function;

[0297] The image data is processed using the target neural network model.

[0298] The beneficial effects of the technical solutions provided in this application are:

[0299] This application is based on a hybrid learning rate optimization design pattern, which can overcome the local optimum dilemma in the learning rate optimization process, improve the verification logic of the neural network model, and has a certain generalization ability.

[0300] The technical solution provided in this application embodiment is based on the first-order derivative information and second-order derivative information of the optimized position, and coordinates the learning rate in the entire design process to adaptively optimize the neural network function, improve the optimization efficiency of the neural network, and overcome local optima.

[0301] The technical solution provided in this application proposes a learning rate alternation optimization method based on gradient change. In the optimization process of the neural network, the neural network parameters are adaptively and quickly updated and optimized, and a certain optimization insurance function and generalization ability are provided, resulting in better application effect.

[0302] Example 7

[0303] This application provides a computer storage medium, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, it performs the following steps:

[0304] Obtain the image dataset;

[0305] A neural network model is created based on the image dataset, and a cost function is determined based on the neural network model.

[0306] The first-order derivative information and the second-order derivative information are calculated based on the cost function, and the target learning rate is calculated based on the first-order derivative information and the second-order derivative information.

[0307] The model parameters of the neural network model are calculated based on the first-order derivative information and the second-order derivative information.

[0308] The gradient update function is determined based on the target learning rate and the model parameters of the neural network model;

[0309] The model parameters of the neural network model are iteratively updated using the gradient update function;

[0310] In response to the neural network model's model parameter iteration update count reaching a first threshold, the neural network model parameters corresponding to the first threshold's model parameter iteration update count are set as the neural network model target model parameters.

[0311] The target cost function is determined based on the target model parameters of the neural network model, and the target neural network model is determined based on the target cost function;

[0312] The image data is processed using the target neural network model.

[0313] In one embodiment, determining the cost function based on the neural network model includes:

[0314] Obtain historical image data x, and the weights w of each neuron in the neural network model;

[0315] Obtain the predicted value h based on historical image data and the weights of each neuron. w (x), the true value y corresponding to the historical image data;

[0316] Obtain the regularization coefficient μ, the number of historical image data S, and the weight w of the i-th neuron. i ;

[0317] Through formula Calculate the cost function J(w), where, This is a regularization term.

[0318] In one embodiment, the step of calculating the first-order derivative information and the second-order derivative information based on the cost function, and calculating the target learning rate based on the first-order derivative information and the second-order derivative information, includes:

[0319] Obtain the cost function J(w), and the weights w of each neuron in the neural network model;

[0320] Through formula Calculate the first derivative information α;

[0321] Through formula Calculate the second derivative information β;

[0322] Obtain the exponential decay rate p and the first derivative α at the current time. n The first derivative information α relative to the current time and the previous time. n-1 The number of iterations is n, where p is a positive number less than 1;

[0323] Through formula Calculate the current first learning rate l n ;

[0324] Obtain the aggravation coefficient c and the second derivative information β at the current time. n , where the value of c conforms to the uniform distribution function U(0,1);

[0325] Through formula r n =r (n-1) -cr (n-1) β n Calculate the current second learning rate r n , where r (n-1) The second learning rate is relative to the previous time step;

[0326] Through formula λ n =max(l n ,r nDetermine the target learning rate λ. n .

[0327] In one embodiment, calculating the model parameters of the neural network model based on the first-order derivative information and the second-order derivative information includes:

[0328] Obtaining first-order momentum information and calculating equations The first derivative information α of the previous time relative to the current time. n-1 ;

[0329] Through formula Calculate the current first-order momentum information m n ;

[0330] Calculation equation for obtaining second-order momentum information The second derivative information β relative to the current time point of the previous time point n-1 ;

[0331] Through formula Calculate the current second-order momentum information v n ;

[0332] Wherein, the first-order momentum information m and the second-order momentum information v are the model parameters of the neural network model.

[0333] In one embodiment, determining the gradient update function based on the target learning rate and the model parameters of the neural network model includes:

[0334] Obtain the target learning rate λ n Current first-order momentum information m n The current second-order momentum information v n ;

[0335] Obtain the regularization coefficient μ, and the number of historical image data S;

[0336] Obtain the weights w of each neuron in the neural network model. n In a neural network model, the weights w of each neuron relative to the previous time step are... n-1 ;

[0337] Through formula Determine the gradient update function.

[0338] In one embodiment, determining the target cost function based on the target model parameters of the neural network model includes:

[0339] When the number of iterations of the model parameters of the neural network model is the first threshold, the model parameters of the neural network model are m. m v m ;

[0340] Through formula Inversely determine the first derivative information α' of the target;

[0341] Through formula Inversely determine the target's second derivative information β';

[0342] Through formula The objective cost function J(w)' is determined in reverse.

[0343] In one embodiment, the processing of image data through the target neural network model includes:

[0344] The image data is converted into the format corresponding to the target neural network model. The conversion process includes adjusting the image size, normalizing pixel values, and rotating and translating to increase the robustness of the model.

[0345] The target neural network model is determined according to the task requirements, wherein the target neural network model includes a convolutional neural network;

[0346] The target neural network model is configured with convolutional layers, pooling layers, and fully connected layers, wherein the convolutional layers are used to extract image features, the pooling layers are used to reduce spatial dimensions, and the fully connected layers are used for decision-making in classification tasks.

[0347] The target neural network model is trained;

[0348] Training the target neural network model includes:

[0349] Determine the target loss function of the target neural network model based on the image data processing task type;

[0350] An optimization algorithm for updating the target neural network model, wherein the optimization algorithm includes a stochastic gradient descent algorithm;

[0351] The target neural network model is trained using a training dataset, and the target loss function is adjusted by adjusting the network weights through backpropagation.

[0352] The target neural network model is improved by adjusting the form of parameters, wherein the parameters include learning rate, batch size, number of layers, and number of nodes;

[0353] The performance of the target neural network model was verified using a test dataset;

[0354] The target neural network model is trained to predict or classify image data after format conversion.

[0355] After predicting or classifying the converted image data using the trained target neural network model, the process includes:

[0356] The target neural network model is optimized using model compression and quantization techniques.

[0357] This application can overcome the local optimum dilemma in the learning rate optimization process, improve the verification logic of neural network models, and has a certain generalization ability.

[0358] Figure 3 This is an exemplary system provided for Embodiment Seven of this application, which can be used to implement the various embodiments described in this application;

[0359] like Figure 3 As shown, in some embodiments, the system can function as any of the aforementioned devices for data processing in each of the various embodiments. In some embodiments, the system may include one or more computer-readable media (e.g., system memory or NVM / storage device) having a result, and one or more processors (e.g., one or more processors) coupled to the one or more computer-readable media and configured to execute the result to implement the module thereby performing the actions described in this application.

[0360] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), Rambus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0361] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0362] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the invention patent. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this patent application should be determined by the appended claims.

Claims

1. A data processing method, characterized by, The method comprises: acquiring an image data set; creating a neural network model according to the image data set, determining a cost function according to the neural network model; determining first derivative information and second derivative information according to the cost function, and determining a target learning rate according to the first derivative information and the second derivative information; determining model parameters of the neural network model according to the first derivative information and the second derivative information; determining a gradient update function according to the target learning rate and the model parameters of the neural network model; iteratively updating the model parameters of the neural network model through the gradient update function; in response to the number of iterations of the model parameters of the neural network model reaching a first threshold, setting the model parameters of the neural network model corresponding to the number of iterations of the model parameters of the neural network model reaching the first threshold as target model parameters of the neural network model; determining a target cost function according to the target model parameters of the neural network model, and determining a target neural network model according to the target cost function; processing image data through the target neural network model.

2. The data processing method according to claim 1, characterized in that, The determination of the cost function according to the neural network model comprises: acquiring historical image data x and the weights w of each neuron in the neural network model; obtaining a prediction value h based on historical image data and weights of the respective neurons w (x), the historical image data corresponding to a true value y; obtaining a regularization coefficient μ, a number S of the history image data, a weight w of an i-th neuron i ; The cost function J(w) is computed by the formula where, is a regularization term.

3. The data processing method according to claim 2, characterized in that, The determination of the first derivative information and the second derivative information according to the cost function, and the determination of the target learning rate according to the first derivative information and the second derivative information, comprise: acquiring the cost function J(w) and the weights w of each neuron in the neural network model; The first derivative information a is calculated by the formula a = - (b - c) / 2 The second derivative information β is calculated by the formula β = - (1 - 2 * a) acquiring an exponential decay rate p, first derivative information a at a current time n , first derivative information a at a time immediately preceding the current time n-1 , an iteration number n, wherein p is a positive number less than 1 Through formula Calculate the current first learning rate l n ; obtaining an aggravation coefficient c, second derivative information β at a current moment n wherein the value of c conforms to a uniform distribution function U(0, 1); The current second learning rate r n is calculated by the formula (n-1) r 9n-1) = r n - cr n , where r (n-1) is the second learning rate of the previous time relative to the current time. The target learning rate λ n is determined by the formula λ n = max(l n , r n ).

4. The data processing method according to claim 3, characterized in that, The determination of the model parameters of the neural network model according to the first derivative information and the second derivative information comprises: Equation for acquiring first-order momentum information First-order derivative information α with respect to the previous time from the current time n-1 ; The current first order momentum information m is calculated by the formula n ;​ Equation for acquiring second-order momentum information Second derivative information β with respect to the previous time from the current time n-1 ; The current second order momentum information v is calculated by the formula n ;​ wherein the first momentum information m and the second momentum information v are the model parameters of the neural network model.

5. The data processing method according to claim 4, characterized in that, The determination of the gradient update function according to the target learning rate and the model parameters of the neural network model comprises: obtaining a target learning rate λ n current first order momentum information m n current second order momentum information v n ; acquiring a regularization coefficient μ and the number S of the historical image data; obtaining the weight w of each neuron in the neural network model at the current time n obtaining the weight w of each neuron in the neural network model at the previous time relative to the current time n-1 ; The gradient update function is determined by the formula determining a gradient update function.

6. The data processing method according to claim 4, characterized in that, The determination of the target cost function according to the target model parameters of the neural network model comprises: When the number of iterations of the model parameters of the neural network model is a first threshold value, the model parameters of the neural network model are m m , v m ; By formula determining target first derivative information a' in reverse; By formula determining target second derivative information β' in reverse; By formula The target cost function J(w)' is determined inversely.

7. The data processing method of claim 1, wherein, The processing of the image data through the target neural network model comprises: converting the image data into a format corresponding to the target neural network model, wherein the conversion process comprises adjusting the image size, normalizing the pixel value, and rotating and translating to increase the robustness of the model; determining a target neural network model according to the task requirements, wherein the target neural network model comprises a convolutional neural network; setting the convolutional layer, the pooling layer, and the fully connected layer of the target neural network model, wherein the convolutional layer is used to extract image features, the pooling layer is used to reduce the spatial dimension, and the fully connected layer is used for decision-making in classification tasks; training the target neural network model; The training of the target neural network model comprises: determining a target loss function of the target neural network model according to the type of the image data processing task; updating the optimization algorithm of the target neural network model, wherein the optimization algorithm comprises a stochastic gradient descent algorithm; The target neural network model is trained through a training data set, and the target loss function is adjusted by adjusting network weight through back propagation; The target neural network model is improved by adjusting parameters, including learning rate, batch size, number of layers, and number of nodes; The performance of the target neural network model is verified through a test data set; The converted image data is predicted or classified by the trained target neural network model; After the converted image data is predicted or classified by the trained target neural network model, the target neural network model is optimized through model compression and quantization techniques. The device comprises:

8. A data processing apparatus, characterized by, An acquisition module for acquiring an image data set; A first determination module for creating a neural network model according to the image data set, determining a cost function according to the neural network model, and determining a gradient update function according to the target learning rate and model parameters of the neural network model; A calculation module for determining first and second derivative information according to the cost function, determining a target learning rate according to the first and second derivative information, and determining model parameters of the neural network model according to the first and second derivative information; An update module for iteratively updating model parameters of the neural network model through the gradient update function; A setting module for setting the neural network model parameters corresponding to the first threshold value of the number of model parameter iterative updates of the neural network model as target model parameters of the neural network model when the number of model parameter iterative updates of the neural network model reaches the first threshold value; A second determination module for determining a target cost function according to the target model parameters of the neural network model, and determining a target neural network model according to the target cost function; A processing module for processing image data through the target neural network model. The processor executes the computer program to realize the steps of the data processing method of any one of claims 1 to 7.

9. A computer device comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, The computer program is executed by the processor to realize the steps of the data processing method of any one of claims 1 to 7.

10. A computer-readable storage medium having stored thereon a computer program, characterized in that, ​