「弱」模型的威力

Python 的 Ensemble 方法

Román de las Heras

Data Scientist, Appodeal

「弱」模型

投票與平均:

  • 少量估計器
  • 精調的估計器
  • 個別訓練

新概念:「弱」 估計器

Python 的 Ensemble 方法

弱 vs 強.jpeg

Python 的 Ensemble 方法

「弱」模型的特性

弱估計器

  • 表現優於隨機猜測
  • 模型輕量
  • 訓練與評估時間短

例:Decision Tree

決策樹(弱).bmp

Python 的 Ensemble 方法

「弱」模型範例

一些「弱」模型:

  • 決策樹:小深度

  • Logistic Regression

  • Linear Regression

  • 其他受限模型

範例程式碼:

model = DecisionTreeClassifier(
    max_depth=3
)

model = LogisticRegression( max_iter=50, C=100.0 )
model = LinearRegression()
Python 的 Ensemble 方法

一起來練習吧!

Python 的 Ensemble 方法

Preparing Video For Download...