Tool - Yellowbrick Development

# This isn't just plotting. This is validation. from yellowbrick.model_selection import ValidationCurve from sklearn.ensemble import RandomForestClassifier visualizer = ValidationCurve( RandomForestClassifier(), param_name="max_depth", param_range=range(1, 11), cv=5, scoring="f1_weighted" ) visualizer.fit(X, y) visualizer.show()

Add from yellowbrick import ... and start debugging visually. Your future self will thank you when the bug takes 10 minutes to fix instead of 10 hours. Before you tune a single hyperparameter, run Yellowbrick's FeatureCorrelation heatmap. If you see a perfect +1.0 or -1.0 correlation between two features, you have redundant data. Kill one. Your training time just dropped by 30%. yellowbrick development tool

You get a plot showing exactly where underfitting turns into overfitting. You don't guess the max_depth anymore. You see the elbow. Most developers use visualizer.show() . Power users use visualizer.finalize() . # This isn't just plotting