70c416bbd7ebc468fda10c37b1f2965d43059249,skopt/learning/gbrt.py,GradientBoostingQuantileRegressor,predict,#GradientBoostingQuantileRegressor#,54
Before Change
def predict(self, X):
Predict for each quantile.
return np.asarray([rgr.predict(X) for rgr in self.regressors_]).T
After Change
predicted_quantiles = np.asarray(
[rgr.predict(X) for rgr in self.regressors_])
if not return_std:
return predicted_quantiles.T
else:
std_quantiles = [0.16, 0.5, 0.84]
is_present_mask = np.in1d(std_quantiles, self.quantiles)
if not np.all(is_present_mask):
raise ValueError(
"return_std works only if the quan")
low = self.regressors_[self.quantiles.index(0.16)].predict(X)
high = self.regressors_[self.quantiles.index(0.84)].predict(X)
mean = self.regressors_[self.quantiles.index(0.5)].predict(X)
return mean, ((high - low) / 2.0)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 8
Instances
Project Name: scikit-optimize/scikit-optimize
Commit Name: 70c416bbd7ebc468fda10c37b1f2965d43059249
Time: 2016-04-26
Author: manojkumarsivaraj334@gmail.com
File Name: skopt/learning/gbrt.py
Class Name: GradientBoostingQuantileRegressor
Method Name: predict
Project Name: BVLC/caffe
Commit Name: 3ef43e41e74f4cebf8b1be006bf0b596a6b37e5a
Time: 2014-07-18
Author: jonlong@cs.berkeley.edu
File Name: python/caffe/pycaffe.py
Class Name:
Method Name: _Net_forward
Project Name: BVLC/caffe
Commit Name: 3ef43e41e74f4cebf8b1be006bf0b596a6b37e5a
Time: 2014-07-18
Author: jonlong@cs.berkeley.edu
File Name: python/caffe/pycaffe.py
Class Name:
Method Name: _Net_backward