Deep learning neural network-based automatic reaction control method and system for production of calcium hypochlorite
Through the deep learning neural network, the calcium bleaching powder production process is monitored in real time, and the problems of low automation and high human judgment errors in traditional methods are solved, fully automated reaction control is achieved, and product quality and safety are improved.
Patent Information
- Application Number
- CN202510513980.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-23
- Publication Date
- 2025-08-05
AI Technical Summary
The traditional calcium bleaching powder production process has low degree of automation, high labor intensity, and high human judgment errors, resulting in improper use of chlorine, affecting product quality and safety.
Using a deep learning neural network method, we use real-time microscopic observation of pictures, predict the reaction stage and output process control parameters to achieve fully automated reaction control.
Improves production efficiency, reduces the risk of chlorine leakage and excess, and improves product quality and safety.
Smart Images

Figure CN120428552A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of chemical automation, and in particular relates to a method and system for controlling an automated reaction in the production of bleaching powder based on a deep learning neural network. Background Art
[0002] Bleaching powder is a highly effective bleaching agent and disinfectant with calcium hypochlorite as its primary active ingredient, widely used in industrial and household cleaning applications. Currently, the production process for bleaching powder is primarily divided into two technical routes: the calcium method and the sodium method. The active chemical component of the calcium method bleaching powder is 3Ca(ClO)2·2Ca(OH)2·2HxO, and its preparation process is completed through the chemical reaction of calcium hydroxide (Ca(OH)2) and chlorine gas (Cl2). The overall reaction equation is as follows:
[0003] 8Ca(OH)2+6Cl2→3Ca(ClO)2·2Ca(OH)2·2H2O+3CaCl2+4H2O
[0004] The chlorination unit is the core link in the production process of bleaching powder. The chlorination reaction is an exothermic reaction involving three phases: gas, liquid, and solid, and involves multiple chemical unit operations such as diffusion, chemical reaction, crystallization, and heat transfer. The chlorination reaction of calcium bleaching powder is generally divided into three main stages:
[0005] Stage 1: Initially, chlorine gas is introduced into the lime milk, causing calcium hydroxide (Ca(OH)2) to react with chlorine (Cl2) to form calcium hypochlorite (Ca(ClO)2). As the reaction proceeds, the concentration of calcium hypochlorite in the liquid phase gradually increases. The end of Stage 1 is marked by saturation of the liquid phase with calcium hypochlorite and the precipitation of small hexagonal crystals of Ca(ClO)2·2Ca(OH)2. This stage boasts the highest chlorine flux and the highest heat release, making it the most exothermic stage of the entire reaction.
[0006] Stage 2: After entering Stage 2, the chlorine flow rate is reduced, and the reaction rate slows. At this point, hexagonal Ca(ClO)2·2Ca(OH)2 crystals gradually increase in number and begin to grow. The end of Stage 2 is marked by the beginning of the fragmentation of large hexagonal crystals and the appearance of small needle-shaped crystals (3Ca(ClO)2·2Ca(OH)2·2H2O). The chlorine flow rate and reaction exotherm during this stage are significantly lower than those in Stage 1, and the reaction is primarily characterized by crystal growth and morphological transformation.
[0007] Stage 3: In Stage 3, the chlorine flow rate is further reduced to its lowest value. At this point, the hexagonal crystals gradually break up, while the small needle-like crystals of 3Ca(ClO)2·2Ca(OH)2·2H2O gradually grow. The end of Stage 3 is marked by the near-complete disappearance of the regular hexagonal crystals and the observation of large needle-like crystals under a microscope. The chlorine flow rate and reaction exotherm are both at their lowest during this stage, primarily reflecting the final transformation and maturation of the crystal morphology.
[0008] Traditional calcium-based bleaching powder chlorination is typically performed in a batch chlorination kettle. The entire chlorination cycle takes approximately six hours and consists of four steps: adding ash emulsion, chlorine flow, cooling, and unloading. Operators observe the crystal morphology under a microscope to determine the reaction stage and adjust the chlorine and cooling water flows accordingly. However, this method, which relies on manual observation, presents the following problems:
[0009] (1) Low degree of automation and high labor intensity. Frequent sampling is required to monitor crystal morphology near the end of each stage and the reaction endpoint, resulting in low operating efficiency and significantly increased labor intensity.
[0010] (2) The risk of human judgment error is high. If the sampling timing is inaccurate, the observation is not careful, or the sample is not representative enough, it may result in insufficient or excessive chlorine. Insufficient chlorine will cause the product's effective chlorine content to fail to meet the standard and increase raw material consumption; excessive chlorine may cause the complete decomposition of the single-pot product, resulting in production accidents.
[0011] Solving the above problems, improving operating methods and introducing automated monitoring technology have become key directions for improving production efficiency and product quality. Summary of the Invention
[0012] One of the purposes of the present invention is to provide an automated reaction control method for bleaching powder production based on a deep learning neural network, which is used for a calcium-based bleaching powder chlorination unit. The method can upload real-time microscopic observation images of the chlorination reaction online, predict the current reaction stage based on the images, and output process control parameters, thereby realizing fully automated reaction control of bleaching powder production.
[0013] The second object of the present invention is to provide an automated reaction control for bleaching powder production based on a deep learning neural network, which is used in the above method.
[0014] To achieve the above object, the technical solution adopted by the present invention is as follows:
[0015] The first aspect of the present invention discloses an automated reaction control method for bleaching powder production based on a deep learning neural network, comprising the following steps:
[0016] S1. Data Collection: Acquire multiple microscopic images of the calcium bleaching powder chlorination unit at each reaction stage;
[0017] S2. Image Preprocessing: Manually classify the collected microscopic images and annotate them into six reaction stages based on crystal morphology to form a labeled dataset.
[0018] S3. Deep learning model training:
[0019] S31. Performing image enhancement and preprocessing on the labeled dataset;
[0020] S32. Divide the preprocessed dataset into a training set, a validation set, and a test set;
[0021] S33. Build a convolutional neural network model or train it based on an open-source pre-trained model, construct training, evaluation, and validation functions, and record training loss, accuracy, and recall.
[0022] S4. Model Validation and Debugging: Debug the model by analyzing the loss curve, accuracy curve, and confusion matrix. Improve the model's generalization ability through data augmentation, regularization, early stopping, or adjusting the learning rate.
[0023] S5. Model preservation and lightweighting: Convert the trained model to ONNX or TensorRT format and save it to the local server as a prediction model;
[0024] S6. Real-time prediction: The prediction model is encapsulated as an HTTP service, which receives real-time image input from online microscopy observations and outputs the corresponding reaction stage;
[0025] S7. Reaction process control: Based on the reaction stage output by the prediction model, the corresponding process control parameters are sent to the DCS system to achieve closed-loop automatic control of the reaction process.
[0026] In some embodiments of the present invention, in step S1, a high-definition online microscopic observation technology is used, a microscope probe is built into the reactor, or an automatic sampling microscopic observation technology is used to obtain a microscopic picture of the reaction process in real time;
[0027] Preferably, in the first reaction stage, a picture is collected and uploaded to the server every 30 minutes; in the second reaction stage, a picture is collected and uploaded to the server every 15 minutes; and in the third reaction stage, a picture is collected and uploaded to the server every 5 minutes.
[0028] The first stage of the reaction described herein refers to the initial stage of the chlorination reaction, in which chlorine gas is introduced into the lime milk, causing calcium hydroxide (Ca(OH)2) to react with chlorine gas (Cl2) to form calcium hypochlorite (Ca(ClO)2). As the reaction proceeds, the concentration of calcium hypochlorite in the liquid phase gradually increases. The end of the first stage of the reaction is marked by the calcium hypochlorite in the liquid phase reaching saturation and the beginning of precipitation of small regular hexagonal crystals of Ca(ClO)2·2Ca(OH)2.
[0029] After entering the second stage of the reaction, the chlorine flow rate is reduced, and the reaction rate slows. At this point, hexagonal Ca(ClO)2·2Ca(OH)2 crystals gradually increase and begin to grow. The end of the second stage is marked by the beginning of the fragmentation of large hexagonal crystals and the appearance of small needle-shaped crystals (3Ca(ClO)2·2Ca(OH)2·2H2O).
[0030] In the third stage of the reaction, the chlorine flow rate was further reduced to its lowest value. At this point, the hexagonal crystals gradually broke apart, while the small needle-like crystals of 3Ca(ClO)2·2Ca(OH)2·2H2O gradually grew. The end of the third stage of the reaction was marked by the near-complete disappearance of the regular hexagonal crystals and the appearance of large needle-like crystals under a microscope.
[0031] In some embodiments of the present invention, in step S2, classification is performed based on the microscopic images collected based on the crystal morphology, as follows:
[0032] The crystal morphology shown in the micrograph is small amorphous crystals, labeled as stage I;
[0033] The crystal morphology shown in the micrograph is hexagonal crystals, labeled as stage II;
[0034] The crystal morphology shown in the micrograph is broken hexagonal crystals, labeled as stage III;
[0035] The crystal morphology shown in the micrograph is needle-shaped crystals accompanied by a large number of hexagonal broken crystals, marked as stage IV;
[0036] The crystal morphology shown in the micrograph is needle-shaped crystals, marked as stage V;
[0037] The crystal morphology shown in the micrograph is broken needle-like crystals, labeled as stage VI.
[0038] In some embodiments of the present invention, in step S31, the Transforms module is used to process and enhance the image, and the Dataset and DataLoader modules are used to load and batch process the images;
[0039] In step S32, the ratio of the training set, validation set, and test set is 8:1:1;
[0040] In step S33, the convolutional neural network model includes ResNet and VGG architectures; preferably, includes ResNet34, ResNet50, and VGG architectures;
[0041] Preferably, the training mode of step S33 is transfer learning, and the residual block is first defined:
[0042] y=F(x,{W i})+x
[0043] Among them, x is the input of the residual block of the previous neural network;
[0044] F(x,{W i}) is the residual mapping, that is, the neural network learning result; preferably, it is two 3x3 convolutional layers;
[0045] y is the input of the residual block;
[0046] Then the convolutional layer of each level of residual block adopts the ReLu activation formula:
[0047] z1=ReLU(BN(Conv3x3(x)))
[0048] z2=BN(Conv3x3(z1))
[0049] y=z2+x。
[0050] In some embodiments of the present invention, the formula for the accuracy in step S33 is:
[0051]
[0052] in,
[0053] TP (Ture Positives): Correctly predicted positive samples;
[0054] TN (Ture Negatives): Correctly predicted negative samples;
[0055] FP (False Positives): incorrectly predicted positive samples;
[0056] FN (False Negatives): incorrectly predicted negative samples;
[0057] The formula for training accuracy is:
[0058] Precision=TP / TP+FP
[0059] The formula for recall is:
[0060] Recall=TP / TP+FN
[0061] The formula for F1-Score is:
[0062] F1=2x Precision x Recall / Precision+Recall
[0063] The formula for training loss is:
[0064]
[0065] Where: N represents the number of samples; C represents the number of categories; j represents the sample index; ii represents the category index; y ji Represents the true probability value of the j-th sample in the i-th category; It represents the probability that the model predicts that the jth sample belongs to the i-th category.
[0066] In some embodiments of the present invention, in step S6, the model is encapsulated as an HTTP service through Flask or FastAPI.
[0067] In some embodiments of the present invention, in step S7, the corresponding relationship between the reaction stage predicted by the prediction model and the process control parameters is as follows:
[0068] Predict reaction stage I, stirring rate is R1 RPM, chlorine flow rate is V1 m 3 / h, the circulating water flow rate is M1 m 3 / h;
[0069] Predict reaction stage II, stirring rate is R1 RPM, chlorine flow rate is V1 m 3 / h, the circulating water flow rate is M1 m 3 / h;
[0070] Predict reaction stage III, stirring rate is R1 RPM, chlorine flow rate is V2 m 3 / h, the circulating water flow rate is M2 m 3 / h;
[0071] Predict reaction stage IV, stirring rate is R2 RPM, chlorine flow rate is V2 m 3 / h, the circulating water flow rate is M2 m 3 / h;
[0072] Predict the reaction stage V, with a stirring rate of R2 RPM and a chlorine flow rate of V3 m 3 / h, the circulating water flow rate is M3m 3 / h;
[0073] Predicted reaction stage VI, stirring rate is R3 RPM, chlorine flow rate is V4 m 3 / h, the circulating water flow rate is M4 m 3 / h.
[0074] The second aspect of the present invention discloses an automated reaction control system for bleaching powder production based on a deep learning neural network, which is used in the above-mentioned automated reaction control method for bleaching powder production, including a data acquisition module, an automated reaction stage judgment module, an automatic process control parameter optimization module, and a DCS control module, wherein:
[0075] The data acquisition module includes a high-definition microscope probe, which is built into the reactor or connected to the automatic sampling device to collect microscopic images of the reaction process in real time;
[0076] The reaction stage automatic judgment module is an HTTP service interface built based on the Flask or FastAPI framework, which is used to receive real-time microscopic images and return the predicted reaction stage; the reaction stage automatic judgment module is configured with a real-time prediction model, which is obtained by steps S1 to S5 of the control method according to any one of claims 1 to 7;
[0077] The process control parameter automatic optimization module outputs the process parameters to the DCS control module based on the reaction stage predicted by the reaction stage;
[0078] The DCS control module is used to output process parameters according to the predicted reaction stage to achieve automatic regulation of the reaction process.
[0079] In some embodiments of the present invention, the process control parameter automatic optimization module includes a manual adjustment function, which can realize manual fine-tuning of process parameters.
[0080] In some working embodiments of the present invention, the reaction phase automatic judgment module integrates an asynchronous task queue for processing multiple image prediction requests in parallel.
[0081] Compared with the prior art, the present invention has the following beneficial effects:
[0082] The present invention is scientifically designed and ingeniously conceived. The present invention can upload real-time microscopic observation pictures of the chlorination reaction to a local server in real time; predict the current reaction stage based on the pictures and output process control parameters, thereby realizing fully automated reaction control of bleaching powder production.
[0083] In the model training image preprocessing of the present invention, unlike the prior art which divides the chlorination reaction into three stages, the present invention creatively refines the reaction stages into six stages and performs image preprocessing and classification according to crystal characteristics.
[0084] Compared with the three-stage chlorine-passing method in the prior art, the six-stage chlorine-passing method of the present invention has more precise control of process parameters for different reaction stages and has the following advantages:
[0085] 1. Effectively reduces the risk of chlorine leakage;
[0086] 2. Effectively reduce the risk of the entire kettle product being scrapped due to excessive chlorine;
[0087] 3. Effectively improve the effective chlorine content in the product and reduce the discharge of bleaching liquid (wastewater).
[0088] The present invention uses a convolutional neural network model to automatically capture the crystal features in the image and reclassify them, and manually adjusts the neural network hyperparameters and data processing mode to improve the model prediction accuracy;
[0089] The present invention predicts the current reaction stage and outputs process control parameters based on a newly input reaction picture. The process control parameters are further manually fine-tuned according to parameters such as reactor size, chlorine concentration, and lime milk quality, thereby realizing fully automated reaction control of bleaching powder production. BRIEF DESCRIPTION OF THE DRAWINGS
[0090] Attachment Figure 1 This is a process flow chart of the automated reaction control method for bleaching powder production based on a deep learning neural network of the present invention.
[0091] Attachment Figure 2 Schematic diagram of the system structure of the present invention. DETAILED DESCRIPTION
[0092] In order to make the objectives, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below with reference to the accompanying drawings. Obviously, the embodiments described are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.
[0093] Example 1
[0094] As attached Figure 1 As shown, this embodiment discloses a method for controlling the automated reaction of bleaching powder production based on a deep learning neural network, comprising the following steps:
[0095] S1. Data Collection: Acquire multiple microscopic images of the calcium bleaching powder chlorination unit at each reaction stage;
[0096] Adopt high-definition online microscopic observation technology, build the microscope probe into the reactor, or use automatic sampling microscopic observation technology to obtain real-time microscopic images of the reaction process;
[0097] In the first phase of the response, images were collected and uploaded to the server every 30 minutes;
[0098] In the second phase of the response, images were collected and uploaded to the server every 15 minutes;
[0099] In the third phase of the response, images are collected and uploaded to the server every 5 minutes.
[0100] The first stage of the reaction refers to the initial stage of the chlorination reaction, when chlorine gas is introduced into the lime milk. Calcium hydroxide (Ca(OH)2) reacts with chlorine (Cl2) to form calcium hypochlorite (Ca(ClO)2). The end of the first stage of the reaction is marked by the saturation of the calcium hypochlorite in the liquid phase and the precipitation of small regular hexagonal crystals of Ca(ClO)2·2Ca(OH)2.
[0101] After entering the second stage of the reaction, hexagonal Ca(ClO)2·2Ca(OH)2 crystals gradually increase and begin to grow. The end of the second stage is marked by the beginning of the fragmentation of large hexagonal crystals and the appearance of small needle-shaped crystals 3Ca(ClO)2·2Ca(OH)2·2H2O.
[0102] In the third stage of the reaction, the chlorine flow rate was further reduced to its lowest value. At this point, the hexagonal crystals gradually broke apart, while the small needle-like crystals of 3Ca(ClO)2·2Ca(OH)2·2H2O gradually grew. The end of the third stage of the reaction was marked by the near-complete disappearance of the regular hexagonal crystals and the appearance of large needle-like crystals under a microscope.
[0103] S2. Image Preprocessing: The collected microscopic images were manually classified and annotated into six reaction stages based on crystal morphology to form a labeled dataset; the details are shown in Table 1:
[0104] Table 1
[0105]
[0106] S3. Deep learning model training: The open source deep learning framework PyTorch is used for model training.
[0107] S31. Perform image enhancement and preprocessing on the labeled dataset: use the Transforms module to process and enhance the image, and the Dataset and DataLoader modules to load and batch process the image;
[0108] S32. Divide the preprocessed dataset into training, validation, and test sets in a ratio of 8:1:1.
[0109] S33. Build a convolutional neural network model or train it based on an open-source pre-trained model, construct training, evaluation, and validation functions, and record training loss, accuracy, and recall.
[0110] The convolutional neural network model includes ResNet and VGG architectures; preferably, it includes ResNet34, ResNet50, and VGG architectures.
[0111] The training mode is transfer learning. First, define the residual block:
[0112] y=F(x,{W i})+x
[0113] Among them, x is the input of the residual block of the previous neural network;
[0114] F(x,{W i}) is the residual mapping, that is, the neural network learning result; preferably, it is two 3x3 convolutional layers;
[0115] y is the input of the residual block;
[0116] Then the convolutional layer of each level of residual block adopts the ReLu activation formula:
[0117] z1=ReLU(BN(Conv3x3(x)))
[0118] z2=BN(Conv3x3(z1))
[0119] y=z2+x。
[0120] In some embodiments of the present invention, the formula for the accuracy in step S33 is:
[0121]
[0122] in,
[0123] TP (Ture Positives): Correctly predicted positive samples;
[0124] TN (Ture Negatives): Correctly predicted negative samples;
[0125] FP (False Positives): incorrectly predicted positive samples;
[0126] FN (False Negatives): incorrectly predicted negative samples;
[0127] The formula for training accuracy is:
[0128] Precision=TP / TP+FP
[0129] The formula for recall is:
[0130] Recall=TP / TP+FN
[0131] The formula for F1-Score is:
[0132] F1=2x Precision x Recall / Precision+Recall
[0133] The formula for training loss is:
[0134]
[0135] Where: N represents the number of samples; C represents the number of categories; j represents the sample index; ii represents the category index; y ji Represents the true probability value of the j-th sample in the i-th category; It represents the probability that the model predicts that the jth sample belongs to the i-th category.
[0136] S4. Model Validation and Debugging: Debug the model by analyzing the loss curve, accuracy curve, and confusion matrix. Improve the model's generalization ability through data augmentation, regularization, early stopping, or adjusting the learning rate.
[0137] S5. Model preservation and lightweighting: Convert the trained model to ONNX or TensorRT format and save it to the local server as a prediction model;
[0138] S6. Real-time prediction: Encapsulate the prediction model as an HTTP service using Flask or FastAPI, receive real-time image input from online microscopy observations, and output the corresponding reaction stage;
[0139] S7. Reaction process control: Based on the reaction stage output by the prediction model, the corresponding process control parameters are sent to the DCS system to achieve closed-loop automatic control of the reaction process.
[0140] The corresponding relationship between the reaction stages predicted by the prediction model and the process control parameters is shown in the following table:
[0141] Table 2
[0142] Predicting the reaction stage Stirring speed RPM <![CDATA[Chlorine gas flow rate m 3 / h]]> <![CDATA[Recirculating water flow rate m 3 / h]]> I R1 V1 M1 II R1 V1 M1 III R1 V2 M2 IV R2 V2 M2 V R2 V3 M3 VI R3 V4 M4
[0143] The process control parameters are further manually fine-tuned according to parameters such as reactor size, chlorine concentration, and lime milk quality to achieve fully automated reaction control for bleaching powder production.
[0144] Example 2
[0145] This embodiment discloses an automated reaction control system for bleaching powder production based on a deep learning neural network. The system includes a data acquisition module, an automated reaction stage judgment module, an automatic process control parameter optimization module, and a DCS control module, wherein:
[0146] The data acquisition module includes a high-definition microscope probe, which is built into the reactor or connected to the automatic sampling device to collect microscopic images of the reaction process in real time;
[0147] The automated reaction stage determination module utilizes an HTTP service interface built on a Flask or FastAPI framework, receiving real-time microscopic images and returning a predicted reaction stage. The module is configured with a real-time prediction model derived from steps S1 through S5 of the control method of Example 1. The module integrates an asynchronous task queue for parallel processing of multiple image prediction requests.
[0148] The process control parameter automatic optimization module outputs the process parameters to the DCS control module according to the reaction stage predicted by the reaction stage; the process control parameter automatic optimization module includes a manual adjustment function, which can realize manual fine-tuning of the process parameters.
[0149] The DCS control module is used to output process parameters to the distributed control system according to the predicted reaction stage to realize automatic control of the reaction process.
[0150] The present invention can upload real-time microscopic observation pictures of the chlorination reaction to a local server in real time; predict the current reaction stage based on the pictures and output process control parameters, thereby realizing fully automated reaction control of bleaching powder production.
[0151] The present invention predicts the current reaction stage and outputs process control parameters based on a newly input reaction picture. The process control parameters are further manually fine-tuned according to parameters such as reactor size, chlorine concentration, and lime milk quality, thereby realizing fully automated reaction control of bleaching powder production.
[0152] The above is only a preferred embodiment of the invention and does not impose any formal limitation on the invention. Based on the technical essence of the invention and within the spirit and principles of the invention, any simple modification, equivalent replacement and improvement of the above embodiment shall still fall within the scope of protection of the technical solution of the invention.
Claims
1. A method for controlling the automated reaction of bleaching powder production based on a deep learning neural network, characterized in that: The following steps are involved: S1. Data Collection: Acquire multiple microscopic images of the calcium bleaching powder chlorination unit at each reaction stage; S2. Image Preprocessing: Manually classify the collected microscopic images and annotate them into six reaction stages based on crystal morphology to form a labeled dataset. S3. Deep learning model training: S31. Performing image enhancement and preprocessing on the labeled dataset; S32. Divide the preprocessed dataset into a training set, a validation set, and a test set; S33. Build a convolutional neural network model or train it based on an open-source pre-trained model, construct training, evaluation, and validation functions, and record training loss, accuracy, and recall. S4. Model Validation and Debugging: Debug the model by analyzing the loss curve, accuracy curve, and confusion matrix. Improve the model's generalization ability through data augmentation, regularization, early stopping, or adjusting the learning rate. S5. Model preservation and lightweighting: Convert the trained model to ONNX or TensorRT format and save it to a local server as a prediction model. S6. Real-time prediction: The prediction model is encapsulated as an HTTP service, which receives real-time image input from online microscopy observations and outputs the corresponding reaction stage. S7. Reaction process control: Based on the reaction stage output by the prediction model, the corresponding process control parameters are sent to the DCS system to achieve closed-loop automatic control of the reaction process.
2. The control method according to claim 1, characterized in that: In step S1, a high-definition online microscopic observation technology is used, a microscope probe is built into the reactor, or an automatic sampling microscopic observation technology is used to obtain a microscopic picture of the reaction process in real time; Preferably, in the first reaction stage, a picture is collected and uploaded to the server every 30 minutes; in the second reaction stage, a picture is collected and uploaded to the server every 15 minutes; and in the third reaction stage, a picture is collected and uploaded to the server every 5 minutes.
3. The control method according to claim 1, characterized in that: In step S2, classification is performed based on the microscopic images collected based on the crystal morphology, as follows: The crystal morphology shown in the micrograph is small amorphous crystals, labeled as stage I; The crystal morphology shown in the micrograph is hexagonal crystals, labeled as stage II; The crystal morphology shown in the micrograph is broken hexagonal crystals, labeled as stage III; The crystal morphology shown in the micrograph is needle-shaped crystals accompanied by a large number of hexagonal broken crystals, marked as stage IV; The crystal morphology shown in the micrograph is needle-shaped, labeled as stage V; The crystal morphology shown in the micrograph is broken needle-like crystals, labeled as stage VI.
4. The control method according to claim 1, wherein: In step S31, the Transforms module is used to process and enhance the image, and the Dataset and DataLoader modules are used to load and batch process the images; In step S32, the ratio of the training set, validation set, and test set is 8:1:1; In step S33, the convolutional neural network model includes ResNet and VGG architectures; preferably, includes ResNet34, ResNet50, and VGG architectures; Preferably, the training mode of step S33 is transfer learning, and the residual block is first defined: y=F(x,{W i })+x Among them, x is the input of the residual block of the previous neural network; F(x,{W i }) is the residual mapping, that is, the neural network learning result; preferably, it is two 3x3 convolutional layers; y is the input of the residual block; Then the convolutional layer of each level of residual block adopts the ReLu activation formula: z1=ReLU(BN(Conv3x3(x))) z2=BN(Conv3x3(z1)) y=z2+x.
5. The control method according to claim 1, wherein: The formula for the accuracy in step S33 is: Accuracy=Number of Correct Predictions / Total Number of Predictions =TP+TN / TP+TN+FP+FN in, TP (Ture Positives): Correctly predicted positive samples; TN (Ture Negatives): Correctly predicted negative samples; FP (False Positives): incorrectly predicted positive samples; FN (False Negatives): incorrectly predicted negative samples; The formula for training accuracy is: Precision=TP / TP+FP The formula for recall is: Recall=TP / TP+FN The formula for F1-Score is: F1=2x Precision x Recall / Precision+Recall The formula for training loss is: Where: N represents the number of samples; C represents the number of categories; j represents the sample index; ii represents the category index; y ji Represents the true probability value of the j-th sample in the i-th category; It represents the probability that the model predicts that the jth sample belongs to the i-th category.
6. The control method according to claim 1, characterized in that: In step S6, the model is encapsulated as an HTTP service through Flask or FastAPI.
7. The control method according to claim 1, characterized in that: In step S7, the corresponding relationship between the reaction stage predicted by the prediction model and the process control parameters is as follows: Predict reaction stage I, stirring rate is R1 RPM, chlorine flow rate is V1m 3 / h, the circulating water flow rate is M1m 3 / h; Predicted reaction stage II, stirring rate is R1RPM, chlorine flow rate is V1m 3 / h, the circulating water flow rate is M1m 3 / h; Predict reaction stage III, stirring rate is R1 RPM, chlorine flow rate is V2m 3 / h, the circulating water flow rate is M2m 3 / h; Predict reaction stage IV, stirring rate is R2 RPM, chlorine flow rate is V2m 3 / h, the circulating water flow rate is M2m 3 / h; Predicted reaction stage V, stirring rate R2 RPM, chlorine flow rate V3m 3 / h, the circulating water flow rate is M3m 3 / h; Predicted reaction stage VI, stirring rate is R3 RPM, chlorine flow rate is V4m 3 / h, the circulating water flow rate is M4m 3 / h.
8. An automated reaction control system for bleaching powder production based on deep learning neural network, characterized in that: It includes data acquisition module, reaction stage automatic judgment module, process control parameter automatic optimization module and DCS control module, among which: The data acquisition module includes a high-definition microscope probe, which is built into the reactor or connected to the automatic sampling device to collect microscopic images of the reaction process in real time; The reaction stage automatic judgment module is an HTTP service interface built based on the Flask or FastAPI framework, which is used to receive real-time microscopic images and return the predicted reaction stage; the reaction stage automatic judgment module is configured with a real-time prediction model, which is obtained by steps S1 to S5 of the control method according to any one of claims 1 to 7; The process control parameter automatic optimization module outputs process parameters to the DCS control module based on the reaction stage predicted by the reaction stage; The DCS control module is used to output process parameters according to the predicted reaction stage to achieve automatic regulation of the reaction process.
9. The system according to claim 8, characterized in that The process control parameter automatic optimization module includes a manual adjustment function, which can realize manual fine-tuning of process parameters.
10. The system according to claim 8, wherein: The reaction phase automatic judgment module integrates an asynchronous task queue for processing multiple image prediction requests in parallel.
Citation Information
Cited By
Control method and system for synthesizing dihydrosphingosine based on catalytic hydrogenation
CN121070116A