New answers tagged

2 votes
Accepted

Python SK-Learn KNN Imputer ( "ValueError: could not convert string to float: )

After replacing the ? with np.NaN, you will be able to convert the type of the BareNuc ...
El Houcine Es-sanhaji's user avatar
0 votes

Why is my test accuracy higher than train accuracy? SKLEARN

As Oxbowerce mentioned already above. It is possible to have a test score that is higher than the training score. This is not an over-fitting scenario as well. Because your training score is lower ...
Pann Vandet's user avatar
2 votes
Accepted

Number of stop words variation in libaries sklearn and nltk

general agreement [on] stop words No, the definition is fuzzy and situational. We apply stop words according to the need. Even in sklearn, you might choose to tack on additional stop words for a ...
J_H's user avatar
  • 488
1 vote

Any Interface/Library that can take the Python ML code and run on spark cluster without learning PySpark?

There's a library called joblib-spark that you can use to leverage a Spark cluster. It lets you take the Scikit-learn code you've written and train it in a distributed, parallel way across a Spark ...
George Sultani's user avatar
0 votes

Solve a non-linear system, in Python, with the GAUSS-NEWTON algorithm? (Jacobian matrix J, etc.)

Python mathematical libraries numpy and scipy have routines for solving systems of linear equations: ...
Roger V.'s user avatar
  • 101
1 vote

Out-of-Range Target Variable in Sequence-based Machine Learning Model

"Interpolation is easy. Extrapolation is hard." Extrapolating might be the right thing to do. But always be suspect of a model that is leading you to big unexplored regions of the state ...
J_H's user avatar
  • 488
0 votes

Scikit-learn and TensorFlow with very different MLP models

I know that your question was asked almost a year ago, but still maybe someone will find it useful. There are two problems: The first is you are using softmax activation, yet only have one output ...
Martinez's user avatar
1 vote
Accepted

How do I best approach a multiple-target binary classification in Tensorflow/Keras?

The term you would use for that is "multilabel classification". It is certainly possible to do so in Tensorflow, although I would say it is more frequent to see it in examples of image ...
noe's user avatar
  • 23.8k
1 vote

Scikit-Learn classifiers have impressively bad accuracy on test set for binary text classification problem

Gaussian Naive Bayes GaussianNB assumes that your features (input data) follow a normal distribution (or Gaussian distribution) for both classes of your binary ...
Adam Jaamour's user avatar
0 votes

Does it make sense to train data in scikit-learn and copy+paste parameters into Rust's linfa?

Or, to make things easier and robust, you can export the trained scikit-learn model in a cross-platform format, and import it in Rust. 2 suggested format by scikit-learn are ONNX and PMML. Chances are ...
lpounng's user avatar
  • 1,000
1 vote

Does it make sense to train data in scikit-learn and copy+paste parameters into Rust's linfa?

In theory, if you were to pass the same data through a logistic regression or a SVM implemented in different packages, you should get the same results. And the same should apply when tuning a model in ...
Adam Jaamour's user avatar

Top 50 recent answers are included