You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thanks for this wonderful package, makes my life a lot easier!
The treeinterpreter does not seem to work for the class GradientBoostingTree. It has a bug because this class does not output n_output, which is checked in your code to ensure the model has a univariate output.
This might be a quick fix. Would it be possible to do this?
I used the below code to test it.
Thanks,
Roel
----code----
import numpy as np
from sklearn.metrics import mean_squared_error
from sklearn.datasets import make_friedman1
from sklearn.ensemble import GradientBoostingRegressor
I also changed one thing in _predict_forest: now predictions, biases and contributions are preallocated (line 110) before instead of computing everything then averaging. That ensures a more reasonable use of memory.
And like roeldobbe said, thank you for that really nice package !
Cheers
Marc
Hi Ando,
Thanks for this wonderful package, makes my life a lot easier!
The treeinterpreter does not seem to work for the class GradientBoostingTree. It has a bug because this class does not output n_output, which is checked in your code to ensure the model has a univariate output.
This might be a quick fix. Would it be possible to do this?
I used the below code to test it.
Thanks,
Roel
----code----
import numpy as np
X.shape
instances = X[300:309,:]
print "Instance 0 prediction:", gbt.predict(instances[0])
print "Instance 1 prediction:", gbt.predict(instances[1])
prediction, bias, contributions = ti.predict(gbt, instances)
The text was updated successfully, but these errors were encountered: