[scikit-learn] control value range of MLPRegressor predictions

Thomas Evangelidis tevang3 at gmail.com
Sun Sep 10 16:43:30 EDT 2017


On 10 September 2017 at 22:03, Sebastian Raschka <se.raschka at gmail.com>
wrote:

> You could normalize the outputs (e.g., via min-max scaling). However, I
> think the more intuitive way would be to clip the predictions. E.g., say
> you are predicting house prices, it probably makes no sense to have a
> negative prediction, so you would clip the output at some value  >0$
>
>
​By clipping you mean discarding the predictors that give values
below/above the threshold?



> PS: -820 and -800 sounds a bit extreme if your training data is in a -5 to
> -9 range. Is your training data from a different population then the one
> you use for testing/making predictions? Or maybe it's just an extreme case
> of overfitting.
>
>
​It is from the same population, but the training sets I use are very small
(6-32 observations), so it must be over-fitting. We had that discussion in
the past here, yet in practice I get good correlations with the
experimental values using MLPRegressors.​



> Best,
> Sebastian
>
>
> > On Sep 10, 2017, at 3:13 PM, Thomas Evangelidis <tevang3 at gmail.com>
> wrote:
> >
> > Greetings,
> >
> > Is there any way to force the MLPRegressor to make predictions in the
> same value range as the training data? For example, if the training data
> range between -5 and -9, I don't want the predictions to range between -820
> and -800. In fact, some times I get anti-correlated predictions, for
> example between 800 and 820 and I have to change the sign in order to
> calculate correlations with experimental values. Is there a way to control
> the value range explicitly or implicitly (by post-processing the
> predictions)?
> >
> > thanks
> > Thomas
> >
> >
> > --
> > ======================================================================
> > Dr Thomas Evangelidis
> > Post-doctoral Researcher
> > CEITEC - Central European Institute of Technology
> > Masaryk University
> > Kamenice 5/A35/2S049,
> > 62500 Brno, Czech Republic
> >
> > email: tevang at pharm.uoa.gr
> >               tevang3 at gmail.com
> >
> > website: https://sites.google.com/site/thomasevangelidishomepage/
> >
> >
> > _______________________________________________
> > scikit-learn mailing list
> > scikit-learn at python.org
> > https://mail.python.org/mailman/listinfo/scikit-learn
>
> _______________________________________________
> scikit-learn mailing list
> scikit-learn at python.org
> https://mail.python.org/mailman/listinfo/scikit-learn
>



-- 

======================================================================

Dr Thomas Evangelidis

Post-doctoral Researcher
CEITEC - Central European Institute of Technology
Masaryk University
Kamenice 5/A35/2S049,
62500 Brno, Czech Republic

email: tevang at pharm.uoa.gr

          tevang3 at gmail.com


website: https://sites.google.com/site/thomasevangelidishomepage/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/scikit-learn/attachments/20170910/56f40d6c/attachment-0001.html>


More information about the scikit-learn mailing list