An Improved Zinc Flotation Foam Image Classification Algorithm and System for Deep Active Learning
Through the improved deep active learning method and the convolutional neural network combined with active learning and deep learning, the problems of strong subjectivity and high labeling cost in the zinc flotation process are solved, and real-time and accurate foam image classification and flotation process optimization are achieved.
Patent Information
- Application Number
- CN202210249062.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-14
- Publication Date
- 2025-07-18
- Estimated Expiration
- 2042-03-14
AI Technical Summary
In the prior art, in the zinc flotation process, manual operation is highly subjective and inaccurate, XRF analyzer maintenance is difficult and costly, making it difficult to achieve real-time control and optimization, and deep learning models require a large number of labeling samples, resulting in high labeling costs.
The improved deep active learning method is adopted, combining active learning and deep learning, and classifying bubble images through convolutional neural network model, using active learning to select label-free samples for annotation, combining Inception-V2 and Dense Net network structures, training is performed using a loss function that considers category weights, reducing labeling costs and improving classification accuracy.
Real-time and accurate foam image classification during zinc flotation is achieved, which reduces labeling costs, improves model training efficiency and classification accuracy, and meets the real-time control needs of the flotation process.
Smart Images

Figure CN114627333B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of froth flotation, and particularly relates to a method for classifying foam images in the zinc flotation process. Background Art
[0002] Froth flotation is the most widely used ore beneficiation method. It involves complex physical and chemical processes and effectively separates different minerals by utilizing the difference in the hydrophobicity and hydrophilicity of the surfaces of mineral particles. All along, the workers at the zinc-lead ore flotation site have carried out flotation operations by visually observing the surface state of the foam and judged the flotation working conditions based on the experience accumulated over a long time. This manual operation method is highly subjective and arbitrary, often resulting in inaccurate results and large consumption of reagents. In order to improve the accuracy and robustness of grade monitoring, an X-ray fluorescence analyzer (XRF analyzer) is applied in modern flotation devices. However, the XRF analyzer is an expensive measuring device and difficult to maintain. To save costs, flotation plants usually use the XRF analyzer to measure the grades of multiple pulp samples, which results in a long measurement interval (about 20 minutes) for grade monitoring, making the detection of ore grades have a time lag and difficult to meet the complex and changeable flotation site, and also difficult to meet the requirements of real-time control of the flotation process.
[0003] Extracting the surface visual features of flotation foam using machine vision provides the possibility for realizing the identification of mineral working conditions. With the development of deep learning, deep convolutional neural networks have shown excellent performance in tasks such as image classification and image segmentation. Therefore, a deep convolutional neural network model is constructed to achieve accurate and rapid classification and recognition of foam images. However, using a deep learning model for classification requires a large number of labeled samples to train the classification model, and these labeled samples not only need to be labeled with the prior knowledge of experts but also require a large amount of manpower and time. To address these problems, a new foam image classification method that combines active learning with high labeling efficiency and deep learning is proposed, which improves the accuracy of foam image classification while effectively reducing the labeling cost. Summary of the Invention
[0004] The purpose of the present invention is to provide an improved zinc flotation foam image classification algorithm and system based on deep active learning. By classifying the flotation foam images, it can effectively judge the current working conditions, thereby controlling some operating variables in the flotation process and realizing real-time control and optimization of the flotation process. The present invention aims at the problems of class imbalance among foam images and the need for a large number of labeled samples at present, and proposes an improved method that combines active learning and deep learning, which is applied to flotation foam pictures. The advantages of reducing the labeling cost of active learning and the advantages of feature extraction of deep learning are respectively utilized to improve the training efficiency and the accuracy of foam image classification, while reducing the amount of annotation of training data.
[0005] The technical solution adopted by the present invention is as follows:
[0006] Step 1: Data preparation;
[0007] Collect foam images during the rough zinc ore separation process to form a foam image dataset. The foam image dataset contains a labeled sample set (X L , Y L ) and an unlabeled sample set X U ;
[0008] Step 2: Data preprocessing;
[0009] Rotate and flip the obtained foam image samples, perform data augmentation processing to obtain a sample image set, and divide all sample images into a training set and a validation set according to a certain ratio;
[0010] Step 3: Build a deep classification model;
[0011] The convolutional neural network structure is based on the Dense Net and Inception network models, which includes 1 Inception module, 3 dense_block modules, and 3 transition layers. And the Inception module is set in front of the first transition module to replace the original dense_block module;
[0012] Step 4: Train the initial network model;
[0013] Randomly select an initial training set L=(x1, x2,......, x L , Y L ) with a sample size of n from the labeled sample set (X n ), input it into the training model, and perform initial training on the training model;
[0014] Step 5: Select samples and update the model;
[0015] Select samples from the unlabeled sample set X U for annotation through active learning, and perform training adjustment on the training model;
[0016] Step 6: Obtain the final Dense Net and Inception-V2 module fusion convolutional neural network model after training adjustment. Input the foam image data to be classified into the network model for recognition and classification to obtain the final classification result of the foam image.
[0017] In the above zinc flotation foam image classification algorithm that improves deep active learning, in step one, the images in the foam image dataset are divided into four categories, respectively represented as Class I, Class II, Class III, and Class IV, which are respectively recorded as four situations: abnormal, qualified, medium, and excellent. Among them, the grade value ranges are (-∞, 53], (53, 54], (54, 55], and (55, +∞) in sequence.
[0018] In the above zinc flotation foam image classification algorithm that improves deep active learning, in step two, a random image processing method is used to expand the foam image set, including: horizontal and vertical flipping, left and right rotation; 80% of the data in each category of the expanded dataset is extracted as the training set, and the remaining 20% of the data is used as the validation set.
[0019] In the above zinc flotation foam image classification algorithm for improving deep active learning, in step three, the fusion model is trained using the data in the training set. The structure of the fusion model is as follows: The block layer receives the foam image with a size of 512×512 pixels input by the data layer. Using a 7×7 convolutional kernel with a stride of 2, it convolves the input data. After batch normalization, ReLU activation function, and max pooling layer, 16 feature maps with a size of 128×128 are obtained and passed to the Inception module; The Inception layer is stacked by two Inception-V2 modules. The Inception-V2 module contains four branches, and the convolutional receptive fields of each branch are 1×1 convolution, 3×3 convolution, 3×3 pooling, and two 3×3 convolutions; At the same time, batch normalization operations are followed immediately after the 1×1, 3×3, and two 3×3 convolutional kernels, and then the outputs of each are stacked together; After two Inception-V2 modules, and then through the max pooling layer, 8 feature maps of 128×128 are extracted; The transition1 layer reduces the number of channels through a 1×1 convolutional layer, and uses an average pooling layer with a stride of 2 to halve the height and width, obtaining 4 feature maps of 64×64 and passing them to the dense block1 layer; The dense_block1 layer is stacked by twelve layer modules. Each layer module receives the feature maps of all the previous layers. After concatenating the features of the current layer with those of all the previous layers through the concat operation, it is passed to the next layer. After twelve layer layers, 388 feature maps of 64×64 are extracted and input to the transition2 layer; The transition2 layer reduces the number of channels through a 1×1 convolutional layer, and uses an average pooling layer with a stride of 2 to halve the height and width, obtaining 194 feature maps of 32×32 and passing them to the dense_block2 layer; The dense_block2 layer is stacked by twenty-four layer modules. Each layer module receives the feature maps of all the previous layers. After concatenating the features of the current layer with those of all the previous layers through the concat operation, it is passed to the next layer. After twenty-four layer layers, 962 feature maps of 32×32 are extracted and input to the transition3 layer; The transition3 layer reduces the number of channels through a 1×1 convolutional layer, and uses an average pooling layer with a stride of 2 to halve the height and width, obtaining 481 feature maps of 32×32 and passing them to the dense_block3 layer; The dense_block3 layer is stacked by sixteen layer modules. Each layer module receives the feature maps of all the previous layers. After concatenating the features of the current layer with those of all the previous layers through the concat operation, it is passed to the next layer. After sixteen layer layers, 993 feature maps of 32×32 are extracted;The output of the dense_block3 layer is averaged through a global AvgPooling layer, and the feature map is unfolded into a one-dimensional vector and passed to the fully connected layer. The fully connected layer uses Dropout to randomly discard the outputs of some neurons to reduce overfitting. Finally, the output of the fully connected layer is fed into the softmax classifier to obtain the classification result.
[0020] In the above zinc flotation foam image classification algorithm with improved deep active learning, in step five, the unlabeled sample set X U is selected through active learning for annotation. The process of training and adjusting the model includes: calculating the information amount of each unlabeled sample in the unlabeled sample set X U using the active learning strategy, sorting the information amounts in descending order, and selecting the top K labeled samples for annotation to generate sample-label pairs (x * , y * ). The newly annotated samples (x * , y * ) are added to the labeled sample set (X L , Y L ), and the training model is trained and adjusted. The above operations are iteratively looped until the network reaches the specified performance or all unlabeled samples are annotated, and the finally trained convolutional neural network model is saved.
[0021] In the above zinc flotation foam image classification algorithm with improved deep active learning, in step five, the active learning strategy is an active learning method with a loss prediction module. The loss prediction module is attached to the deep learning model to predict the loss value of samples without labels, evaluate the information amount of all unlabeled samples in the unlabeled pool, and at the same time mark the samples with the top-K predicted losses and add them to the training set.
[0022] In the above zinc flotation foam image classification algorithm with improved deep active learning, during the model training process, a weighted loss function based on the loss function considering the weights between categories and the loss prediction loss function is adopted, and its form is defined as:
[0023]
[0024] In the formula, the first part belongs to the loss considering the weights between categories, and the second part is the loss prediction loss. B is the number of mini-batch samples, B s is the number of mini-batch samples in the s-th stage of active learning, and γ is the weight; represents the predicted category; y represents the true category value, l represents the target loss, represents the loss prediction of the sample through the loss prediction module.
[0025]
[0026] Wherein, n y is the number of classes of y in the training set, is the weight factor, β is a hyperparameter, β ∈ [0, 1), where a regulation factor δ is introduced to reduce the weight gap between the few-shot classes and the many-shot classes. The larger the regulation factor δ, the larger the weight gap between classes; C is the total number of classes, and z j is the probability that the model output belongs to the j-th class after passing through softmax.
[0027]
[0028]
[0029] Wherein, ε is a predefined positive boundary, and (i, j) represents a pair of loss predictions.
[0030] In the above zinc flotation foam image classification algorithm for improved deep active learning, in step five, the sign of the completion of training adjustment is that the network reaches the specified performance or the unlabeled sample set X U is completely labeled.
[0031] In the above zinc flotation foam image classification algorithm for improved deep active learning, in step five, δ is set to 0.4, γ is set to 2, and β is set to 0.9999.
[0032] The present invention also proposes a zinc flotation foam image classification system for improved deep active learning. The system is used to implement the zinc flotation foam image classification algorithm for improved deep active learning, including:
[0033] An image sample collector for collecting foam image samples during the zinc flotation process;
[0034] A training model acquisition module, where an improved fusion convolutional neural network model is used as the training model for flotation foam image classification;
[0035] A training model initialization module, which randomly selects an initial training set L = (x1, x2,..., x L Y L ) with a sample size of n from the labeled sample set (X n ), inputs it into the training model, and performs initial training on the training model;
[0036] A model annotation adjustment module, which selects samples from the unlabeled sample set X U for annotation through active learning, and trains and updates the training model;
[0037] The working condition recognition module uses the trained and updated training model to classify and recognize foam images.
[0038] Compared with the prior art, the beneficial effects of the technical solution of the present invention are as follows:
[0039] An improved deep active learning zinc flotation foam image classification algorithm and system proposed by the present invention, for the foam images obtained by industrial cameras set on site, based on a new loss function, proposes a deep active learning framework for foam image classification adapted to class imbalance. The fusion convolutional neural network model that combines the improved Dense Net and Inception Net is used as the training model for foam image classification. The convolutional neural network model is used to learn the characteristics of flotation foam, and the active learning method is used to select unlabeled data for annotation. The data with the largest amount of information selected is put into the labeled data set L, and the training model is trained and updated, effectively selecting key information and reducing the cost of manually labeling samples. By combining the advantages of the two learning methods, the efficiency of model training and the accuracy of foam image classification can be improved. Brief Description of the Drawings
[0040] Figure 1 It is a schematic diagram of the overall process of an improved deep active learning zinc flotation foam image classification algorithm in an embodiment of the present invention.
[0041] Figure 2 They are foam images under 4 different working conditions in the flotation process in an embodiment of the present invention.
[0042] Figure 3 It is a structural diagram of the improved fusion convolutional neural network model proposed in the present invention.
[0043] Figure 4 It is a block diagram of the deep active learning proposed in the present invention.
[0044] Figure 5 It is a block diagram of the overall deep active learning of an improved deep active learning zinc flotation foam image classification algorithm in an embodiment of the present invention. Specific Implementation Method
[0045] Figure 1 It is a flow block diagram of the present invention.
[0046] Step 1: Data Preparation
[0047] Collect foam images during the zinc roughing process to form a foam image data set. Among them, the foam image data set includes a labeled sample set (X L , Y L ) and an unlabeled sample set X U .
[0048] In this embodiment, the images in the foam image dataset are divided into four categories, denoted as Class I, Class II, Class III, and Class IV, which are respectively recorded as four situations: abnormal, qualified, medium, and excellent. Among them, the grade value ranges are (-∞, 53], (53, 54], (54, 55], (55, +∞) in sequence, as Figure 2 shown.
[0049] Step 2: Data preprocessing
[0050] The obtained foam image samples are rotated and flipped, and data augmentation processing is performed to obtain a sample image set. All sample images are divided into a training set and a validation set according to a certain proportion.
[0051] In this embodiment, a random image processing method is adopted to expand the foam image set, including: horizontal and vertical flipping, left and right rotation; 80% of the data in each category of the expanded dataset is extracted as the training set, and the remaining 20% of the data is used as the validation set.
[0052] Step 3: Build a deep classification model
[0053] The convolutional neural network structure is based on the Dense Net and Inception network models, which includes 1 Inception module, 3 dense_block modules, and 3 transition layers. And the Inception module is set in front of the first transition module to replace the original dense_block module.
[0054] In this embodiment, the fusion model is trained using the data in the training set. The structure of the fusion model is as follows: The block layer receives the foam image with a size of 512×512 pixels input by the data layer, performs convolution on the input data using a 7×7 convolutional kernel with a stride of 2, and after batch normalization, ReLU activation function, and max pooling layer, 16 feature maps with a size of 128×128 are obtained and passed to the Inception module; The Inception layer is stacked by two Inception-V2 modules. The Inception-V2 module contains four branches, and the convolutional receptive fields of each branch are 1×1 convolution, 3×3 convolution, 3×3 pooling, and two 3×3 convolutions; At the same time, batch normalization operations are followed immediately after the 1×1, 3×3, and two 3×3 convolutional kernels, and then the outputs of each are stacked together; After passing through two Inception-V2 modules and then through the max pooling layer, 8 feature maps of 128×128 are extracted; The transition1 layer reduces the number of channels through a 1×1 convolutional layer and halves the height and width using an average pooling layer with a stride of 2 to obtain 4 feature maps of 64×64, which are passed to the dense_block1 layer; The dense_block1 layer is stacked by twelve layer modules. Each layer receives the feature maps of all the previous layers. After concatenating the features of the current layer with those of all the previous layers through the concat operation, it is passed to the next layer. After twelve layer layers, 388 feature maps of 64×64 are extracted and input to the transition2 layer; The transition2 layer reduces the number of channels through a 1×1 convolutional layer and halves the height and width using an average pooling layer with a stride of 2 to obtain 194 feature maps of 32×32, which are passed to the dense_block2 layer; The dense_block2 layer is stacked by twenty-four layer modules. Each layer receives the feature maps of all the previous layers. After concatenating the features of the current layer with those of all the previous layers through the concat operation, it is passed to the next layer. After twenty-four layer layers, 962 feature maps of 32×32 are extracted and input to the transition3 layer; The transition3 layer reduces the number of channels through a 1×1 convolutional layer and halves the height and width using an average pooling layer with a stride of 2 to obtain 481 feature maps of 32×32, which are passed to the dense_block3 layer; The dense_block3 layer is stacked by sixteen layer modules. Each layer receives the feature maps of all the previous layers. After concatenating the features of the current layer with those of all the previous layers through the concat operation, it is passed to the next layer. After sixteen layer layers, 993 feature maps of 32×32 are extracted;The output of the dense_block3 layer is averaged through a global AvgPooling layer, and the feature map is unfolded into a one-dimensional vector and passed to the fully connected layer. The fully connected layer uses Dropout to randomly discard the outputs of some neurons to reduce overfitting. Finally, the output of the fully connected layer is fed into the softmax classifier to obtain the classification result. The fusion network structure of the present invention is as follows; Figure 3 as shown.
[0055] Step Four: Training the initial network model
[0056] Randomly select an initial training set L=(x1, x2,......, x L , Y L ) with a sample size of n from the labeled sample set (X n ), input it into the training model, and perform initial training on the training model.
[0057] Step Five: Select samples and update the model
[0058] Select samples from the unlabeled sample set X U for annotation through active learning. The process of training and adjusting the training model includes: using the active learning strategy to calculate the information amount of each unlabeled sample in the unlabeled sample set X U , sort the information amounts in descending order, select the top K (top-K) labeled samples for annotation, generate sample-label pairs (x * , y * ), add the newly annotated samples (x * , y * ) to the labeled sample set (X L , Y L ), train and adjust the training model, and iteratively execute the above operations until the network reaches the specified performance or the unlabeled sample set is completely annotated. Save the finally trained convolutional neural network model. The deep active learning framework is as Figure 4 shown. The active learning strategy is an active learning method with a loss prediction module. The loss prediction module is attached to the deep learning model to predict the loss values of samples without labels, evaluate the information amounts of all unlabeled samples in the unlabeled pool, and at the same time mark the samples with the top-K predicted losses and add them to the training set.
[0059] The present system adopts a weighted loss function based on the loss function considering the weights between categories and the loss prediction loss function, and its form is defined as:
[0060]
[0061] In the formula, the first part belongs to the loss considering the weights between categories, and the second part is the loss prediction loss. B is the number of mini-batch samples, and B s is the number of mini-batch samples for active learning in the s-th stage, and γ is the weight; represents the predicted category; y represents the true category value, and l represents the target loss, represents the loss prediction of the sample passing through the loss prediction module.
[0062]
[0063] In the formula, n y is the number of samples with category y in the training set, is the weight factor, β is a hyperparameter, β ∈ [0, 1), and a regulation factor δ is introduced to reduce the weight gap between few-shot classes and multi-shot classes. The larger the regulation factor δ, the larger the weight gap between classes; C is the total number of classes, and z j is the probability that the model output belongs to the j-th class after passing through softmax.
[0064]
[0065]
[0066] In the formula, ε is a predefined positive boundary, and (i, j) represents a pair of loss predictions.
[0067] In this embodiment, the sign of the completion of training adjustment is that the network reaches the specified performance or the unlabeled sample set X U is completely labeled.
[0068] In this embodiment, δ is set to 0.4, γ is set to 2, and β is set to 0.9999.
[0069] Step Six: Obtain the finally trained and adjusted Dense Net and Inception-V2 module fusion convolutional neural network model. Input the foam image data to be classified into the network model for recognition and classification to obtain the final classification result of the foam image. The overall structure of the deep active learning of the improved zinc flotation foam image classification algorithm by deep active learning is as Figure 5 shown.
[0070] The present invention also proposes an improved deep active learning zinc flotation foam image classification system. The system is used to implement the improved deep active learning zinc flotation foam image classification algorithm, including: an image sample collector for collecting zinc flotation process foam image samples;
[0071] a training model acquisition module, with the improved fusion convolutional neural network model as the training model for flotation foam image classification; a training model initialization module, starting from the labeled sample set (XL , Y L ) Randomly select an initial training set L = (x1, x2,......, x n ), and input it into the training model for initial training of the training model;
[0072] The model annotation adjustment module selects unlabeled sample sets X through active learning U to annotate the samples in and train and update the training model.
[0073] The working condition recognition module uses the training model after the training update is completed to classify and recognize foam images.
[0074] It should be understood that the parts not elaborated in detail in this specification all belong to the prior art.
[0075] It should be understood that the above description of the preferred embodiment is relatively detailed, and it should not be considered as a limitation to the protection scope of the invention patent. Under the inspiration of the present invention, those of ordinary skill in the art can also make substitutions or deformations without departing from the protection scope defined by the claims of the present invention, and all fall within the protection scope of the present invention. The scope of protection claimed by the present invention shall be subject to the appended claims.
Claims
1. An improved zinc flotation foam image classification algorithm for deep active learning, characterized in that, It includes the following steps: Step 1: Data preparation; Collect foam images during the rough selection process of zinc blocks to form a foam image dataset. Among them, the foam image dataset contains a labeled sample set (X L , Y L ) and an unlabeled sample set X U ; Step 2: Data preprocessing; Rotate and flip the obtained foam image samples, perform data augmentation processing to obtain a sample image set, and divide all sample images into a training set and a validation set according to a ratio; Step 3: Build a deep classification model; The convolutional neural network structure is based on the fusion of the Dense Net and Inception network models, which contains 1 Inception module, 3 dense_block modules and 3 transition layers, and the Inception module is set in front of the first transition module to replace the original dense_block module; Step 4: Train the initial network model; From the labeled sample set (X L , Y L ), randomly select an initial training set L = (x1, x2,..., x n ) with a sample size of n, input it into the training model, and perform initial training on the training model; Step 5: Select samples and update the model; Select an unlabeled sample set X through active learning U Annotate the samples in it and adjust the training of the training model; Step 6: Obtain the finally trained and adjusted convolutional neural network model that fuses the Dense Net and Inception-V2 modules. Input the foam image data to be classified into the network model for recognition and classification to obtain the final classification result of the foam image.
2. An improved zinc flotation foam image classification algorithm for deep active learning according to claim 1, characterized in that, In Step 1, the images in the foam image dataset are divided into four categories, which are respectively represented as Class I, Class II, Class III, and Class IV, and are respectively recorded as four situations: abnormal, qualified, medium, and excellent. Among them, the grade value ranges are (-∞, 53], (53, 54], (54, 55], and (55, +∞) in sequence.
3. An improved zinc flotation foam image classification algorithm for deep active learning according to claim 1, characterized in that, In Step 2, a random image processing method is used to expand the foam image set, including: horizontal and vertical flipping, left and right rotation; 80% of the data in each category of the expanded dataset is extracted as the training set, and the remaining 20% of the data is used as the validation set.
4. An improved zinc flotation foam image classification algorithm for deep active learning according to claim 1, characterized in that In Step 4, the data in the training set is used to train the fusion model, and the structure of the fusion model is as follows: The block layer receives the foam image with a size of 512×512 pixels input by the data layer, uses a convolutional kernel with a size of 7×7 and a stride of 2 to perform convolution on the input data, and after batch normalization, ReLU activation function, and max pooling layer, 16 feature maps with a size of 128×128 are obtained and passed to the Inception module; The Inception layer is composed of two stacked Inception-V2 modules. The Inception-V2 module contains four branches, and the convolutional receptive fields of each branch are 1×1 convolution, 3×3 convolution, 3×3 pooling, and 2 3×3 convolutions respectively; at the same time, batch normalization operations are followed after the 1×1, 3×3, and 2 3×3 convolutional kernels, and then each output is stacked together; after two Inception-V2 modules, and then through the max pooling layer, 8 feature maps with a size of 128×128 are extracted; The transition1 layer reduces the number of channels through a 1×1 convolutional layer, and uses an average pooling layer with a stride of 2 to halve the height and width, obtaining 4 feature maps with a size of 64×64, and passing them to the dense_block1 layer; The dense_block1 layer is composed of twelve layer modules stacked together. Each layer module receives the feature maps of all the previous layers as input. After concatenating the features of the current layer with those of all the previous layers through a concat operation, the result is passed to the next layer. After passing through twelve layer modules, 388 feature maps of 64×64 are extracted and input to the transition2 layer; The transition2 layer reduces the number of channels through a 1×1 convolutional layer and halves the height and width using an average pooling layer with a stride of 2, obtaining 194 feature maps of 32×32, which are then passed to the dense_block2 layer; The dense_block2 layer is composed of twenty-four layer modules stacked together. Each layer module receives the feature maps of all the previous layers as input. After concatenating the features of the current layer with those of all the previous layers through a concat operation, the result is passed to the next layer. After passing through twenty-four layer modules, 962 feature maps of 32×32 are extracted and input to the transition3 layer; The transition3 layer reduces the number of channels through a 1×1 convolutional layer and halves the height and width using an average pooling layer with a stride of 2, obtaining 481 feature maps of 32×32, which are then passed to the dense_block3 layer; The dense_block3 layer is composed of sixteen layer modules stacked together. Each layer module receives the feature maps of all the previous layers as input. After concatenating the features of the current layer with those of all the previous layers through a concat operation, the result is passed to the next layer. After passing through sixteen layer modules, 993 feature maps of 32×32 are extracted; The output result of the dense_block3 layer is subjected to average pooling through a global AvgPooling layer, and the feature maps are unfolded into a one-dimensional vector and passed to the fully connected layer. The fully connected layer uses Dropout to randomly discard the outputs of some neurons to reduce overfitting. Finally, the output of the fully connected layer is passed into the softmax classifier to obtain the classification result.
5. An improved zinc flotation foam image classification algorithm for deep active learning according to claim 1, characterized in that, In step 5, the unlabeled sample set X is selected through active learning U The process of training and adjusting the training model includes: using active learning strategy to calculate the unlabeled sample set X U The information amount of each unlabeled sample in is sorted from large to small, and the top K labeled samples are selected for annotation to generate sample and label pairs (x * ,y * ), the new labeled sample (x * ,y * )Add the sample set with labels (X L , Y L ), train and adjust the training model, iterate and loop through the above operations until the network reaches the specified performance or the unlabeled sample set is labeled, and save the final trained convolutional neural network model.
6. An improved zinc flotation foam image classification algorithm for deep active learning according to claim 1, characterized in that The active learning strategy described in step five is an active learning method with a loss prediction module. The loss prediction module is attached to the deep learning model to predict the loss values of samples without labels, evaluate the information content of all unlabeled samples in the unlabeled pool, and at the same time mark the samples with the top-K predicted losses and add them to the training set.
7. An improved zinc flotation foam image classification algorithm for deep active learning according to claim 1, characterized in that, During the model training process, a weighted loss function based on the loss function considering the weights between classes and the loss prediction loss function is adopted, and its form is defined as: In the formula, the first part belongs to the loss considering the weights between categories, and the second part is the loss prediction loss. B is the number of mini-batch samples, and B s is the number of mini-batch samples for active learning in the s-th stage, and γ is the weight; represents the predicted category; y represents the true category value, and l represents the target loss, represents the loss prediction of the sample passing through the loss prediction module; where n y is the number of classes of y in the training set, is the weight factor, β is a hyperparameter, β ∈ [0, 1), where a regularization factor δ is introduced to mitigate the weight gap between few-shot classes and many-shot classes. The larger the regularization factor δ, the greater the weight gap between classes; C is the total number of classes, and z j is the probability that the model output belongs to the j-th class after passing through softmax; In the formula, ε is a predefined positive boundary, and (i, j) represents a pair of loss predictions.
8. An improved zinc flotation foam image classification algorithm for deep active learning according to claim 1, characterized in that, In step 5, the sign that the training adjustment is completed is that the network reaches the specified performance or the unlabeled sample set X U is labeled completely.
9. An improved zinc flotation foam image classification algorithm for deep active learning according to claim 7, characterized in that, δ is set to 0.4, γ is set to 2, and β is set to 0.9999.
10. An improved zinc flotation foam image classification system for deep active learning, which is used to implement the improved deep active learning zinc flotation foam image classification algorithm described in claim 1, characterized in that, Including: An image sample collector for collecting zinc flotation process foam image samples; A training model acquisition module, using the improved fusion convolutional neural network model as the training model for flotation foam image classification; Training model initialization module, randomly selects an initial training set L=(x1, x2,......, x L , Y L ) with a sample size of n from the labeled sample set (X n ), inputs it into the training model, and performs initial training on the training model; The model annotation adjustment module selects an unlabeled sample set X through active learning U to annotate the samples in it and train and update the training model; A working condition recognition module, using the training model that has been updated after training to classify and recognize foam images.
Citation Information
Patent Citations
Material microscopic image and performance bidirectional prediction method based on deep learning
CN112101432A
Zinc flotation froth image segmentation algorithm based on improved U-Net network
CN113837193A