当前位置:网站首页>The difference between bagging and boosting in machine learning
The difference between bagging and boosting in machine learning
2022-07-04 04:05:00 【Xiaobai learns vision】
Click on the above “ Xiaobai studies vision ”, Optional plus " Star standard " or “ Roof placement ”
Heavy dry goods , First time delivery Bagging and Boosting All of them combine the existing classification or regression algorithms in a certain way , Form a more powerful classifier , More precisely, it's a way to assemble classification algorithms . The method of assembling weak classifiers into strong classifiers .
First introduced Bootstraping, Self help method : It's a sampling method with put back ( Duplicate samples may be drawn ).
1. Bagging (bootstrap aggregating)
Bagging The bagging method , The algorithm process is as follows :
The training set was extracted from the original sample set . Each round is used from the original sample set Bootstraping Method extraction n Training samples ( In training set , Some samples may be taken multiple times , Some samples may not be picked at all ). Together with k Round draw , obtain k Training set .(k The training sets are independent of each other )
One model at a time using one training set ,k A total of training sets k A model .( notes : There is no specific classification algorithm or regression method , We can adopt different classification or regression methods according to the specific problem , Such as the decision tree 、 Sensors etc. )
Pair classification problem : I'm going to go up k The classification results were obtained by voting ; Pair regression problem , The mean value of the above model is calculated as the final result .( All models are equally important )
2. Boosting
The main idea is to assemble the weak classifier into a strong classifier . stay PAC( The probability approximation is correct ) Under the learning framework , Then the weak classifier can be assembled into a strong classifier .
About Boosting The two core issues of this issue :
2.1 How to change the weight or probability distribution of training data in each round ?
By increasing the weight of the samples that were divided by the weak classifier in the previous round , Reduce the weight of the previous round of pairing samples , So that the classifier has a better effect on the misclassified data .
2.2 How to combine weak classifiers ?
The weak classifiers are combined linearly through the additive model , such as AdaBoost By a weighted majority , That is to increase the weight of the classifier with small error rate , At the same time, the weight of the classifier with high error rate is reduced .
The lifting tree gradually reduces the residual by fitting the residual , The final model is obtained by superimposing the models generated in each step .
3. Bagging,Boosting The difference between the two
Bagging and Boosting The difference between :
1) Sample selection :
Bagging: The training set is selected from the original set , The training sets selected from the original set are independent of each other .
Boosting: The training set of each round is the same , Only the weight of each sample in the classifier changes in the training set . And the weight is adjusted according to the last round of classification results .
2) Sample weights :
Bagging: Use uniform sampling , The weight of each sample is equal
Boosting: Adjust the weight of the sample according to the error rate , The greater the error rate, the greater the weight .
3) Prediction function :
Bagging: All prediction functions have equal weight .
Boosting: Each weak classifier has its own weight , For the classifier with small classification error, it will have more weight .
4) Parallel computing :
Bagging: Each prediction function can be generated in parallel
Boosting: Each prediction function can only be generated in sequence , Because the latter model parameter needs the result of the previous model .
4. summary
These two methods are to integrate several classifiers into one classifier , It's just that the way of integration is different , In the end, we get a different effect , The application of different classification algorithms into this kind of algorithm framework will improve the classification effect of the original single classifier to a certain extent , But it also increases the amount of computation .
Here is a new algorithm that combines decision tree with these algorithm frameworks :
Bagging + Decision tree = Random forests
AdaBoost + Decision tree = Ascension tree
Gradient Boosting + Decision tree = GBDT
download 1:OpenCV-Contrib Chinese version of extension module
stay 「 Xiaobai studies vision 」 Official account back office reply : Extension module Chinese course , You can download the first copy of the whole network OpenCV Extension module tutorial Chinese version , cover Expansion module installation 、SFM Algorithm 、 Stereo vision 、 Target tracking 、 Biological vision 、 Super resolution processing And more than 20 chapters .
download 2:Python Visual combat project 52 speak
stay 「 Xiaobai studies vision 」 Official account back office reply :Python Visual combat project , You can download the Image segmentation 、 Mask detection 、 Lane line detection 、 Vehicle count 、 Add Eyeliner 、 License plate recognition 、 Character recognition 、 Emotional tests 、 Text content extraction 、 face recognition etc. 31 A visual combat project , Help fast school computer vision .
download 3:OpenCV Actual project 20 speak
stay 「 Xiaobai studies vision 」 Official account back office reply :OpenCV Actual project 20 speak , You can download the 20 Based on OpenCV Realization 20 individual Actual project , Realization OpenCV Learn advanced .
Communication group
Welcome to join the official account reader group to communicate with your colleagues , There are SLAM、 3 d visual 、 sensor 、 Autopilot 、 Computational photography 、 testing 、 Division 、 distinguish 、 Medical imaging 、GAN、 Wechat groups such as algorithm competition ( It will be subdivided gradually in the future ), Please scan the following micro signal clustering , remarks :” nickname + School / company + Research direction “, for example :” Zhang San + Shanghai Jiaotong University + Vision SLAM“. Please note... According to the format , Otherwise, it will not pass . After successful addition, they will be invited to relevant wechat groups according to the research direction . Do not Send ads within the group , Or you'll be invited out , Thanks for your understanding ~


边栏推荐
- Penetration practice - sqlserver empowerment
- super_ Subclass object memory structure_ Inheritance tree traceability
- Third party login initial version
- EV6 helps the product matrix, and Kia is making efforts in the high-end market. The global sales target in 2022 is 3.15 million?
- 三年进账35.31亿,这个江西老表要IPO了
- 用于TCP协议交互的TCPClientDemo
- [PaddleSeg 源码阅读] PaddleSeg计算Dice
- 支持首次触发的 Go Ticker
- PostgreSQL users cannot create table configurations by themselves
- XSS prevention
猜你喜欢

Third party login initial version

三菱M70宏变量读取三菱M80公共变量采集三菱CNC变量读取采集三菱CNC远程刀补三菱机床在线刀补三菱数控在线测量

EV6 helps the product matrix, and Kia is making efforts in the high-end market. The global sales target in 2022 is 3.15 million?

Two sides of the evening: tell me about the bloom filter and cuckoo filter? Application scenario? I'm confused..

10 reasons for not choosing to use free virtual hosts

MySQL one master multiple slaves + linear replication

Typical applications of minimum spanning tree

图解网络:什么是热备份路由器协议HSRP?

Management and thesis of job management system based on SSM

Msgraphmailbag - search only driveitems of file types
随机推荐
Katalon framework tests web (XXI) to obtain element attribute assertions
[paddleseg source code reading] paddleseg custom data class
AAAI2022 | Word Embeddings via Causal Inference: Gender Bias Reducing and Semantic Information Preserving
Brief explanation of depth first search (with basic questions)
"Implement both software and hardware" to help build a new cloud computing data center
idea修改主体颜色
Katalon框架测试web(二十一)获取元素属性断言
[PaddleSeg 源码阅读] PaddleSeg Transform 的 Normalize操作
用于TCP协议交互的TCPClientDemo
Recursive structure
Why is it recommended that technologists write blogs?
Infiltration practice guest account mimikatz sunflower SQL rights lifting offline decryption
Objective C attribute keyword
Mitsubishi M70 macro variable reading Mitsubishi M80 public variable acquisition Mitsubishi CNC variable reading acquisition Mitsubishi CNC remote tool compensation Mitsubishi machine tool online tool
Objective-C member variable permissions
laravel admin里百度编辑器自定义路径和文件名
Future源碼一觀-JUC系列
1289_FreeRTOS中vTaskSuspend()接口实现分析
Leecode 122. Zuijia timing of buying and selling stocks ②
A review of reverse reinforcement learning at Virginia Tech (VT)