跳至内容
首页Python

课程

Python 树模型机器学习

中级技能水平
更新时间 2025年12月
在本课程中,你将学习如何使用 scikit-learn 中的基于树的模型和集成方法进行回归和分类。
免费开始课程
PythonMachine Learning
5小时
15 视频
57 道练习
4,650 XP
110K+
成就证明

创建您的免费帐户

继续使用 Google显示更多选项


继续操作即表示您接受我们的《使用条款》和《隐私政策》,并同意您的数据存储在美国。

深受数千家公司学习者的喜爱

Group

需要团队培训?

企业版试用

课程描述

决策树是一类用于分类与回归问题的监督学习模型。树模型具有很强的灵活性,但也有代价:一方面,树能捕捉复杂的非线性关系;另一方面,它们容易记住数据集中的噪声。通过聚合以不同方式训练的多棵树的预测,集成方法既能利用树的灵活性,又能降低其记忆噪声的倾向。集成方法广泛应用于各个领域,并多次在机器学习竞赛中取得优胜。 在本课程中,您将学习如何使用 Python 结合易用的 scikit-learn 机器学习库来训练决策树和基于树的模型。您将理解树模型的优势与局限,并看到集成学习如何缓解这些问题,同时在真实数据集上进行练习。最后,您还将掌握如何调优最关键的超参数,以充分发挥模型性能。

先决条件

Supervised Learning with scikit-learn
1

Classification and Regression Trees

Classification and Regression Trees (CART) are a set of supervised learning models used for problems involving classification and regression. In this chapter, you'll be introduced to the CART algorithm.
开始章节
2

The Bias-Variance Tradeoff

The bias-variance tradeoff is one of the fundamental concepts in supervised machine learning. In this chapter, you'll understand how to diagnose the problems of overfitting and underfitting. You'll also be introduced to the concept of ensembling where the predictions of several models are aggregated to produce predictions that are more robust.
开始章节
3

Bagging and Random Forests

Bagging is an ensemble method involving training the same algorithm many times using different subsets sampled from the training data. In this chapter, you'll understand how bagging can be used to create a tree ensemble. You'll also learn how the random forests algorithm can lead to further ensemble diversity through randomization at the level of each split in the trees forming the ensemble.
开始章节
4

Boosting

Boosting refers to an ensemble method in which several models are trained sequentially with each model learning from the errors of its predecessors. In this chapter, you'll be introduced to the two boosting methods of AdaBoost and Gradient Boosting.
开始章节
5

Model Tuning

The hyperparameters of a machine learning model are parameters that are not learned from data. They should be set prior to fitting the model to the training set. In this chapter, you'll learn how to tune the hyperparameters of a tree-based model using grid search cross validation.
开始章节
Python 树模型机器学习
课程完成

获得成就证明

将此证书添加到您的 LinkedIn 档案、简历或履历中
在社交媒体和绩效评估中分享
立即注册

加入超过19百万学习者,今天就开始Python 树模型机器学习!

创建您的免费帐户

继续使用 Google显示更多选项


继续操作即表示您接受我们的《使用条款》和《隐私政策》,并同意您的数据存储在美国。

通过 DataCamp for Mobile 提升您的数据技能

随时随地通过我们的移动课程和每日 5 分钟编程挑战提升技能。