Anomaly Detection in Python
Bekhruz (Bex) Tuychiev
Kaggle Master, Data Science Content Creator
IForest に最も影響するハイパーパラメータ:
contaminationn_estimatorsmax_samplesmax_featuresIForest がデータ点を分類する流れ:
contamination という閾値を設定contamination に相当する上位割合のスコアを外れ値として選択from pyod.models.iforest import IForest# 0~0.5 の値を受け付ける iforest = IForest(contamination=0.05)
# 大規模データには木を増やす
iforest = IForest(n_estimators=1000)
iforest.fit(airbnb_df)
iforest = IForest(n_estimators=200, max_samples=0.6, max_features=0.9)iforest.fit(airbnb_df)
Anomaly Detection in Python