model.py 文件源码

python
阅读 20 收藏 0 点赞 0 评论 0

项目:CryptoBot 作者: AdeelMufti 项目源码 文件源码
def fit_boosting(X, y, window=100000, estimators=250, learning=.01,
                 samples_leaf=500, depth=20, validate=False):
    '''
    Fits Gradient Boosting
    '''
    model = GradientBoostingRegressor(n_estimators=estimators,
                                      learning_rate=learning,
                                      min_samples_leaf=samples_leaf,
                                      max_depth=depth,
                                      random_state=42)
    if validate:
        return cross_validate(X, y, model, window)
    return model.fit(X, y)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号