Target element content measurement method, training method, related device and storage medium

The automatic extraction of metallographic image features through a deep regression network model solves the problems of low efficiency and low accuracy in measuring target element content in existing technologies that rely on sorbite identification, and achieves fast and accurate target element content measurement.

CN113781492BActive Publication Date: 2024-10-22ALIBABA GROUP HOLDING LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202010521698.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-06-10
Publication Date
2024-10-22
Estimated Expiration
2040-06-10

AI Technical Summary

Technical Problem

Existing target element content measurement methods rely on the accurate identification of sorbite structures, resulting in low accuracy and low efficiency of measurement results, and manual operations are labor-intensive and harmful to the eyes.

Method used

Using a deep regression network model, the metallographic image is cut into multiple image blocks and input into the trained deep regression network model, features are extracted and weighted, and the target element content measurement is automatically completed without the need to identify the target element organization in advance.

Benefits of technology

It achieves fast, accurate and stable measurement of target element content, reduces manual intervention, improves measurement efficiency and accuracy, and avoids damage to the eyes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113781492B_ABST
    Figure CN113781492B_ABST
Patent Text Reader

Abstract

A target element content measurement method, training method, related device and storage medium, wherein the target element content measurement method comprises: obtaining a metallographic image of a target object collected by a metallographic microscope; cutting the metallographic image into multiple image blocks according to a preset cutting size; inputting the multiple image blocks into a trained deep regression network model to extract the features of the multiple image blocks, and mapping the features of the multiple image blocks to a real number rating to obtain real number measurement results of the multiple image blocks; performing weighted processing on the real number measurement results of the multiple image blocks to obtain the target element content of the metallographic image. The target element content can be measured quickly and effectively using the method of the embodiment of this specification.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of this specification relate to the field of image processing technology, and in particular to a target element content measurement method, a training method, a related device and a storage medium. Background Art

[0002] Traditionally, the target element content measurement, such as the sorbite content measurement, is manually observed by naked eyes using a metallographic microscope, which is labor-intensive and inefficient. In addition, long-term use of the metallographic microscope is harmful to the eyes of the tester. In recent years, with the development of image processing technology, different image processing methods have been proposed, and corresponding software systems have been designed to realize the automatic recognition of sorbite structure, and on this basis, the sorbite content measurement is completed.

[0003] However, it is difficult for the existing grain boundary extraction method to perfectly identify the troostite structure, resulting in errors in the troostite content during the measurement process. Therefore, it is of great significance to find a fast and effective method for measuring the target element content so that the measurement results are not affected by the troostite structure recognition effect. Summary of the invention

[0004] In view of this, the embodiments of this specification provide a target element content measurement method, a training method, a related device and a storage medium, which can quickly and effectively measure the target element content.

[0005] First, the embodiment of this specification provides a method for measuring the content of a target element, including:

[0006] Acquire a metallographic image of a target object collected by a metallographic microscope;

[0007] Cutting the metallographic image into a plurality of image blocks according to a preset cutting size;

[0008] Inputting the plurality of image blocks into a trained deep regression network model to extract features of the plurality of image blocks, and mapping the features of the plurality of image blocks into a real number rating to obtain real number measurement results of the plurality of image blocks;

[0009] The real number measurement results of the multiple image blocks are weighted to obtain the target element content of the metallographic image.

[0010] Optionally, the deep regression network model includes: a preset convolutional neural network and a fully connected neural network, and the output end of the convolutional neural network is connected to the input end of the fully connected neural network.

[0011] Optionally, the convolutional neural network includes: a deep residual network;

[0012] Inputting the plurality of image blocks into a trained deep regression network model to extract features of the plurality of image blocks, and mapping the features of the plurality of image blocks into a real number rating to obtain real number measurement results of the plurality of image blocks, comprises:

[0013] Inputting the multiple image blocks into the deep residual network, extracting features of each image block, and obtaining features as real number vectors of preset dimensions;

[0014] The real number vector is output to the fully connected neural network, the feature of each image block is mapped to a real number rating, and the real number measurement results of the multiple image blocks are obtained.

[0015] Optionally, the deep residual network includes any one of the following:

[0016] The 50-layer residual network ResNet50 and the 101-layer residual network ResNet101.

[0017] Optionally, the activation functions of the deep residual network and the fully connected neural network include:

[0018] f(x)=max(x,0);

[0019] Among them, x represents the input variable of the neuron, and f(x) represents the value mapped by the output of the neuron.

[0020] Optionally, performing weighted processing on the real number measurement results of the plurality of image blocks to obtain the target element content of the metallographic image includes:

[0021] An average value is calculated for the real number measurement results of the plurality of image blocks, and the average value is converted into a percentage to obtain the target element content of the metallographic image.

[0022] Optionally, the deep regression network model is trained using the following method:

[0023] Acquire a metallographic image of a target object to be trained;

[0024] Cutting the metallographic image according to the preset cutting size to obtain a plurality of image blocks as image blocks to be trained;

[0025] Obtain manual measurement results of target element contents corresponding to the multiple image blocks to be trained, input the manual measurement results of target element contents corresponding to the multiple image blocks to be trained into the deep regression network model, and input the image blocks to be trained into the deep regression network model for training using a preset training method until the deep regression network model reaches a preset stability performance indicator.

[0026] Optionally, the loss function of the deep regression network model includes:

[0027]

[0028] Wherein, P represents the manually determined target element content measurement result of the image block of the preset cutting size, represents the target element content of the metallographic image output during the training process of the deep regression network model, and e is a very small constant greater than 0.

[0029] Optionally, the adopting a preset training method to input the image block to be trained into the deep regression network model for training until the deep regression network model reaches a preset stability performance index includes:

[0030] Adaptive moment estimation method is used and the learning rate is set to 10 -3 , so that the output value of the loss function of the deep regression network converges to a preset threshold.

[0031] Optionally, the method further comprises:

[0032] Before inputting the image block to be trained into the deep regression network model for training, preprocessing the manual measurement results of the target element content corresponding to the image block to be trained;

[0033] Before weighting the real number measurement results of the plurality of image blocks, post-processing is performed on the real number measurement results of the plurality of image blocks.

[0034] Optionally, the preprocessing of the manual measurement result of the target element content corresponding to the image block to be trained includes: performing a logarithmic transformation on the manual measurement result of the target element content corresponding to the image block to be trained;

[0035] The real number measurement results of the multiple image blocks are post-processed before the real number measurement results of the multiple image blocks are weighted, including: performing exponential transformation on the real number measurement results of the multiple image blocks.

[0036] Optionally, the cutting of the metallographic image according to the preset cutting size to obtain a plurality of image blocks, as image blocks to be trained, includes at least one of the following:

[0037] Extracting image blocks with a size of the preset cutting size from the metallographic image from top to bottom and from left to right according to a preset step length as the image blocks to be trained;

[0038] Processing the metallographic image by upsampling and downsampling, and cutting the metallographic image obtained after sampling according to the preset cutting size to obtain the image block to be trained;

[0039] The metallographic image is subjected to image enhancement processing, and the enhanced metallographic image is cut according to the preset cutting size to obtain the image block to be trained.

[0040] The embodiment of this specification also provides a training method for a deep regression network model suitable for measuring target element content, including:

[0041] Acquire a metallographic image of a target object to be trained;

[0042] Cutting the metallographic image into a plurality of image blocks according to a preset cutting size as image blocks to be trained;

[0043] Obtain manual measurement results of target element contents corresponding to the multiple image blocks to be trained, input the manual measurement results of target element contents corresponding to the multiple image blocks to be trained into the deep regression network model, and input the image blocks to be trained into the deep regression network model for training using a preset training method until the deep regression network model reaches a preset stability performance indicator.

[0044] Optionally, the deep regression network model includes: a preset deep residual network and a fully connected neural network, and the output end of the deep residual network is connected to the input end of the fully connected neural network.

[0045] The step of using a preset training method to input the image block to be trained into the deep regression network model for training includes:

[0046] Inputting the plurality of image blocks to be trained into the deep residual network, extracting features of each of the image blocks to be trained, and obtaining features as real number vectors of preset dimensions;

[0047] The real number vector is output to the fully connected neural network, the feature of each image block to be trained is mapped to a real number rating, and the real number measurement results of the multiple image blocks to be trained are obtained.

[0048] Optionally, the loss function of the deep regression network model includes:

[0049]

[0050] Wherein, P represents the manually determined target element content measurement result of the image block of the preset cutting size, represents the target element content of the metallographic image output during the training process of the deep regression network model, and e is a very small constant greater than 0.

[0051] Optionally, the adopting a preset training method to input the image block to be trained into the deep regression network model for training until the deep regression network model reaches a preset stability performance index includes:

[0052] The real number measurement results of the plurality of image blocks to be trained and the corresponding manual measurement results of the target element content are respectively input into a preset network loss function until the output value of the loss function converges to a preset threshold.

[0053] Optionally, the adopting a preset training method to input the image block to be trained into the deep regression network model for training until the deep regression network model reaches a preset stability performance index includes:

[0054] Adaptive moment estimation method is used and the learning rate is set to 10 -3 , so that the loss function of the deep regression network gradually converges to a preset stable state indicator.

[0055] Optionally, before inputting the image block to be trained into the deep regression network model for training, the method further includes: preprocessing the manual measurement result of the target element content corresponding to the image block to be trained.

[0056] Optionally, the preprocessing of the manual measurement result of the target element content corresponding to the image block to be trained includes: performing a logarithmic transformation on the manual measurement result of the target element content corresponding to the image block to be trained.

[0057] Optionally, the cutting of the metallographic image into a plurality of image blocks according to a preset cutting size as the image blocks to be trained comprises at least one of the following:

[0058] Extracting image blocks with a size of the preset cutting size from the metallographic image from top to bottom and from left to right according to a preset step length as the image blocks to be trained;

[0059] Processing the metallographic image by upsampling and downsampling, and cutting the metallographic image obtained after sampling according to the preset cutting size to obtain the image block to be trained;

[0060] The metallographic image is subjected to image enhancement processing, and the enhanced metallographic image is cut according to the preset cutting size to obtain the image block to be trained.

[0061] The present specification also provides a method for measuring the content of a target element, including:

[0062] Get the target object;

[0063] Preprocessing the target object;

[0064] Place the pre-treated target object under a metallographic microscope;

[0065] Automatically take metallographic images of target objects collected by metallographic microscope;

[0066] The target element content measurement method described in any of the above embodiments is used to perform measurement to obtain the target element content of the metallographic image of the target object.

[0067] The embodiment of this specification also provides a target element content measurement device, including:

[0068] A metallographic image acquisition unit, adapted to acquire a metallographic image of a target object acquired by a metallographic microscope;

[0069] An image cutting unit, adapted to cut the metallographic image into a plurality of image blocks according to a preset cutting size;

[0070] The measuring unit is adapted to input the plurality of image blocks into a trained deep regression network model to extract features of the plurality of image blocks, map the features of the plurality of image blocks into a real number rating, obtain real number measurement results of the plurality of image blocks, and perform weighted processing on the real number measurement results of the plurality of image blocks to obtain the target element content of the metallographic image.

[0071] Optionally, the deep regression network model includes: a preset convolutional neural network and a fully connected neural network, and the output end of the convolutional neural network is connected to the input end of the fully connected neural network.

[0072] Optionally, the convolutional neural network includes: a deep residual network, and the activation functions of the deep residual network and the fully connected neural network are nonlinear activation functions;

[0073] The measurement unit is suitable for inputting the multiple image blocks into the deep residual network, extracting features of each image block, obtaining a real number vector with a preset dimension as the feature, and outputting the real number vector to the fully connected neural network, mapping the features of each image block into a real number rating, and obtaining real number measurement results of the multiple image blocks.

[0074] Optionally, the measuring unit is adapted to perform exponential transformation on the real number measurement results of the multiple image blocks, and average the real number measurement results after the exponential transformation, and convert the average value obtained into a percentage to obtain the target element content of the metallographic image.

[0075] The embodiment of this specification also provides a training device for a deep regression network model suitable for measuring target element content, including:

[0076] A metallographic image acquisition unit, adapted to acquire a metallographic image of a target object to be trained;

[0077] An image cutting unit, adapted to cut the metallographic image into a plurality of image blocks according to a preset cutting size as image blocks to be trained;

[0078] A training unit is adapted to obtain manual measurement results of target element contents corresponding to the multiple image blocks to be trained, and input the manual measurement results of target element contents corresponding to the multiple image blocks to be trained into the deep regression network model, and input the image blocks to be trained into the deep regression network model for training using a preset training method until the deep regression network model reaches a preset stability performance index.

[0079] Optionally, the deep regression network model includes:

[0080] A preset deep residual network and a fully connected neural network, wherein the output end of the deep residual network is connected to the input end of the fully connected neural network, and the activation functions of the deep residual network and the fully connected neural network are nonlinear activation functions.

[0081] Optionally, the training unit is suitable for inputting the multiple image blocks to be trained into the deep residual network, extracting features of each of the image blocks to be trained, and obtaining a real number vector with features of a preset dimension; and outputting the real number vector to the fully connected neural network, mapping the features of each of the image blocks to be trained into a real number rating, and obtaining real number measurement results of the multiple image blocks to be trained.

[0082] Optionally, the loss function of the deep regression network model includes:

[0083]

[0084] Wherein, P represents the manually determined target element content measurement result of the image block of the preset cutting size, represents the target element content of the metallographic image output during the training process of the deep regression network model, and e is a very small constant greater than 0.

[0085] Optionally, the training unit is suitable for obtaining artificial measurement results of target element contents corresponding to the multiple image blocks to be trained, and inputting the real number measurement results of the multiple image blocks to be trained and the corresponding artificial measurement results of target element contents into a preset network loss function respectively until the output value of the loss function converges to a preset threshold.

[0086] Optionally, the training unit is adapted to perform logarithmic transformation on the manual measurement results of the target elements of the multiple image blocks to be trained and then input them into the deep regression network model for training.

[0087] The embodiment of this specification also provides a target element content measurement system, including:

[0088] A sample acquisition device, adapted to acquire a target object;

[0089] A preprocessing device, adapted to preprocess the target object;

[0090] A metallographic image shooting device, adapted to automatically shoot a metallographic image of the target object acquired by a metallographic microscope after the pre-processed target object is placed under a microscope;

[0091] And the target element content measuring device described in any of the aforementioned embodiments.

[0092] An embodiment of the present specification also provides an electronic device, including a memory and a processor, wherein the memory stores computer instructions that can be executed on the processor, and when the processor executes the computer instructions, the steps of the method described in any of the above embodiments are executed.

[0093] The embodiments of the present specification also provide a computer-readable storage medium on which computer instructions are stored. When the computer instructions are executed, the steps of the method described in any of the above embodiments are executed.

[0094] Compared with the prior art, the technical solution of the embodiment of this specification has the following beneficial effects:

[0095] On the one hand, the target element content measurement scheme of the embodiment of the present specification is adopted, by cutting the metallographic image of the target object into multiple image blocks according to a preset cutting size, and inputting them into a trained deep regression network to automatically extract the features of the multiple image blocks, mapping the features of the multiple image blocks into a real number classification, and obtaining the real number measurement results of the multiple image blocks. Thereafter, the real number measurement results of the multiple image blocks are weighted to obtain the target element content of the metallographic image. This target element content measurement scheme does not require pre-identification of the target element organization in the metallographic image. The entire measurement process is automatically completed based on the trained deep regression network, without manual measurement, and the measurement accuracy does not depend on the recognition accuracy of the target element content, thereby ensuring the stability of the measurement results and being able to efficiently, stably and accurately measure the target element content in the target object.

[0096] On the other hand, by adopting the training scheme in the embodiment of the present specification, the deep regression network model is trained by obtaining the manual measurement results of the target element content corresponding to multiple image blocks to be trained of the target object, and combining the manual measurement results of the target element content corresponding to the multiple image blocks to be trained until the deep regression network model reaches a preset stability performance index, so that the trained deep regression network model can be used for automatic measurement of the target element content in the target object, and the measurement using the deep regression network model does not require pre-identification of the target element organization in the target object to be measured, thereby ensuring the accuracy and stability of the measurement results, and the deep regression network model can be used to achieve automatic measurement, therefore, the deep regression network model trained using the training method in the embodiment of the present specification is used for the measurement of the target element content in the target object, and the target element content in the target object can be measured quickly and effectively. BRIEF DESCRIPTION OF THE DRAWINGS

[0097] Figure 1 This is a flowchart of a target element content measurement process in an embodiment of this specification;

[0098] Figure 2 is a flow chart of a method for measuring the content of a target element in an embodiment of this specification;

[0099] Figure 3 It is a schematic diagram of a residual structure principle in an embodiment of this specification;

[0100] Figure 4 This is a specific application schematic diagram of a target element content measurement system in an embodiment of this specification;

[0101] Figure 5 It is a schematic diagram of the structure of a deep residual network in an embodiment of this specification;

[0102] Figure 6 It is a schematic diagram of the structure of a fully connected neural network in an embodiment of this specification.

[0103] Figure 7 is a flow chart of a training method in an embodiment of this specification;

[0104] Figure 8 It is a structural schematic diagram of a target element content measuring device in an embodiment of this specification;

[0105] Fig. 9 It is a structural schematic diagram of a training device in an embodiment of this specification;

[0106] Fig.10 It is a structural schematic diagram of a target element content measurement system in an embodiment of this specification;

[0107] Fig.11 It is a structural schematic diagram of an electronic device in an embodiment of this specification. DETAILED DESCRIPTION

[0108] Wire rod, also called wire rod, usually refers to small diameter round steel in coils. There are many types of wire rods, among which low carbon steel wire rods in carbon steel wire rods are commonly known as soft wires, and medium and high carbon steel wire rods are commonly known as hard wires. After drawing, high carbon steel wire rods are widely used in high-rise buildings, bridges, petrochemicals, railways and other engineering fields. Sorbite is the matrix structure of high carbon steel wire rods. The main factor affecting the drawing performance and mechanical properties of high carbon steel wire rods is the sorbite content. The higher and more uniform the sorbite content, the better the drawing performance. With the substantial increase in the output of high carbon steel wire rods and the wide application of its products, manufacturers and product industries are also paying more and more attention to its sorbite content index.

[0109] At present, according to the promulgated standard document of the ferrous metallurgy industry of the People's Republic of China, "Metallographic Detection Method of Sorbite Content in High Carbon Steel Wire Rod", the process of measuring sorbite can be divided into four steps: standard sample selection, polishing and corrosion of standard sample and sample to be measured, calibration of test conditions and testing of sample to be tested. Among them, how to accurately identify the sorbite structure from the microscope image in the testing of the sample to be tested directly affects the measurement accuracy of the sorbite content.

[0110] In the past, inspection was usually done manually, using a metallographic microscope to observe with the naked eye. Although this method is highly accurate, it is labor-intensive and inefficient. In addition, long-term use of a metallographic microscope can cause significant damage to the tester's eyes.

[0111] In recent years, with the development of image processing technology, people have proposed a variety of image processing methods and designed corresponding software systems to realize the automatic identification of troostite structure and complete the measurement of troostite content on this basis. For example, the metallographic image is opened by image processing software, and the auxiliary lines of the image processing software are used to manually calculate the amount of troostite structure, and on this basis, the troostite content value of the cross section of the wire rod in the entire metallographic image is obtained. For another example, a simple threshold segmentation method is used to identify the troostite structure in the metallographic image, and then the troostite content is calculated, in which the threshold parameter needs to be given manually.

[0112] The existing method for measuring the troostite content relies on the accuracy of troostite tissue identification. On the one hand, due to the influence of image noise, it is difficult to accurately identify all troostite tissues for different images, resulting in poor stability and low accuracy of troostite content measurement precision. On the other hand, the existing method needs to further calculate the troostite content based on the identification of the troostite tissue, and the tissue identification calculation is very time-consuming, so the troostite measurement speed is very slow.

[0113] Therefore, how to find a fast and effective method to measure the target element content in the target object so that the measurement result is not affected by the target element tissue recognition effect is of great significance.

[0114] To this end, an embodiment of the present specification provides a target element content measurement method based on a deep regression network. By using the target element content measurement method of the embodiment of the present specification, there is no need to accurately identify the target element organization, and the target element content in the target object can be automatically measured. It also has strong anti-noise ability and can ensure the stability of the target element content measurement accuracy.

[0115] In order to enable those skilled in the art to more clearly understand and implement the embodiments of this specification, the technical solutions in the embodiments of this specification will be clearly and completely described below in conjunction with the drawings in the embodiments of this specification. Obviously, the described embodiments are part of the embodiments of this specification, not all of the embodiments. Based on the embodiments in this specification, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of this specification.

[0116] Reference Figure 1 The target element content measurement flow chart shown in the figure is used as an example to illustrate the measurement of the troostite content in a high carbon steel wire rod sample in order to enable those skilled in the art to better understand and implement the embodiments of this specification. The execution flow includes the following steps:

[0117] S11, obtaining a target object.

[0118] A high carbon steel wire rod sample was obtained as the target object.

[0119] S12, preprocessing the target object.

[0120] For example, the high carbon steel wire rod sample may be pre-treated, for example, the sample may be inlaid, ground, and polished to obtain a metallographic surface, and then may be etched with a nitric acid alcohol solution and then blown dry.

[0121] S13, metallographic microscope observation.

[0122] After pretreatment, the high carbon steel wire rod sample can be placed under a metallographic microscope.

[0123] S14, automatically taking metallographic images.

[0124] In a specific implementation, a monitoring point can be determined on the wire rod cross-section sample, and several viewing fields with a magnification of 500 times can be continuously selected at the monitoring point to take metallographic images. To improve the test efficiency, the metallographic image of the high carbon steel wire rod sample collected by the metallographic microscope can be automatically obtained by an automatic shooting device.

[0125] S15, target element content measurement.

[0126] Among them, in the process of measuring the target element content in step S15, a deep regression network model can be used for measurement. In order to achieve fast and accurate measurement of the target element content, the deep regression network model can be trained in advance. After the training is completed, the trained deep regression network model can be used to measure the target element content.

[0127] In order to enable those skilled in the art to better understand and implement, the following describes in detail the target element content measurement process in the target object and the training process of the deep regression network model.

[0128] First, the measurement process of the target element content in the target object is introduced. The measurement process of the target element content can be understood as the use process of the deep regression network model, that is, the trained deep regression network model is used to calculate the metallographic image of the target element content to be measured, and the target element content in the metallographic image is obtained.

[0129] Reference Figure 2 The flowchart of the target element content measurement method shown in the embodiment of this specification may specifically include the following steps:

[0130] S21, obtaining a metallographic image of the target object collected by a metallographic microscope.

[0131] The high carbon steel wire rod sample is still used as the target object for example description. In a specific implementation, the high carbon steel wire rod sample can be placed under a metallographic microscope, and a metallographic image of the high carbon steel wire rod sample presented under the metallographic microscope can be taken. In some embodiments of the present specification, a monitoring point can be determined on the wire rod cross-section sample, and several fields of view with a magnification of 500 times can be continuously selected at the monitoring point to take a metallographic image. In order to improve the test efficiency, the metallographic image of the high carbon steel wire rod sample collected by the metallographic microscope can be automatically acquired by an automatic shooting device.

[0132] In addition, before placing the target object under the metallographic microscope, the intercepted target object, such as a high-carbon steel wire rod sample, can be pre-processed first. For example, the sample can be inlaid, ground, and polished to obtain a metallographic surface, and then etched with nitric acid alcohol solution and blown dry.

[0133] In a specific implementation, the metallographic microscope may be an optical metallographic microscope or other types of metallographic microscopes.

[0134] S22, cutting the metallographic image into a plurality of image blocks according to a preset cutting size.

[0135] In a specific implementation, the cutting size of the metallographic image can be preset according to the size of the texture of the target element in the metallographic image. The preset cutting size is set according to the distance of the target object from the metallographic microscope, the magnification of the metallographic microscope, etc.

[0136] In some embodiments of the present specification, for the troostite metallographic image, the cutting size is preset to 384×384 pixels.

[0137] S23, inputting the multiple image blocks into a trained deep regression network model to extract features of the multiple image blocks, and mapping the features of the multiple image blocks into a real number rating to obtain real number measurement results of the multiple image blocks.

[0138] In some embodiments of the present specification, the deep regression network model includes: a preset convolutional neural network and a fully connected neural network, and the output end of the convolutional neural network is connected to the input end of the fully connected neural network.

[0139] In a specific implementation, the activation functions of the convolutional neural network and the fully connected neural network may adopt a nonlinear activation function. In some embodiments of the present specification, the activation functions of the convolutional neural network and the fully connected neural network select the ReLU activation function. ReLU, i.e., the rectified linear unit (Rectified Linear Unit), can activate some neurons and increase sparsity. When x < 0, the output value is 0; when x > 0, the output value is x, which can be expressed as:

[0140] f(x)=max(x,0);

[0141] Among them, x represents the input variable of the neuron, and f(x) represents the value mapped by the output of the neuron.

[0142] In step S23, the multiple image blocks can be first input into a preset convolutional neural network to extract features of each image block to obtain a real number vector with features of a preset dimension. Thereafter, the real number vector can be output to the fully connected neural network to map the features of each image block to a real number rating to obtain real number measurement results of the multiple image blocks.

[0143] In a specific implementation, the activation function of the fully connected neural network can adopt a nonlinear activation function.

[0144] S24, performing weighted processing on the real number measurement results of the plurality of image blocks to obtain the target element content of the metallographic image.

[0145] By adopting the method for measuring the troostite content of the above-mentioned embodiment, there is no need to pre-identify the troostite structure in the metallographic image. The entire measurement process is automatically completed based on the trained deep regression network, and no manual measurement is required. The measurement accuracy does not depend on the recognition accuracy of the troostite content, thereby ensuring the stability of the measurement results and being able to measure the troostite content efficiently, stably and accurately.

[0146] To facilitate understanding and implementation, some specific convolutional neural networks applicable to the embodiments of this specification are given below, for example, AlexNet, VGG, Inception, Deep Residual Network (ResNet) and other networks can be used.

[0147] Among them, AlexNet deepens the network structure based on LeNet and can learn richer and higher-dimensional image features.

[0148] VGG has two network structures with different depths: VGG16 and VGG19. The entire VGGNet network uses the same convolution kernel size (3×3) and maximum pooling size (2×2).

[0149] Inception, also known as GoogLeNet, the entire Inception structure is composed of multiple Inception modules connected in series. It can use 1×1 convolution for dimensionality reduction and can perform convolution and re-aggregation at multiple sizes at the same time. By using 1×1 convolution to increase and decrease dimensions, more convolutions can be superimposed in the receptive field of the same size, richer features can be extracted, and using 1×1 convolution for dimensionality reduction can reduce computational complexity. Simultaneous convolution at multiple sizes can extract size features of different scales. Richer features mean that the real number classification obtained by subsequent mapping is more accurate, and the decomposition of sparse matrices into dense matrices can speed up convergence. In addition, aggregating highly correlated features in advance can also help accelerate convergence.

[0150] The structure of ResNet is a residual structure, such as Figure 3 The schematic diagram of the residual structure principle shown is expressed by the formula:

[0151] y=F(x)+x;

[0152] Among them, x represents the input of ResNet and y represents the output of ResNet.

[0153] The residual structure of ResNet contains two types of mapping, one is identity mapping (Identity Mapping) and the other is residual mapping (Residual Mapping). The identity mapping refers to itself, that is, x in the formula, and the residual mapping refers to the "difference", that is, yx, which is the F(x) part in the formula.

[0154] In response to the phenomenon that the accuracy of the training set decreases as the network deepens, ResNet provides two options, namely identity mapping and residual mapping. If the network has reached the optimal state, continuing to deepen the network will approach 0, leaving only the identity mapping. In this way, the network is theoretically always in the optimal state, and the network performance will not decrease with increasing depth.

[0155] It is understandable that the above are only some specific examples of convolutional neural networks that can be used, and are not intended to limit the types of convolutional neural networks to which the embodiments of this specification are applicable.

[0156] In addition, two or more convolutional neural networks can also be used in combination, for example, the Inception structure and the ResNet structure can be mixed to form an Inception-ResNet structure. In a specific implementation, the Inception-ResNet structure can be specifically combined in a variety of ways, and the specific structure finally used for the measurement of the troostite content can be selected according to the actual training effect.

[0157] In order to enable those skilled in the art to better understand and implement how to use a deep regression network model to achieve the measurement of the troostite content that is independent of troostite recognition, the following uses a deep residual network and a fully connected neural network in a deep regression network model as an example, and explains in detail through the implementation of a specific application scenario.

[0158] Reference Figure 4 The specific application diagram of the target element content measurement system shown in the figure can be used to measure the troostite content in the following steps:

[0159] S41, cutting the input metallographic image into image blocks of a preset cutting size.

[0160] As a specific example, for the obtained metallographic image of the high carbon steel wire rod sample, the metallographic image can be cut into n image blocks with a cutting size of 384×384 pixels from top to bottom and from left to right.

[0161] S42, input the cut image blocks with a size of 384×384 pixels into the trained deep regression network model to obtain real number measurement results of each image block.

[0162] Continuing with the above specific example, each image block of size 384×384 pixels is input into the deep residual network, and the features of the n image blocks are extracted to obtain a real number vector with a preset dimension. In a specific implementation, the preset dimension can be equal to the number of image blocks obtained by cutting a metallographic image. After that, the real number vector can be output to a fully connected neural network, and the features of each image block are mapped to a real number rating, and the real number measurement results of the n image blocks are obtained, which can be recorded as:

[0163] p i ,i=1,2,3,…,n。

[0164] In order to further improve the measurement accuracy, the artificial measurement results of the target element content corresponding to the training image block can be preprocessed during the training phase, and the real number measurement results of the image block can be post-processed accordingly during the target element content measurement phase. As an optional example, the artificial measurement results of the target element content corresponding to the training image block can be logarithmically transformed, for example, a logarithmic transformation with base 10. Accordingly, the deep regression network model trained with the artificial measurement results of the target element content corresponding to the preprocessed image block to be trained is used, and the real number measurement results of each image block output are the logarithmic form of the true measurement results of each image block. For ease of understanding, suppose the real number measurement result of the image block is p, then the real number measurement result of the image block output here is the logarithmic form of p, such as Figure 4 As shown, after being processed by the deep regression network model, a real number measurement result lgp in the form of a logarithm with a base of 10 is obtained. Therefore, a corresponding exponential transformation is performed on the real number measurement result of each image block, for example, an exponential transformation with a base of 10 is performed accordingly to obtain a real number measurement result of each image block that can be expressed as a percentage. It can be understood that in a specific implementation, the logarithmic transformation in the preprocessing process and the exponential transformation in the postprocessing process can also take other bases, such as e as the base, 2 as the base, etc. The embodiments of this specification do not impose any limitation on the base taken, and the specific value can be selected according to the verification results of the experimental data.

[0165] S43, calculating an average value of the real number measurement results of each image block, converting the average value obtained into a percentage, and obtaining the percentage of the troostite content in the metallographic image.

[0166] Continuing with the above specific example, the percentage of troostite content G can be expressed as follows:

[0167]

[0168] In one embodiment of the present specification, a 50-layer deep residual network ResNet50 is used.

[0169] Reference Figure 5 The network structure diagram of the deep residual network ResNet50 shown in the figure is a residual network with 50 layers, among which there are no layers that need to train parameters, such as the pooling layer, which is not included in the counting. ResNet50 consists of 5 parts, namely: stage1 to stage5, which can also be called 5 convolution stages with different parameters. Among them:

[0170] Stage 1 includes: 64 7×7 convolution kernels, stride 2, and 0 padding to increase the dimension to 3 (7×7conv, 64, stride 2, pad3); batch normalization and activation function ReLU (BatchNormalization+ReLU) are applied on the channel axis of the input; and a 3×3 maximum pooling layer with a stride of 2 (3×3max pooling, stride 2).

[0171] Stage 2 includes: three-layer bottleneck structure units: It contains a bottleneck block and two identity blocks.

[0172] In stage 3, 4, and 5, there are also multiple three-layer bottleneck structural units. Each part may include a bottleneck block and m-1 identity blocks. The specific structure of each bottleneck block and identity block is as follows: Figure 5 Specific parameters in the deep residual network, such as d1, d2, d3, n1, n2, n3, m, etc., can be determined according to the simulation experiment results in the specific implementation.

[0173] Depend on Figure 5 It can be seen that in one embodiment of the present specification, after the image block with a size of 384×384 pixels is cut and input into the deep residual network ResNet50, after Stage 1, a feature map with a size of 96×96×64 can be extracted, and then after stage 2, a feature map with a size of 96×96×256 can be output, and after stage 3, a feature map with a size of 48×48×512 can be output, and after stage 4, a feature map with a size of 24×24×1024 can be output, and then after stage 5, a feature map with a size of 12×12×2048 can be output, and finally after the global average pooling layer (GlobalAveragePooling), a feature map with a size of 1×1×2048 can be output.

[0174] Continue to refer to Figure 6The schematic diagram of the fully connected neural network structure shown in the figure, the 1×1×2048 feature map output by the deep residual network can be converted into a 2048×1 feature vector and input into the fully connected neural network, which can output the network classification result p of each image block. i , which is the real number measurement result of each image block.

[0175] As a specific example, the activation functions of the deep residual network ResNet50 and the fully connected neural network are both ReLU functions. Using ReLU function as the activation function can make the extracted features richer than the linear function. For the non-linear function, since the gradient in the non-negative interval is a constant, there is no problem of gradient disappearance, so that the convergence speed of the deep regression network model is maintained in a stable state.

[0176] In a specific implementation, other activation functions may also be used, such as ELU function, Leaky ReLU, etc.

[0177] The above describes in detail the specific method of applying the deep residual network ResNet50 to the measurement of the troostite content. In the specific implementation, other deep ResNets can also be used, for example, ResNet101. The embodiments of this specification do not impose any restrictions on the level of the deep residual network.

[0178] In order to enable those skilled in the art to better understand and implement the embodiments of this specification, the training process of the deep regression network model in the embodiments of this specification is described in detail below.

[0179] Reference Figure 7 The training method flow chart of the deep regression network model shown in the figure, the training process may specifically include the following steps:

[0180] S71, obtaining a metallographic image of the target object to be trained.

[0181] Still taking the high carbon steel wire rod as the target object for example, in a specific implementation, the metallographic image of the high carbon steel wire rod sample can be collected by a metallographic microscope, and the specific method can refer to the description of step S21 in the above embodiment.

[0182] S72, cutting the metallographic image according to the preset cutting size to obtain a plurality of image blocks as image blocks to be trained.

[0183] First, in order to enable the deep regression network model to complete effective training through learning with a small number of images, the metallographic image is divided into blocks before training. The specific cutting method can refer to step S22 in the previous embodiment and will not be described in detail here.

[0184] Furthermore, when the training samples are limited, the training sample data can be constructed based on the samples, so that the deep regression network model can be effectively trained and learned even when the samples are few. Specifically, the training sample data can be constructed in a variety of ways. The following are some feasible examples. Specifically, one or more of these ways can be used to obtain the image blocks to be trained:

[0185] Example 1: Extracting image blocks with a size of the preset cutting size from the metallographic image from top to bottom and from left to right according to a preset step size as the image blocks to be trained.

[0186] Example 2: The metallographic image is processed by up-sampling and down-sampling, and the metallographic image obtained after sampling is cut according to the preset cutting size to obtain the image block to be trained.

[0187] Example 3: Performing image enhancement processing on the metallographic image, and cutting the enhanced metallographic image according to the preset cutting size to obtain the image block to be trained

[0188] Targeted emphasis on the overall or local features of the image can make the originally unclear image clear or emphasize certain features of interest, expand the differences between the features of different objects in the image, and suppress features of no interest, which can improve image quality, enrich the amount of information, and enhance image interpretation and recognition effects.

[0189] In a specific implementation, the image enhancement may be performed by a frequency domain method such as a low-pass filter or a high-pass filter, or by a spatial domain method such as a local averaging method or a median filter.

[0190] The noise in the image can be removed or reduced by low-pass filtering, local averaging or median filtering, while high-pass filtering can enhance high-frequency signals such as edges to make blurred images clearer.

[0191] S73, obtaining manual measurement results of the target element contents corresponding to the multiple image blocks to be trained, inputting the manual measurement results of the target element contents corresponding to the multiple image blocks to be trained into the deep regression network model, and using a preset training method to input the image blocks to be trained into the deep regression network model for training until the deep regression network model reaches a preset stability performance indicator.

[0192] In a specific implementation, the deep regression network model may include: a preset convolutional neural network and a fully connected neural network, and the output end of the deep residual network is connected to the input end of the fully connected neural network.

[0193] The following uses the deep residual network of the convolutional neural network as an example to illustrate the entire training process:

[0194] The multiple image blocks to be trained can be input into the deep residual network, and the features of each image block to be trained can be extracted to obtain a real number vector whose features are preset dimensions. After that, the real number vector is output to the fully connected neural network, and the features of each image block to be trained are mapped to a real number rating to obtain real number measurement results of the multiple image blocks to be trained.

[0195] For an image block with a size of 384×384, the average diameter of the grains in the image is between 1 and 384. Based on this, in some embodiments of the present specification, setting the loss function of the deep regression network model includes:

[0196]

[0197] Wherein, P represents the manually determined measurement result of the troostite content of the image block of the preset cutting size, represents the troostite content of the metallographic image output during the training process of the deep regression network model, and e is a very small constant greater than 0.

[0198] For the above loss function, when P = 0, lg(P + e) ​​= lge. If e = 0, the logarithmic function is meaningless. To prevent this from happening, e is a very small constant greater than 0. In one embodiment of this specification, e = 10 -6 .

[0199] In a specific implementation, the real number measurement results of the multiple image blocks to be trained and the corresponding manual measurement results of the target element content are respectively input into a preset network loss function until the output value of the loss function converges to a preset threshold, and it is determined that the training is completed.

[0200] In the specific implementation, in order to efficiently minimize the network loss function and complete the training as quickly as possible, some training methods that can automatically optimize the learning rate can be used. For example, batch gradient descent (BGD), stochastic gradient descent (SGD), momentum, AdaGrad, adaptive moment estimation (Adam), etc. can be used.

[0201] In one embodiment of this specification, the Adam method is used and the learning rate is set to 10 -3 After about 100 rounds of training, the loss function of the deep regression network gradually converges to a preset stable state indicator, and it is determined that the training is completed and can be put into use.

[0202] The embodiments of this specification also provide corresponding troostite content measuring devices, measuring systems and training devices, which are described below through specific embodiments.

[0203] In some embodiments of this specification, Figure 8 The target element content measuring device 80 is a schematic structural diagram of the target element content measuring device shown in FIG. 8 . The target element content measuring device 80 may include:

[0204] A metallographic image acquisition unit 81, adapted to acquire a metallographic image of a target object acquired by a metallographic microscope;

[0205] An image cutting unit 82, adapted to cut the metallographic image into a plurality of image blocks according to a preset cutting size;

[0206] The measuring unit 83 is suitable for inputting the multiple image blocks into a trained deep regression network model to extract the features of the multiple image blocks, and map the features of the multiple image blocks into a real number rating to obtain the real number measurement results of the multiple image blocks, and perform weighted processing on the real number measurement results of the multiple image blocks to obtain the target element content of the metallographic image.

[0207] By adopting the above-mentioned target element content measuring device, there is no need to pre-identify the target element structure in the metallographic image of the target object. Instead, the image features are extracted through a deep regression network model, and the target element content in the image is obtained based on the extracted features. The entire measurement process is automatically completed based on the trained deep regression network, without the need for manual measurement, and the measurement accuracy does not depend on the recognition accuracy of the target element content, thereby ensuring the stability of the measurement results and being able to measure the target element content efficiently, stably and accurately.

[0208] In a specific implementation, the deep regression network model may include: a preset convolutional neural network and a fully connected neural network, and the output end of the convolutional neural network is connected to the input end of the fully connected neural network.

[0209] In some embodiments of the present specification, the convolutional neural network includes: a deep residual network, and the activation functions of the deep residual network and the fully connected neural network are nonlinear activation functions, such as ReLU functions. Accordingly, the measurement unit 83 is suitable for inputting the multiple image blocks into the deep residual network, extracting the features of each image block, obtaining a real number vector with a preset dimension as the feature, and outputting the real number vector to the fully connected neural network, mapping the features of each image block to a real number rating, and obtaining real number measurement results of the multiple image blocks.

[0210] In a specific implementation, if the artificial measurement results of the target element content corresponding to the training image block are preprocessed in the training phase, then in the target element content measurement phase, the real number measurement results of the image block can be post-processed accordingly. For example, if the artificial measurement results of the target element content corresponding to the training image block are logarithmically transformed (as an example, a logarithmic transformation with a base of 10 is performed), then correspondingly, continue to refer to Figure 8 The measuring unit 83 is suitable for performing an exponential transformation on the real number measurement results of the multiple image blocks (as a specific example, performing an exponential transformation with a base of 10), and averaging the real number measurement results after the exponential transformation, converting the average value obtained into a percentage, and obtaining the target element content of the metallographic image.

[0211] The present specification also provides a training device for a deep regression network model suitable for measuring the content of troostites, such as Fig. 9 The structural diagram of the training device shown in FIG. 90 may include:

[0212] A metallographic image acquisition unit 91, adapted to acquire a metallographic image of a target object to be trained;

[0213] An image cutting unit 92, adapted to cut the metallographic image into a plurality of image blocks according to a preset cutting size as image blocks to be trained;

[0214] The training unit 93 is suitable for obtaining the artificial measurement results of the target element content corresponding to the multiple image blocks to be trained, and inputting the artificial measurement results of the target element content corresponding to the multiple image blocks to be trained into the deep regression network model, and using a preset training method to input the image blocks to be trained into the deep regression network model for training until the deep regression network model reaches a preset stability performance indicator.

[0215] In some embodiments of the present specification, the deep regression network model includes: a preset deep residual network and a fully connected neural network, the output end of the deep residual network is connected to the input end of the fully connected neural network, and the activation functions of the deep residual network and the fully connected neural network are non-linear activation functions.

[0216] For example, for the aforementioned deep regression network model composed of a preset deep residual network and a fully connected neural network, the training unit 93 is suitable for inputting the multiple image blocks to be trained into the deep residual network, extracting the features of each of the image blocks to be trained, and obtaining a real number vector with a preset dimension as the feature; and outputting the real number vector to the fully connected neural network, mapping the features of each of the image blocks to be trained into a real number rating, and obtaining real number measurement results of the multiple image blocks to be trained.

[0217] In a specific implementation, the loss function of the deep regression network model includes:

[0218]

[0219] Wherein, P represents the manually determined target element content measurement result of the image block of the preset cutting size, represents the target element content of the metallographic image output during the training process of the deep regression network model, and e is a very small constant greater than 0.

[0220] In a specific implementation, the training unit 83 is suitable for obtaining the manual measurement results of the target element content corresponding to the multiple image blocks to be trained, and inputting the real number measurement results of the multiple image blocks to be trained and the corresponding manual measurement results of the target element content into a preset network loss function respectively until the output value of the loss function converges to a preset threshold.

[0221] As mentioned above, in a specific implementation, the training unit 83 can perform logarithmic transformation on the manual measurement results of the target element contents of the multiple image blocks to be trained and then input them into the deep regression network model for training.

[0222] The present specification also provides a target element content measurement system, such as Fig.10 As shown, the target element content measurement system 100 may include:

[0223] The sample acquisition device 101 is suitable for acquiring a target object, such as cutting a high carbon steel wire rod sample;

[0224] A preprocessing device 102, adapted to preprocess the target object;

[0225] A metallographic image shooting device 103, adapted to automatically shoot a metallographic image of the target object collected by a metallographic microscope after the pre-processed target object is placed under a microscope;

[0226] The target element content measuring device 104 is suitable for measuring the target element content.

[0227] In a specific implementation, the target element content measuring device 104 can be implemented using the target element content measuring device introduced in any of the aforementioned embodiments. The specific implementation methods can be found in the aforementioned embodiments, which will not be described again here.

[0228] The present specification also provides an electronic device, such as Fig.11As shown in the structural schematic diagram of the electronic device, the electronic device 110 may include a memory 111 and a processor 112, the memory stores computer instructions that can be executed on the processor, and the processor executes the steps of the target element content measurement method described in any of the aforementioned embodiments or the training method of the deep regression network model suitable for target element content measurement described in any of the aforementioned embodiments when running the computer instructions.

[0229] It should be noted that the processor 112 may specifically include a CPU chip 1121 formed by one or more CPU cores, or may include a GPU chip 1122, or a chip module composed of the CPU chip 1121 and the GPU chip 1122. The processor 112 and the memory 111 may communicate with each other through a bus or the like, and the chips may also communicate with each other through corresponding communication interfaces.

[0230] The embodiments of this specification also provide a computer-readable storage medium having computer instructions stored thereon, which, when executed, execute the steps of the target element content measurement method described in any of the aforementioned embodiments or the training method of a deep regression network model suitable for target element content measurement described in any of the aforementioned embodiments.

[0231] In a specific implementation, the computer-readable storage medium may include, for example, any suitable type of memory unit, memory device, memory item, memory medium, storage device, storage item, storage medium and / or storage unit, such as memory, removable or non-removable medium, erasable or non-erasable medium, writable or rewritable medium, digital or analog medium, hard disk, floppy disk, compact disk read-only memory (CD-ROM), compact disk recordable (CD-R), compact disk rewritable (CD-RW), optical disk, magnetic medium, magneto-optical medium, removable memory card or disk, various types of digital versatile discs (DVD), magnetic tape, cassette tape, etc.

[0232] Computer instructions may include any suitable type of code, e.g., source code, compiled code, interpreted code, executable code, static code, dynamic code, encrypted code, etc., implemented using any suitable high-level, low-level, object-oriented, visual, compiled and / or interpreted programming language.

[0233] For the specific implementation mode, working principle, specific function and effect of each device, system, equipment or system in the embodiments of the present invention, please refer to the specific introduction in the corresponding method embodiment.

[0234] In the above specific embodiments, the measurement of the troostite content in a high carbon steel wire rod sample is used as an example. Those skilled in the art can understand that the measurement method adopted in the embodiments of this specification is also applicable to other types of target elements in other target objects, as long as the metallographic image of the target object can be obtained.

[0235] Although the embodiments of this specification are disclosed as above, the present invention is not limited thereto. Any person skilled in the art can make various changes and modifications without departing from the spirit and scope of the embodiments of this specification, so the protection scope of the present invention shall be subject to the scope defined by the claims.

Claims

1. A method for measuring target element content, characterized in that: include: Acquire a metallographic image of a target object collected by a metallographic microscope; Cutting the metallographic image into a plurality of image blocks according to a preset cutting size; Inputting the plurality of image blocks into a trained deep regression network model to extract features of the plurality of image blocks, and mapping the features of the plurality of image blocks into a real number rating to obtain real number measurement results of the plurality of image blocks; Performing weighted processing on the real number measurement results of the plurality of image blocks to obtain the target element content of the metallographic image; The deep regression network model includes: a preset convolutional neural network and a fully connected neural network, the output end of the convolutional neural network is connected to the input end of the fully connected neural network; The convolutional neural network includes: a deep residual network; Inputting the plurality of image blocks into a trained deep regression network model to extract features of the plurality of image blocks, and mapping the features of the plurality of image blocks into a real number rating to obtain real number measurement results of the plurality of image blocks, comprises: The multiple image blocks are input into the deep residual network, the features of each image block are extracted, and a real number vector with a preset dimension is obtained; the real number vector is output to the fully connected neural network, the features of each image block are mapped into a real number rating, and the real number measurement results of the multiple image blocks are obtained.

2. The target element content measurement method according to claim 1, characterized in that: The deep residual network includes any of the following: The 50-layer residual network ResNet50 and the 101-layer residual network ResNet101.

3. The target element content measurement method according to claim 2, characterized in that: The activation functions of the deep residual network and the fully connected neural network include: ; Among them, x represents the input variable of the neuron, and f(x) represents the value mapped by the output of the neuron.

4. The target element content measurement method according to any one of claims 1 to 3, characterized in that: The step of performing weighted processing on the real number measurement results of the plurality of image blocks to obtain the target element content of the metallographic image comprises: An average value is calculated for the real number measurement results of the plurality of image blocks, and the average value is converted into a percentage to obtain the target element content of the metallographic image.

5. The target element content measurement method according to claim 4, characterized in that: The deep regression network model is trained using the following method: Acquire a metallographic image of a target object to be trained; Cutting the metallographic image according to the preset cutting size to obtain a plurality of image blocks as image blocks to be trained; Obtain manual measurement results of target element contents corresponding to multiple image blocks to be trained, input the manual measurement results of target element contents corresponding to the multiple image blocks to be trained into the deep regression network model, and input the image blocks to be trained into the deep regression network model for training using a preset training method until the deep regression network model reaches a preset stability performance indicator.

6. The target element content measurement method according to claim 5, characterized in that: The loss function of the deep regression network model includes: ; Wherein, P represents the manually determined target element content measurement result of the image block of the preset cutting size, represents the target element content of the metallographic image output during the training process of the deep regression network model, and e is a very small constant greater than 0.

7. The method for measuring the target element content according to claim 6, characterized in that: The step of using a preset training method to input the image block to be trained into the deep regression network model for training until the deep regression network model reaches a preset stability performance index includes: Adaptive moment estimation method is used and the learning rate is set to 10 -3 , so that the output value of the loss function of the deep regression network converges to a preset threshold.

8. The target element content measurement method according to claim 5, characterized in that: Also includes: Before inputting the image block to be trained into the deep regression network model for training, preprocessing the manual measurement results of the target element content corresponding to the image block to be trained; Before weighting the real number measurement results of the plurality of image blocks, post-processing is performed on the real number measurement results of the plurality of image blocks.

9. The target element content measurement method according to claim 8, characterized in that: The preprocessing of the manual measurement result of the target element content corresponding to the image block to be trained includes: performing logarithmic transformation on the manual measurement result of the target element content corresponding to the image block to be trained; The real number measurement results of the multiple image blocks are post-processed before the real number measurement results of the multiple image blocks are weighted, including: performing exponential transformation on the real number measurement results of the multiple image blocks.

10. The target element content measurement method according to claim 5, characterized in that: The metallographic image is cut according to the preset cutting size to obtain a plurality of image blocks, and the image blocks to be trained include at least one of the following: Extracting image blocks with a size of the preset cutting size from the metallographic image from top to bottom and from left to right according to a preset step length as the image blocks to be trained; Processing the metallographic image by upsampling and downsampling, and cutting the metallographic image obtained after sampling according to the preset cutting size to obtain the image block to be trained; The metallographic image is subjected to image enhancement processing, and the enhanced metallographic image is cut according to the preset cutting size to obtain the image block to be trained.

11. A training method for a deep regression network model suitable for measuring target element content, characterized in that: include: Acquire a metallographic image of a target object to be trained; Cutting the metallographic image into a plurality of image blocks according to a preset cutting size as image blocks to be trained; Obtaining manual measurement results of target element contents corresponding to a plurality of image blocks to be trained, inputting the manual measurement results of target element contents corresponding to the plurality of image blocks to be trained into the deep regression network model, and inputting the image blocks to be trained into the deep regression network model for training using a preset training method until the deep regression network model reaches a preset stability performance index; The deep regression network model includes: A preset deep residual network and a fully connected neural network, wherein the output end of the deep residual network is connected to the input end of the fully connected neural network; The step of using a preset training method to input the image block to be trained into the deep regression network model for training includes: The multiple image blocks to be trained are input into the deep residual network, and the features of each image block to be trained are extracted to obtain a real number vector with a preset dimension as the feature; the real number vector is output to the fully connected neural network, and the features of each image block to be trained are mapped into a real number rating to obtain real number measurement results of the multiple image blocks to be trained.

12. The training method according to claim 11, characterized in that: The loss function of the deep regression network model includes: ; Wherein, P represents the manually determined target element content measurement result of the image block of the preset cutting size, represents the target element content of the metallographic image output during the training process of the deep regression network model, and e is a very small constant greater than 0.

13. The training method according to claim 12, characterized in that: The step of using a preset training method to input the image block to be trained into the deep regression network model for training until the deep regression network model reaches a preset stability performance index includes: The real number measurement results of the plurality of image blocks to be trained and the corresponding manual measurement results of the target element content are respectively input into a preset network loss function until the output value of the loss function converges to a preset threshold.

14. The training method according to claim 13, characterized in that: The step of using a preset training method to input the image block to be trained into the deep regression network model for training until the deep regression network model reaches a preset stability performance index includes: Adaptive moment estimation method is used and the learning rate is set to 10 -3 , so that the loss function of the deep regression network gradually converges to a preset stable state indicator.

15. The training method according to claim 11, characterized in that: Before inputting the image block to be trained into the deep regression network model for training, the method further includes: Preprocessing is performed on the manual measurement results of the target element content corresponding to the image block to be trained.

16. The training method according to claim 15, characterized in that: The preprocessing of the manual measurement result of the target element content corresponding to the image block to be trained includes: Perform logarithmic transformation on the manual measurement result of the target element content corresponding to the image block to be trained.

17. The training method according to claim 11, characterized in that: The step of cutting the metallographic image into a plurality of image blocks according to a preset cutting size as the image blocks to be trained comprises at least one of the following: Extracting image blocks with a size of the preset cutting size from the metallographic image from top to bottom and from left to right according to a preset step length as the image blocks to be trained; Processing the metallographic image by upsampling and downsampling, and cutting the metallographic image obtained after sampling according to the preset cutting size to obtain the image block to be trained; The metallographic image is subjected to image enhancement processing, and the enhanced metallographic image is cut according to the preset cutting size to obtain the image block to be trained.

18. A method for measuring target element content, characterized in that: include: Get the target object; Preprocessing the target object; Place the pre-treated target object under a metallographic microscope; Automatically take metallographic images of target objects collected by metallographic microscope; The target element content measurement method according to any one of claims 1 to 10 is used to perform measurement to obtain the target element content of the metallographic image of the target object.

19. A target element content measuring device, characterized in that: include: A metallographic image acquisition unit, adapted to acquire a metallographic image of a target object acquired by a metallographic microscope; An image cutting unit, adapted to cut the metallographic image into a plurality of image blocks according to a preset cutting size; a measuring unit adapted to input the plurality of image blocks into a trained deep regression network model to extract features of the plurality of image blocks, map the features of the plurality of image blocks into a real number rating, obtain real number measurement results of the plurality of image blocks, perform weighted processing on the real number measurement results of the plurality of image blocks, and obtain the target element content of the metallographic image, wherein the training of the deep regression network model adopts the target element content measurement results of the image blocks of the preset cutting size measured; The deep regression network model includes: a preset convolutional neural network and a fully connected neural network, and the output end of the convolutional neural network is connected to the input end of the fully connected neural network; The convolutional neural network includes: a deep residual network, and the activation functions of the deep residual network and the fully connected neural network are nonlinear activation functions; The measurement unit is suitable for inputting the multiple image blocks into the deep residual network, extracting features of each image block, obtaining a real number vector with a preset dimension as the feature, and outputting the real number vector to the fully connected neural network, mapping the features of each image block into a real number rating, and obtaining real number measurement results of the multiple image blocks.

20. The target element content measuring device according to claim 19, characterized in that: The measuring unit is adapted to perform exponential transformation on the real number measurement results of the multiple image blocks, calculate an average value of the real number measurement results after the exponential transformation, and convert the calculated average value into a percentage to obtain the target element content of the metallographic image.

21. A training device for a deep regression network model suitable for measuring target element content, characterized in that: include: A metallographic image acquisition unit, adapted to acquire a metallographic image of a target object to be trained; An image cutting unit, adapted to cut the metallographic image into a plurality of image blocks according to a preset cutting size as image blocks to be trained; A training unit, adapted to obtain manual measurement results of target element contents corresponding to a plurality of image blocks to be trained, and input the manual measurement results of target element contents corresponding to the plurality of image blocks to be trained into the deep regression network model, and input the image blocks to be trained into the deep regression network model for training using a preset training method until the deep regression network model reaches a preset stability performance index, wherein the training of the deep regression network model uses the measured target element content measurement results of the image blocks of the preset cutting size; The deep regression network model includes: A preset deep residual network and a fully connected neural network, wherein the output end of the deep residual network is connected to the input end of the fully connected neural network, and the activation functions of the deep residual network and the fully connected neural network are nonlinear activation functions; The training unit is suitable for inputting the multiple image blocks to be trained into the deep residual network, extracting the features of each of the image blocks to be trained, and obtaining a real number vector with a preset dimension as the feature; and outputting the real number vector to the fully connected neural network, mapping the features of each of the image blocks to be trained into a real number rating, and obtaining real number measurement results of the multiple image blocks to be trained.

22. The training device according to claim 21, characterized in that The loss function of the deep regression network model includes: ; Wherein, P represents the manually determined target element content measurement result of the image block of the preset cutting size, represents the target element content of the metallographic image output during the training process of the deep regression network model, and e is a very small constant greater than 0.

23. The training device according to claim 22, characterized in that The training unit is adapted to obtain artificial measurement results of target element contents corresponding to the plurality of image blocks to be trained, and input the real number measurement results of the plurality of image blocks to be trained and the corresponding artificial measurement results of target element contents into a preset network loss function respectively until the output value of the loss function converges to a preset threshold.

24. A training device according to any one of claims 21 to 23, characterized in that The training unit is suitable for performing logarithmic transformation on the manual measurement results of the target elements of the multiple image blocks to be trained and then inputting them into the deep regression network model for training.

25. A target element content measurement system, characterized in that: include: A sample acquisition device, adapted to acquire a target object; A preprocessing device, adapted to preprocess the target object; A metallographic image shooting device, adapted to automatically shoot a metallographic image of the target object acquired by a metallographic microscope after the pre-processed target object is placed under a microscope; And the target element content measuring device according to any one of claims 19 to 20.

26. An electronic device comprising a memory and a processor, wherein the memory stores computer instructions that can be executed on the processor, characterized in that: When the processor executes the computer instructions, the method according to any one of claims 1 to 10 or the steps of the method according to any one of claims 11 to 18 are performed.

27. A computer-readable storage medium having computer instructions stored thereon, characterized in that: When the computer instructions are executed, the method according to any one of claims 1 to 10 or the steps of the method according to any one of claims 11 to 18 are executed.