Foam video key frame extraction method based on average flow velocity of foam
By establishing a fuzzy relationship model between the average foam flow rate and the optimal sampling time interval in the foam flotation technology, the foam video keyframe sequence is extracted, and the problem of relying on manual observation and large amount of CNN models in the existing technology is solved, and the more Efficient working conditions identification and resource utilization.
Patent Information
- Application Number
- CN202411050997.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-01
- Publication Date
- 2024-11-01
AI Technical Summary
The existing foam flotation technology lacks effective mathematical models to describe the flotation process, resulting in production relying on manual observation, low accuracy, serious resource waste, and large parameters of the foam video CNN model and slow inference speed, making it difficult to be effective in industry. deploy.
A bubble video keyframe extraction method based on the average foam flow rate is proposed. By collecting foam video data on site, a fuzzy relationship model between the average foam flow rate and the optimal sampling time interval is established, the optimal sampling interval under different flow rates is determined, and the foam video is extracted. Keyframe sequences, reducing model parameters and improving recognition accuracy.
It realizes accurate identification of working conditions under complex and changeable flotation conditions, reduces the difficulty of model deployment, improves identification accuracy and operation speed, and reduces information redundancy.
Smart Images

Figure CN118887586A_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the field of foam flotation technology, and specifically relates to a foam video key frame extraction method based on foam average flow velocity Background Art
[0002] Froth flotation is one of the most commonly used separation methods in the ore beneficiation process, and it is widely used in my country and even internationally. Froth flotation separates valuable mineral particles from waste rock or other non-valuable minerals by utilizing the differences in the physical and chemical properties of the mineral surface (mainly hydrophilicity and hydrophobicity). It has the advantages of strong flexibility, wide application range, good beneficiation effect, etc., and can help improve the recovery rate and metal grade of the ore. However, due to the extremely complex physical and chemical processes involved in the flotation process, it has the characteristics of long flotation process, unclear internal mechanism, many external interference factors, and serious nonlinearity. Although domestic and foreign scholars have conducted a lot of research in recent years, there is still no effective and applicable mathematical model to describe the flotation process. The analysis and modeling of the flotation process is still a problem that needs to be solved urgently. For a long time, the flotation process mainly relies on the manual naked eye observation of the foam state on the surface of the flotation tank to complete the on-site operation. This production method relies heavily on the workers' experience and knowledge, is highly subjective, and has low accuracy, resulting in frequent fluctuations in flotation production indicators, serious loss of mineral raw materials, large consumption of reagents, and low resource recovery rate. Foam video is an indicator of the state and change of the surface foam of flotation, and is the main basis for monitoring the key performance indicators of flotation. However, the duration of foam video is long, the image quality requirements are high, the image resolution is large, the parameters of the CNN model based on foam video are large, the reasoning speed is slow, and the configuration requirements of industrial computers are high, which makes it difficult to deploy effectively in actual industrial applications. By analyzing the relationship between each frame of the foam video and the key performance indicators of flotation, extracting the key frame sequence that is most closely related to the key performance indicators of flotation, and maximizing the coverage of the static and dynamic characterization information of the original foam video, it is an important measure to reduce the number of parameters of the foam video CNN model. However, the foam flotation working conditions are changeable, and there are differences in the foam flow rate between different flotation cells and at different times of the same flotation cell. The requirements for the key frame sequence of foam video at different flow rates are different. For example, the foam flow rate of the scanning cell is fast, and the state of the foam on the surface of the flotation cell changes rapidly. The frames of the key frame sequence should have a small sampling interval to meet the needs of rapidly changing working conditions. In the flotation industrial process, foam video is an important data reflecting the current flotation working conditions and the basis for monitoring the key performance indicators of flotation. The CNN model based on foam video has a large number of parameters, slow inference speed, and high requirements for industrial computer configuration, making it difficult to deploy effectively in actual industrial applications. At the same time, there are many frames with little information in the foam video. If all the frames in the video are processed, it will cause serious information redundancy. However, the foam flotation conditions are changeable, and there are differences in foam flow rates between different flotation cells and at different times in the same flotation cell. The requirements for foam video key frame sequences at different flow rates are different, so general sampling operations cannot meet the needs of flotation key performance indicator monitoring. Summary of the invention
[0003] The purpose of the present invention is to propose a new method for extracting key frames of foam videos based on the average flow velocity of foam. A new method for extracting key frames of foam videos based on the average flow velocity of foam is proposed. The present invention collects foam videos based on a foam video acquisition system set up on site, extracts the average flow velocity of the foam video, establishes a fuzzy relationship model between the average flow velocity of foam and the optimal sampling time interval, obtains the optimal sampling time interval under different foam flow velocities, and then obtains a foam video key frame sequence.
[0004] The technical solution steps adopted are as follows:
[0005] Step 1: Use the image acquisition system at the flotation site to collect zinc flotation foam video data, pre-process the collected data, and form a zinc flotation data set;
[0006] Step 2: Sample the original zinc flotation video at equal intervals to obtain the original foam video image frame sequence S0 = {I1, I2, I3, ..., I M}
[0007] Step 3: Select different sampling intervals, perform multiple equal-interval sampling on the original foam video image frame sequence S0, and record the sampling interval as △k to obtain the original foam video image frame sequence S △k , as shown below:
[0008] S △k ={I1,I 1+△k ,I 1+2△k ,…,I 1+(α-1)△k},△k=1…△N
[0009] Among them I 1+(α-1)△k It represents the data of a single video frame, α is the number of candidate key frames of the foam video, and △N is the maximum sampling interval;
[0010] Step 4: The candidate key frame sequences {S △k ,△k=1…△N} is fed into the 3D convolutional network to obtain the loss error {δ △k ,△k=1…△N}, as shown in the following formula:
[0011] δ △k =Conv3D(S △k ),△k=1…△N
[0012] Among them, Conv3D(·) is a 3D convolutional neural network;
[0013] Step 5: Use the elbow plot method to analyze and calculate the model loss distribution under different sampling intervals to determine the optimal sampling time interval
[0014]
[0015] Step 6: Select the SURF algorithm, and extract the foam flow velocity of each frame from the original foam video image frame sequence S0 = {I1, I2, I3, …, I M}, and calculate the average flow velocity of the foam video
[0016] S1: Extract two consecutive frames of images from the original foam video image frame sequence, extract SURF features from each frame of foam image, and obtain SURF operator descriptors v0 and v1;
[0017] S2: According to the definition of the Euclidean distance, calculate the nearest distance d0 and the second nearest distance d1 between v0 and v1, and define the ratio between the nearest distance d0 and the second nearest distance d1 as the threshold When ratio < gate, the feature matching is successful, otherwise it fails;
[0018] S3: According to the feature point matching results of the two frames of foam images, use the ransac algorithm to remove the mismatched points;
[0019] S4: According to the matching results after removing the mismatched points and the pixel point differences between the matching points of the two frames of images, obtain the foam displacement, and divide by the unit time to obtain the speed set of the successfully matched points in the two consecutive frames of images; Take the average value of the speed set of the matching points as the speed v1 of these two consecutive foam images;
[0020] S5: Repeat the steps of S2 - S4 to extract the speeds of the remaining frames of the foam video, and obtain the inter-frame speed set V = {v1, v2, … v M};
[0021] S6: Calculate the average value in the inter-frame speed set of the video as the average speed of the foam video;
[0022] Step 7: Denote S v as the set of average foam flow velocities generated by the foam video, and S △ as the set of optimal sampling time intervals. Use the type-2 fuzzy logic algorithm Type-2TSK(·) to establish a fuzzy relationship model FuzzyModel between the average foam flow velocity and the optimal sampling time interval, including an input layer, a fuzzification layer, a fuzzy inference layer, and an output layer;
[0023] S1: Construct a fuzzy input layer. The input layer takes the average foam flow velocity of each video in S v as the input u, and the optimal time interval as the output y;
[0024] S2: Select the Gaussian interval type II membership function with uncertain width as the upper and lower membership functions of the fuzzification layer, as shown in the following formula:
[0025]
[0026] Among them, a is the central upper bound of the Gaussian membership function, b is the central lower bound of the Gaussian membership function, σ1 and σ2 are the widths of the Gaussian membership function, and Represent the fuzzy set A i The upper and lower bounds of the membership function under input u;
[0027] S3: Construct the fuzzy reasoning layer; let the output variable be y(u), and the model uses the complete type-2 fuzzy rule base as follows:
[0028]
[0029] Where n is the number of input conditions, is a type-2 fuzzy set about the input u, is the interval weight of the rule consequent;
[0030] S4: construct the output layer; use the type-2 fuzzy system mean downsizer to complete the downsizing, the mean downsizer The formula is expressed as follows:
[0031]
[0032] The output y is calculated using the centroid method, as shown below:
[0033]
[0034] Step 8: Average the foam video flow rate Enter the FuzzyModel created in step 7 to obtain the optimal interval time As shown below:
[0035]
[0036] Step 9: Based on the optimal time interval obtained in step 8 Using equal interval sampling, the original foam video image frame sequence S0 = {I1, I2, I3, ..., I M Extract key frame sequence from As shown below:
[0037]
[0038] Wherein, α is the total number of key frames of the foam video.
[0039] The gate range in step six S4 is gate∈[0.65,0.95].
[0040] The foam video acquisition system based on the on-site setting proposed in the present invention acquires foam video, obtains original foam video image frame data by equal-interval sampling, obtains the optimal sampling time interval by using the elbow diagram method, extracts the average flow velocity of the foam video by using the SURF algorithm, and establishes a fuzzy relationship model between the average flow velocity of the foam and the optimal sampling time interval in a data-driven form. The model takes the foam video flow velocity as input and outputs the optimal sampling time interval. According to the optimal sampling time interval, the original foam video is sampled at equal intervals, and the foam video key frame sequence is adaptively obtained. The foam key frame sequence is used as the input of the flotation key performance detection model for verification, and the results show that in the working condition identification task, the extracted key frame sequence helps to reduce the parameters of the model and improve the accuracy of working condition identification. The verification results show that the present invention can fully express the static and dynamic characteristics of the foam video and accurately identify the working condition while reducing the difficulty of model deployment. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] Figure 1 Flowchart of the foam video key frame extraction method based on the average foam flow velocity. DETAILED DESCRIPTION
[0042] Figure 1 It is a flow chart of the present invention.
[0043] Step 1: Use the image acquisition system at the flotation site to collect zinc flotation foam video data and pre-process the collected data as follows:
[0044] 1) Eliminate erroneous data that exceeds the normal change threshold;
[0045] 2) Eliminate the collection of fuzzy data;
[0046] Step 2: Sample the original zinc flotation video at equal intervals to obtain the original foam video image frame sequence S0 = {I1, I2, I3, ..., I M}
[0047] Step 3: Select different sampling intervals, perform multiple equal-interval sampling on the original foam video image frame sequence S0, and record the sampling interval as △k to obtain the original foam video image frame sequence S △k , as shown below:
[0048] S △k ={I1,I 1+△k ,I 1+2△k ,…,I 1+(α-1)△k},△k=1…△N
[0049] Among them I1+(α-1)△k It represents single-frame video data. α is the number of frames of the candidate key frames of the foam video, and △N is the maximum sampling interval;
[0050] Step Four: Send the candidate key frame sequences {S △k , △k = 1…△N} under different sampling intervals into the 3D convolutional network to obtain the loss errors {δ △k , △k = 1…△N}, as shown in the following formula:
[0051] δ △k = Conv3D(S △k ), △k = 1…△N
[0052] where Conv3D(·) is the 3D convolutional neural network;
[0053] Step Five: Use the elbow method to analyze and calculate the model loss distribution under different sampling intervals to determine the optimal sampling time interval
[0054]
[0055] Step Six: Select the SURF algorithm to extract the foam flow velocity of each frame from the original foam video image frame sequence S0 = {I1, I2, I3, …, I M}, and calculate the average flow velocity of the foam video
[0056] S1: Extract two consecutive frames of images from the original foam video image frame sequence, extract SURF features from each frame of foam image to obtain the SURF operator descriptor v0 and v1;
[0057] S2: According to the definition of the Euclidean distance, calculate the nearest distance d0 and the second nearest distance d1 between v0 and v1, and define the ratio between the nearest distance d0 and the second nearest distance d1 as the threshold Set the threshold gate = 0.7. When ratio < gate, the feature matching is successful, otherwise it fails;
[0058] S3: According to the feature point matching results of the two frames of foam images, use the ransac algorithm to remove the mismatched points;
[0059] S4: According to the matching results after removing the mismatched points and the pixel point difference between the matching points of the two frames of images, obtain the foam displacement, and divide by the unit time to obtain the speed set of the successfully matched points in the two consecutive frames of images. Take the average value of the speed set of the matching points as the speed v1 of these two consecutive frames of foam images.
[0060] S5: Repeat steps S2-S4 to extract the speed of the remaining frames of the bubble video, and obtain the video frame speed set V = {v1, v2, ... v M}.
[0061] S6: Calculate the mean of the speed concentration between video frames As the average speed of the bubble video. Step 7: Record S v The mean set of foam velocity generated for the foam video, S △ For the optimal sampling time interval set, the type-2 fuzzy logic algorithm Type-2TSK(·) is used to establish the fuzzy relationship model FuzzyModel between the average foam flow rate and the optimal sampling time interval, which includes input layer, fuzzification layer, fuzzy reasoning layer and output layer.
[0062] S1: Construct the fuzzy input layer. The input layer is S v The average foam flow rate of each video in is taken as input u, and the optimal time interval is taken as output y;
[0063] S2: Select the Gaussian interval type II membership function with uncertain width as the upper and lower membership functions of the fuzzification layer, as shown in the following formula:
[0064]
[0065] Among them, a is the central upper bound of the Gaussian membership function, b is the central lower bound of the Gaussian membership function, σ1 and σ2 are the widths of the Gaussian membership function, and Represent the fuzzy set A i The upper and lower bounds of the membership function under input u;
[0066] S3: Construct the fuzzy reasoning layer; let the output variable be y(u), and the model uses the complete type-2 fuzzy rule base as follows:
[0067]
[0068] Where n is the number of input conditions, is a type-2 fuzzy set about the input u, is the interval weight of the rule consequent.
[0069] S4: construct the output layer; use the type-2 fuzzy system mean downsizer to complete the downsizing, the mean downsizer The formula is expressed as follows:
[0070]
[0071] The output y is calculated using the centroid method, as shown below:
[0072]
[0073] Step 8: Average the foam video flow rate Enter the FuzzyModel created in step 7 to obtain the optimal interval time As shown below:
[0074]
[0075] Step 9: Based on the optimal time interval obtained in step 8 The original foam video image frame sequence S0 = {I1, I2, I3, ..., I M Extract key frame sequence from As shown below:
[0076]
[0077] Among them, α is the total number of key frames of the foam video;
[0078] Step 10: Extract the key frame sequence As input, it is input into the ResNet-50 model to complete the working condition recognition task. Compared with the original video frame sequence, the model accuracy is improved by 9.12% and the model running speed is improved by 20.13%.
[0079] The present invention proposes a foam video key frame extraction method based on the average foam flow rate, which is used to extract the key frame sequence in the foam video. In view of the complex and changeable characteristics of flotation working conditions, different sampling frequencies are determined according to the different foam flow rates, which can meet the requirements of different working condition performance index detection tasks, speed up the running speed of the model, and reduce the difficulty of model deployment. Experiments have verified that our method can accurately judge the working conditions and assist workers in making adjustments.
Claims
1. A foam video key frame extraction method based on foam average flow velocity, characterized in that: The following steps are involved: Step 1: Use the image acquisition system at the flotation site to collect zinc flotation foam video data, pre-process the collected data, and form a zinc flotation data set; Step 2: Sample the zinc flotation dataset video at equal intervals to obtain the original foam video image frame sequence S0 = {I1, I2, I3, …, I M }; Step 3: Select different sampling intervals, perform multiple equal-interval sampling on the original foam video image frame sequence S0, and record the sampling interval as △k to obtain the original foam video image frame sequence S △k , as shown below: S △k ={I1,I 1+△k ,I 1+2△k ,…,I 1+(α-1)△k },△k=1…△N Among them I 1+(α-1)△k It represents the data of a single video frame, α is the number of candidate key frames of the foam video, and △N is the maximum sampling interval; Step 4: The candidate key frame sequences {S △k ,△k=1…△N} is fed into the 3D convolutional network to obtain the loss error {δ △k ,△k=1…△N}, as shown in the following formula: d △k =Conv3D(S △k ),△k=1…△N Among them, Conv3D(·) is a 3D convolutional neural network; Step 5: Use the elbow plot method to analyze and calculate the model loss distribution under different sampling intervals to determine the optimal sampling time interval Step 6: Select the SURF algorithm and perform the original foam video image frame sequence S0 = {I1, I2, I3, ..., I M }Extract the foam flow rate of each frame and calculate the mean flow rate of the foam video S1: extract two consecutive frames of images from the original foam video image frame sequence, extract SURF features for each foam image frame, and obtain SURF operator description operators v0 and v1; S2: According to the definition of Euclidean distance, calculate the nearest distance d0 and the second-nearest distance d1 between v0 and v1, and define the ratio between the nearest distance d0 and the second-nearest distance d1 as the threshold Set the threshold gate. When ratio < gate, the feature matching is successful; otherwise, it fails. S3: According to the matching results of the feature points of the two foam images, the RANSAC algorithm is used to remove the mismatched points; S4: Obtain the foam displacement according to the matching result after removing the mismatched points and the pixel difference of the matching points between the two frames of images, and obtain the velocity set of the successfully matched points in the two consecutive frames of images by removing the unit time; and take the average value of the velocity set of the matching points as the velocity v1 of the two consecutive frames of foam images; S5: Repeat steps S2-S4 to extract the speed of the remaining frames of the bubble video, and obtain the video frame speed set V = {v1, v2, ... v M }; S6: Calculate the mean of the speed concentration between video frames As the average speed of the foam video; Step 7: Remember S v The mean set of foam velocity generated for the foam video, S △ For the optimal sampling time interval set, the type-2 fuzzy logic algorithm Type-2TSK(·) is used to establish the fuzzy relationship model FuzzyModel between the average foam flow rate and the optimal sampling time interval, including input layer, fuzzification layer, fuzzy reasoning layer and output layer; S1: Construct the fuzzy input layer. The input layer is S v The average foam flow rate of each video in is taken as input u, and the optimal time interval is taken as output y; S2: Select the Gaussian interval type II membership function with uncertain width as the upper and lower membership functions of the fuzzification layer, as shown in the following formula: Among them, a is the central upper bound of the Gaussian membership function, b is the central lower bound of the Gaussian membership function, σ1 and σ2 are the widths of the Gaussian membership function, and Represent the fuzzy set A i The upper and lower bounds of the membership function under input u; S3: Construct the fuzzy reasoning layer; let the output variable be y(u), and the model uses the complete type-2 fuzzy rule base as follows: Where n is the number of input conditions, is a type-2 fuzzy set about the input u, is the interval weight of the rule consequent; S4: construct the output layer; use the type-2 fuzzy system mean downsizer to complete the downsizing, the mean downsizer The formula is expressed as follows: The output y is calculated using the centroid method, as shown below: Step 8: Average the foam video flow rate Enter the FuzzyModel created in step 7 to obtain the optimal interval time As shown below: Step 9: Based on the optimal time interval obtained in step 8 The original foam video image frame sequence S0 = {I1, I2, I3, ..., I M Extract key frame sequence from As shown below: Wherein, α is the total number of key frames of the foam video.
2. The foam video key frame extraction method based on the foam average flow velocity according to claim 1, characterized in that: The gate range in step six S4 is gate∈[0.65,0.95].
Citation Information
Cited By
Mineral flotation fine bubble flow velocity online detection method and device based on bubble image
CN120431100A
Flotation froth flow velocity prediction method and device based on dynamic space-time attention fusion
CN120932046A
Flotation froth flow rate prediction method and device based on dynamic spatiotemporal attention fusion
CN120932046B
