0

I'm wondering if there is a non-linear regression routine with scikit-learn which allows for incremental learning, ie though the partial_fit call. I see that SGDRegressor and PassiveAggressiveRegressor both allow partial_fit, but are linear, and my data is decidedly non-linear so fits are nowhere close.

1
  • I think the answer is no. One way you could get around this is by transforming your features into nonlinear features and then running a linear partial fit on those. If this doesn't work, you can always use a library like tensorflow or pytorch to do a partial fit. Commented Oct 7, 2024 at 21:25

1 Answer 1

0

The MLPRegressor class is capable of modeling non-linear relationships using a multi-layer perceptron. It supports partial_fit(). Note that partial_fit() only works if solver is not set to 'lbfgs.'

Based on a search through the docs, I could not find any other examples that fulfill all of 1) being a regressor, 2) having support for partial_fit(), and 3) being nonlinear.

Alternatively, you might consider kernel methods. For example, you could pick a subset of your data, perform RBF between that subset and all other points, and you would be able to model non-linear relationships using a linear regressor on the transformed RBF space. The RBF kernel would not learn incrementally, but the linear component would. This would give you more options, such as SGDRegressor or PassiveAgressiveRegressor.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.