model.predict() gives constant values
marastadler opened this issue · comments
Hi,
This package is super helpful :-)!
When applying LassonetRegressor
to my data I get a constant model with model.predict(X)
(for test or validation set), i.e. a vector of predictions where all entries are equal. But the feature importances still make sense. The same observation I made in the diabetes.py
example.
Do you have any idea what this is?
Thanks a lot,
Mara
After computing the path, the model is sparse and uses zero features. You need to load some history item with the number of features you want. I can provide an example if needed!
Thanks. Got it!
You can find an example here: https://github.com/lasso-net/lassonet/blob/e3a3754ad258e67470e15457cb3fa6b8289653a5/examples/friedman.py