Chọn mô hình: mô hình ensemble

Luyện tập câu hỏi phỏng vấn Machine Learning bằng Python

Lisa Stuart

Data Scientist

Bootstrapping

Lấy mẫu bootstrap

1 https://medium.com/@rrfd/boosting-bagging-and-stacking-ensemble-methods-with-sklearn-and-mlens-a455c0c982de
Luyện tập câu hỏi phỏng vấn Machine Learning bằng Python

Random Forest

Rừng

1 https://www.sca.com/en/about-us/our-forest/
Luyện tập câu hỏi phỏng vấn Machine Learning bằng Python

Gradient Boosting

Gradient Boosting

1 https://blog.bigml.com/2017/03/14/introduction-to-boosted-trees/
Luyện tập câu hỏi phỏng vấn Machine Learning bằng Python

RF vs GB

tham số Random Forest Gradient Boosting
n_estimators 10 100
criterion gini (hoặc entropy) friedman_mse
max_depth None 3
learning_rate N/A 0.1
1 https://scikit-learn.org/stable/modules/classes.html#module-sklearn.ensemble
Luyện tập câu hỏi phỏng vấn Machine Learning bằng Python

Các hàm

Hàm trả về
sklearn.ensemble.RandomForestClassifier Random Forest
sklearn.ensemble.GradientBoostingClassifier Mô hình Gradient Boosting
sklearn.metrics.accuracy_score độ chính xác mô hình đã huấn luyện
sklearn.metrics.confusion_matrix(y_test,y_pred) ma trận nhầm lẫn
sklearn.metrics.precision_score(y_test,y_pred) precision
sklearn.metrics.recall_score(y_test,y_pred) recall
sklearn.metrics.f1_score(y_test,y_pred) f1-score
Luyện tập câu hỏi phỏng vấn Machine Learning bằng Python

Luyện tập nào!

Luyện tập câu hỏi phỏng vấn Machine Learning bằng Python

Preparing Video For Download...