Avvikelsedetektering i Python
Bekhruz (Bex) Tuychiev
Kaggle Master, Data Science Content Creator
Hyperparametrar som påverkar IForest mest:
contaminationn_estimatorsmax_samplesmax_featuresSå klassificerar IForest datapunkter:
contamination sättscontamination väljs ut som avvikande datapunkterfrom pyod.models.iforest import IForest# Accepts a value between 0 and 0.5 iforest = IForest(contamination=0.05)
# More trees for larger datasets
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)
Avvikelsedetektering i Python