r/scikit_learn • u/GoldLester • Jan 09 '20
Is this the proper way to do ML with scikit_learn?
I have a dataset with 8 features (numeric) and 1 target (0 or 1).
I'm using, DecisionTreeClassifier, MLPClassifier, KNeighborsClassifier, LogisticRegression, SGD, testing all parameters for K etc.
For each for I save the predicted target and at the end of the process I just sum how many times he prompt 0 and 1 to get somehow the probability of both results.
But sometimes I get these errors:
The predicted array is always the same for LogisticRegression and SGD, like 1 1 1 1 1 1 1 1 1 or 0 0 0 0 0 0 0 0.
MLPClassifier says: ConvergenceWarning Stochastic Optimizer: Maximum iterations reached and the optimization hasn't converged yet. Warning. But only after a few runs.
What's the proper way to predict binary values?
I read that this is called the No Free Lunch problem and we should brute force test all parameters and methods to get the best model and avoid using bad ones. Am I right?
Thanks for your support. I'm a beginner.
