Soil identification method based on random forest and synthetic minority over-sampling technique

By improving random forest and synthetic minority class oversampling techniques, and combining them with the Grey Wolf algorithm to optimize parameters, the limitations of high-dimensional and nonlinear data processing in soil layer classification are overcome, thereby improving the accuracy and applicability of soil layer identification.

CN119622412BActive Publication Date: 2025-12-05CCCC FOURTH HARBOR ENG INST CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202411704945.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-26
Publication Date
2025-12-05
Estimated Expiration
2044-11-26

AI Technical Summary

Technical Problem

Traditional soil classification methods are inefficient when processing high-dimensional data, and the accuracy and consistency of the results are difficult to guarantee. Existing soil classification methods are complex and diverse, and have significant limitations when processing high-dimensional and nonlinear data. Furthermore, the imbalance of sample classes leads to insufficient ability of the classifier to identify the minority class.

Method used

An improved random forest algorithm and synthetic minority class oversampling technique were adopted. The hyperparameters of the random forest were optimized by the gray wolf algorithm. Combined with underwater deep cement mixing pile data and expert evaluation method, a balanced sample dataset was generated to build a classification model to improve the soil layer identification accuracy.

Benefits of technology

It effectively solves the problem of data imbalance in soil layer classification, improves the model's ability to identify a minority of soil layers, enhances the model's generalization ability and classification accuracy, and is suitable for different soil layer identification scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119622412B_ABST
    Figure CN119622412B_ABST
Patent Text Reader

Abstract

The application provides a soil layer identification method based on a random forest and a synthetic minority over-sampling technique, is suitable for the field of soil layer identification, and comprises the following steps: collecting data based on underwater deep cement mixing piles, data processing, obtaining balanced sample data sets, data preparation, obtaining optimal random forest algorithm parameters, constructing a classification model, classification model testing and optimization, and model application; the method provides a soil layer identification method based on a random forest and a synthetic minority over-sampling technique, has high classification precision and wide applicability, and can be widely applied to the field of soil layer identification.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to a soil layer identification method based on random forest and synthetic minority over-sampling technique, and is suitable for the field of soil layer identification. BACKGROUND

[0002] In civil engineering and geotechnical engineering, soil classification is a key link in foundation engineering design and construction. Accurate soil classification helps to optimize foundation treatment schemes, select appropriate construction methods, and improve engineering safety and stability. However, due to the complexity and diversity of soil layers, traditional soil classification methods have significant limitations in handling high-dimensional and nonlinear data. Traditional soil classification methods mainly rely on manual experience and conventional soil tests, which are inefficient in handling complex and variable soil data, and the accuracy and consistency of the results are difficult to guarantee. In addition, the problem of class imbalance in soil classification is also a challenge, as the minority class of soil samples accounts for a very low proportion in the data set, resulting in insufficient recognition ability of the classifier for the minority class.

[0003] In order to solve these problems, in recent years, machine learning technology has been introduced into soil classification. Among them, the random forest algorithm is widely used in soil classification tasks due to its strong nonlinear modeling ability and high robustness. Random forest can effectively improve classification accuracy by integrating multiple decision trees for voting decision. However, RF algorithm still has certain limitations in handling class imbalance problems. Synthetic minority over-sampling technique balances the class distribution of the data set by generating new minority class samples, thereby improving the recognition ability of the classifier for the minority class. Combining SMOTE with RF can significantly improve the performance of soil classification, but the classification accuracy of traditional random forest algorithm depends on the selection of parameters such as tree depth. Using grid search or random search algorithm will result in high computational complexity and low classification efficiency. In addition, SMOTE technology may introduce noise data when synthesizing samples, affecting the performance of the classifier.

[0004] In this context, the present application proposes a soil classification method based on improved random forest and synthetic minority over-sampling technique, which improves the classification performance, reduces the introduction of noise, and improves the classification efficiency of the classifier by using grey wolf algorithm to improve the hyperparameters of random forest. The improved random forest and synthetic minority over-sampling technique method is expected to make up for the shortcomings of existing methods and bring innovative solutions to soil identification problems. SUMMARY

[0005] The purpose of the present application is to solve some problems encountered in the introduction of machine learning technology into soil classification. A soil layer identification method based on random forest and synthetic minority over-sampling technique is proposed.

[0006] The object of the application can be achieved by adopting the following technical solutions:

[0007] The soil layer identification method based on the random forest and the synthetic minority over-sampling technique has the following steps:

[0008] S101, data collection based on underwater deep cement mixing piles;

[0009] The data collection based on underwater deep cement mixing piles includes collecting N sets of construction parameters of underwater deep mixing piles numbered X in the process of construction in the area to be identified, the time of obtaining each set of construction parameters being the same, the construction parameters including energy consumption W in the penetration stage, water content Q in the penetration stage, average speed V in the penetration stage, average current A in the penetration stage, and construction elevation H.

[0010] The data collection based on underwater deep cement mixing piles includes geological drilling detection near the underwater deep mixing pile numbered X, and obtaining elevation-based soil layer classification results by using an expert evaluation method.

[0011] S102, data processing;

[0012] The data processing includes adding labels to the N sets of construction parameters according to the construction elevation H in the N sets of construction parameters and the elevation-based soil layer classification results obtained by using the expert evaluation method, the labels representing soil layer classification results, and finally obtaining N sets of construction parameter data containing labels.

[0013] S103, obtaining an equalized sample data set;

[0014] The obtaining of the equalized sample data set includes adjusting the N sets of construction parameter data containing labels into an equalized sample construction parameter data set containing labels by using a synthetic minority over-sampling technique.

[0015] S104, data preparation;

[0016] The data preparation includes randomly dividing the equalized sample construction parameter data set containing labels into a training set and a test set according to a certain proportion.

[0017] S105, obtaining optimal random forest algorithm parameters;

[0018] The obtaining of the optimal random forest algorithm parameters includes obtaining optimal random forest algorithm parameters by using a grey wolf algorithm.

[0019] S106, constructing a classification model;

[0020] The construction of the classification model includes constructing a classification model according to the optimal random forest algorithm parameters.

[0021] S107, classification model testing and optimization;

[0022] The classification model is tested and improved, including inputting test set data into the classification model, obtaining model classification results, comparing the model classification results with the test set data labels to obtain test set test results, and optimizing according to the test set test results, and finally obtaining an optimized model;

[0023] S108 model application;

[0024] The model application includes using the optimized model for soil layer classification.

[0025] Further, in the step S102, each set of construction parameter data containing labels in the N sets of construction parameter data containing labels is a vector with a dimension of 1x6, corresponding to one output variable and five input variables, the one output variable is the label, and the five input variables are the energy consumption W of the down-penetration stage, the water content Q of the down-penetration stage, the average speed V of the down-penetration stage, the average current A of the down-penetration stage, and the construction elevation H.

[0026] Further, in the step S103, the step of adjusting the N sets of construction parameter data containing labels into a balanced sample construction parameter data set containing labels by using the SMOTE technology is:

[0027] a) For the N sets of construction parameter data containing labels, the number of construction parameter data of each label is counted, and the construction parameter data group of the minority class label is obtained according to the counting result, and the determination of the minority class label is determined by formula (1),

[0028] (1)

[0029] In the formula, N i is the number of construction parameter data groups of the minority class label i, N is the total number of construction parameter data groups, m is the total number of label categories, η is an adjustment coefficient, and the value is 0.5-0.8;

[0030] b) Randomly select a measurement set D from the construction parameter data group of the minority class label, calculate the Euclidean distance between the selected measurement set D and all the remaining measurement sets in the same label, and select the first Y nearest neighbors of the measurement set D with the smallest Euclidean distance;

[0031] c) Randomly select a measurement set E from the Y nearest neighbors of the test set D,

[0032] d) Generate a random variable µ between 0 and 1, and generate a new synthetic data set F based on the linear interpolation method by formula (2),

[0033] (2)

[0034] e) adding the new data set F according to its label to the corresponding N groups of construction parameter data containing labels to expand the data, repeating steps a) to d), and finally obtaining the balanced sample construction parameter data set containing labels.

[0035] Further, in the step S105, the step of obtaining the optimal random forest algorithm parameter by using the grey wolf algorithm is:

[0036] a) initializing the grey wolf punch, each grey wolf containing a random forest model hyperparameter combination;

[0037] b) calculating the fitness value of each grey wolf by using the fitness function, and the fitness function uses formula (3),

[0038] (3)

[0039] In the formula, N1 is the number of correct classifications of the training set by using the hyperparameter combination contained in the grey wolf to construct the random forest model for label classification;

[0040] c) determining the current optimal solution, optimal solution and suboptimal solution according to the calculation result of the fitness value;

[0041] d) updating the positions of the remaining grey wolves, repeating the process of calculating the fitness and updating the position until the predetermined number of iterations or the fitness converges;

[0042] e) after the iteration is completed, the position of the grey wolf with the highest fitness is selected as the optimal random forest algorithm parameter.

[0043] The present application has the following beneficial effects: by using the synthetic minority oversampling technique (SMOTE) to balance the construction parameter data, the problem of data imbalance can be effectively solved, the recognition ability of the model for the minority class of soil layers can be improved, and thus the overall classification precision is improved; by optimizing the parameters of the random forest algorithm by using the grey wolf algorithm, the characteristics of the soil layers can be more effectively learned from the data, the generalization ability of the model is enhanced, and the model can also make accurate classification on unobserved soil layer data. The method does not depend on specific soil structure or autocorrelation function assumptions, has good universality, and can be widely applied to different soil layer identification scenarios. BRIEF DESCRIPTION OF DRAWINGS

[0044] Figure 1 The flowchart of the soil layer identification method based on random forest and synthetic minority oversampling technique of the present application. DETAILED DESCRIPTION

[0045] The specific embodiments of the present application will be described in detail below with reference to the accompanying drawings; it should be understood that the specific embodiments given herein are only for illustration and explanation of the present application, and cannot be used to limit the present application.

[0046] The following is a specific embodiment of a soil layer identification method based on a random forest and a synthetic minority over-sampling technique.

[0047] The soil layer identification method based on a random forest and a synthetic minority over-sampling technique comprises the following steps:

[0048] S101: Collecting data based on underwater deep cement mixing piles;

[0049] The collecting data based on underwater deep cement mixing piles comprises collecting N sets of construction parameters of underwater deep mixing piles numbered X in a to-be-identified soil layer area during construction, the time of obtaining each set of construction parameters being the same, and the construction parameters comprising energy consumption W in a penetration stage, water content Q in the penetration stage, average speed V in the penetration stage, average current A in the penetration stage, and construction elevation H.

[0050] The collecting data based on underwater deep cement mixing piles comprises performing geological drilling detection near the underwater deep mixing piles numbered X, and obtaining an elevation-based soil layer classification result by using an expert evaluation method.

[0051] S102: Data processing;

[0052] The data processing comprises adding labels to the N sets of construction parameters according to the construction elevation H in the N sets of construction parameters and the elevation-based soil layer classification result obtained by using the expert evaluation method, the labels representing soil layer classification results, and finally obtaining N sets of construction parameter data containing labels.

[0053] Further, in the step S102, each set of construction parameter data containing labels in the N sets of construction parameter data containing labels is a vector with a dimension of 1x6, corresponding to one output variable and five input variables, the one output variable being a label, and the five input variables being energy consumption W in a penetration stage, water content Q in the penetration stage, average speed V in the penetration stage, average current A in the penetration stage, and construction elevation H.

[0054] S103: Obtaining an equalized sample data set;

[0055] The obtaining an equalized sample data set comprises adjusting the N sets of construction parameter data containing labels into an equalized sample construction parameter data set containing labels by using a synthetic minority over-sampling technique.

[0056] Further, in the step S103, the step of adjusting the N sets of construction parameter data containing labels into an equalized sample construction parameter data set containing labels by using a synthetic minority over-sampling technique comprises the following steps:

[0057] a) For the N groups of construction parameter data containing labels, count the number of construction parameter data of each label, and obtain the construction parameter data group of the minority class label according to the counting result, the determination of the minority class label uses formula (1),

[0058] (1)

[0059] wherein, N i is the number of construction parameter data groups of the minority class label i, N is the total number of construction parameter data groups, m is the total number of label categories, η is an adjustment coefficient, and the value is 0.5-0.8;

[0060] b) Randomly select a measurement set D from the construction parameter data group of the minority class label, calculate the Euclidean distance between the selected measurement set D and all the remaining measurement sets in the same label, and select the first Y measurement sets with the smallest Euclidean distance as the Y nearest neighbors of the measurement set D;

[0061] c) Randomly select a measurement set E from the Y nearest neighbors of the test set D,

[0062] d) Generate a random variable µ between 0 and 1, and generate a new synthetic data set F based on the linear interpolation method through formula (2),

[0063] (2)

[0064] e) Add the new data set F to the corresponding N groups of construction parameter data containing labels according to its label to expand the data, repeat steps a) to d), and finally obtain the balanced sample construction parameter data set containing labels.

[0065] S104 data preparation;

[0066] The data preparation includes randomly dividing the balanced sample construction parameter data set containing labels into a training set and a test set according to a certain proportion;

[0067] S105 obtaining optimal random forest algorithm parameters;

[0068] The obtaining of the optimal random forest algorithm parameters includes obtaining the optimal random forest algorithm parameters by using a grey wolf algorithm; further, in the above step S105, the step of obtaining the optimal random forest algorithm parameters by using the grey wolf algorithm is:

[0069] a) Initialize the grey wolf fist, and each grey wolf contains a random forest model hyperparameter combination;

[0070] b) Calculate the fitness value of each grey wolf by using a fitness function, and the fitness function uses formula (3),

[0071] (3)

[0072] In the formula, N1 is the number of correct classifications of the training set by the random forest model constructed using the hyperparameter combination containing the gray wolf;

[0073] c) determining the current optimal solution, the optimal solution and the suboptimal solution according to the fitness value calculation result;

[0074] d) updating the positions of the remaining gray wolves, repeating the process of calculating fitness and updating positions until a predetermined number of iterations or fitness convergence is reached;

[0075] e) after the iteration is completed, the position of the gray wolf with the highest fitness is selected as the optimal random forest algorithm parameter.

[0076] S106 constructs a classification model;

[0077] The construction of the classification model comprises constructing a classification model according to the optimal random forest algorithm parameter;

[0078] S107 tests and optimizes the classification model;

[0079] The classification model testing and improvement comprises inputting test set data into the classification model, obtaining model classification results, comparing the model classification results with the test set data labels to obtain test set test results, and optimizing according to the test set test results, and finally obtaining an optimized model;

[0080] S108 applies the model;

[0081] The model application comprises using the optimized model for soil layer classification.

[0082] In the above embodiment, the present application discloses a soil layer identification method based on random forest and synthetic minority over-sampling technique, comprising collecting data based on underwater deep cement mixing pile, data processing, obtaining balanced sample data set, data preparation, obtaining optimal random forest algorithm parameter, constructing classification model, classification model testing and optimization, model application; the method proposes a soil layer identification method based on random forest and synthetic minority over-sampling technique, which has high classification accuracy and wide applicability, and can be widely applied in the field of soil layer identification.

[0083] The above is the preferred embodiment of the present application, which does not limit the present application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principles of the present application shall be included in the protection scope of the present application.

Claims

1. A soil layer identification method based on a random forest and a synthetic minority over-sampling technique, characterized by, The method comprises the following steps: S101 collecting data based on underwater deep cement mixing piles; The data based on the underwater deep cement mixing piles comprises collecting N sets of construction parameters of the underwater deep mixing pile No. X in the construction process in the to-be-identified soil layer, the time of obtaining each set of construction parameters being the same, the construction parameters comprising energy consumption W in the penetration stage, water content Q in the penetration stage, average speed V in the penetration stage, average current A in the penetration stage, and construction elevation H; The data based on the underwater deep cement mixing piles comprises performing geological drilling detection near the underwater deep mixing pile No. X, and obtaining an elevation-based soil layer classification determination result by using an expert evaluation method; S102 data processing; The data processing comprises adding labels to the N sets of construction parameters according to the construction elevation H in the N sets of construction parameters and the elevation-based soil layer classification determination result obtained by using the expert evaluation method, the labels representing soil layer classification determination results, and finally obtaining N sets of construction parameter data containing labels; S103 obtaining a balanced sample data set; The obtaining of the balanced sample data set comprises adjusting the N sets of construction parameter data containing labels into a balanced sample construction parameter data set containing labels by using a synthetic minority over-sampling technique; The step of adjusting the N sets of construction parameter data containing labels into the balanced sample construction parameter data set containing labels by using the synthetic minority over-sampling technique comprises the following steps: a) for the N sets of construction parameter data containing labels, counting the number of construction parameter data of each label, and obtaining a minority class label construction parameter data set according to the counting result, wherein the minority class label is determined by using formula (1), (1) In the formula, N i is the number of construction parameter data sets of the minority class label i, N is the total number of construction parameter data sets, m is the total number of label categories, η is an adjustment coefficient, and the value is 0.5-0.

8. b) randomly selecting a measurement set D from the minority class label construction parameter data set, calculating the Euclidean distance between the selected measurement set D and all the remaining measurement sets in the same label, and selecting the first Y nearest neighbors of the measurement set D as the Y nearest neighbors of the measurement set D with the minimum Euclidean distance; c) randomly selecting a measurement set E from the Y nearest neighbors of the measurement set D, d) generating a random variable µ between 0 and 1, and generating a new synthetic data set F based on the linear interpolation method by using formula (2), (2) e) adding the new data set F to the corresponding N sets of construction parameter data containing labels according to the label of the new data set F to expand the data, repeating steps a) to d), and finally obtaining a balanced sample construction parameter data set containing labels; S104 data preparation; The data preparation comprises randomly dividing the balanced sample construction parameter data set containing labels into a training set and a test set according to a certain proportion; S105 obtaining optimal random forest algorithm parameters; The obtaining of the optimal random forest algorithm parameters comprises obtaining the optimal random forest algorithm parameters by using a grey wolf algorithm; S106 constructing a classification model; The constructing of the classification model comprises constructing a classification model according to the optimal random forest algorithm parameters; S107 classification model testing and optimization; The classification model is tested and improved, including inputting test set data into the classification model, obtaining model classification results, comparing the model classification results with test set data labels to obtain test set test results, and optimizing according to the test set test results, and finally obtaining an optimized model; S108 model application; The model application includes using the optimized model for soil layer classification. 2.The soil layer identification method based on random forest and synthetic minority over-sampling technique according to claim 1, wherein, In the step S102, each set of construction parameter data containing a label in the N sets of construction parameter data containing a label is a vector with a dimension of 1x6, corresponding to one output variable and five input variables. The one output variable is the label, and the five input variables are the energy consumption W, water content Q, average speed V, average current A, and construction elevation H of the next stage. 3.The soil layer identification method based on random forest and synthetic minority over-sampling technique according to claim 1, wherein, In the step S105, the step of obtaining the optimal random forest algorithm parameter by using the grey wolf algorithm is: a) initialize the grey wolf punch, each grey wolf contains a random forest model hyperparameter combination; b) calculate the fitness value of each grey wolf by using the fitness function, and the fitness function uses formula (3), (3) In the formula, N1 is the number of correct classifications of the random forest model constructed by using the hyperparameter combination contained in the grey wolf to classify the labels of the training set; c) determine the current optimal solution, optimal solution and suboptimal solution according to the calculation result of the fitness value; d) update the positions of the remaining grey wolves, repeat the process of calculating the fitness and updating the position, until the predetermined number of iterations or the fitness converges; e) after the iteration is completed, the position of the grey wolf with the highest fitness is selected as the optimal random forest algorithm parameter.

Citation Information

Patent Citations

  • Stratum recognition method based on trenchless while-drilling parameter machine learning

    CN112381938A

  • Deep cement mixing pile soil layer identification method, system, equipment and medium

    CN117328441A

  • Self-adaptive dividing method for small, medium and micro-sized enterprise scales and industry characteristics

    CN117725518A

  • Transformer fault diagnosis method based on oversampling

    CN117972556A

  • Oversampling method for processing unbalanced classification problem

    CN118133005A