Ensemble.py 文件源码

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

项目:molearn 作者: jmread 项目源码 文件源码
def demo():
    import sys
    sys.path.append( '../core' )
    from tools import make_XOR_dataset

    X,Y = make_XOR_dataset()
    N,L = Y.shape

    from sklearn import linear_model
    h_ = linear_model.SGDClassifier(n_iter=100)
    from CC import RCC
    cc = RCC(h=h_)
    e = Ensemble(n_estimators=10,base_estimator=cc)
    e.fit(X, Y)
    # test it
    print(e.predict(X))
    print("vs")
    print(Y)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号