Giter Club home page Giter Club logo

Comments (12)

BinchaoPeng avatar BinchaoPeng commented on May 28, 2024 1

恩恩,好的,希望这个project可以实现gpu支持和sklearn支持

from deep-forest.

IncubatorShokuhou avatar IncubatorShokuhou commented on May 28, 2024

@BinchaoPeng 可以自定义estimators和predictor,然后使用支持gpu的评估器作为estimator和predictor。详见https://deep-forest.readthedocs.io/en/stable/advanced_topics/use_customized_estimator.html

from deep-forest.

IncubatorShokuhou avatar IncubatorShokuhou commented on May 28, 2024

另外,如果你不自定义estimator和predictor的话,cv应该是没问题的。但是如果你用了customized estimators的话,那就会出bug了,因为cv里面会用到sklearn.base.clone (见https://github.com/scikit-learn/scikit-learn/blob/main/sklearn/model_selection/_search.py#L769)

关于clone引起bug的问题,可以看我新提交的issure: #92

from deep-forest.

xuyxu avatar xuyxu commented on May 28, 2024

感谢 @IncubatorShokuhou 的说明。关于使用GPU,可以考虑使用cuml中的随机森林:https://docs.rapids.ai/api/cuml/stable/api.html#random-forest

from deep-forest.

BinchaoPeng avatar BinchaoPeng commented on May 28, 2024

好的,谢谢,我去看看

from deep-forest.

xuyxu avatar xuyxu commented on May 28, 2024

如果准备尝试的话,十分欢迎您在这个issue下面进行反馈 ;-)

from deep-forest.

BinchaoPeng avatar BinchaoPeng commented on May 28, 2024

还是报错了,关于GridSearchCV的:

/home/pbc/anaconda3/envs/cuda9/lib/python3.6/site-packages/sklearn/model_selection/_validation.py:700: UserWarning: Scoring failed. The score on this train-test partition for these parameters will be set to nan. Details: 
Traceback (most recent call last):
[CV 1/5] END predictor=xgboost; accuracy: (test=nan) average_precision: (test=nan) f1: (test=nan) roc_auc: (test=nan) total time=10.0min
  File "/home/pbc/anaconda3/envs/cuda9/lib/python3.6/site-packages/sklearn/metrics/_scorer.py", line 56, in _cached_call
    return cache[method]
KeyError: 'decision_function'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File "/home/pbc/anaconda3/envs/cuda9/lib/python3.6/site-packages/sklearn/metrics/_scorer.py", line 334, in _score
    y_pred = method_caller(clf, "decision_function", X)
  File "/home/pbc/anaconda3/envs/cuda9/lib/python3.6/site-packages/sklearn/metrics/_scorer.py", line 58, in _cached_call
    result = getattr(estimator, method)(*args, **kwargs)
AttributeError: 'CascadeForestClassifier' object has no attribute 'decision_function'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File "/home/pbc/anaconda3/envs/cuda9/lib/python3.6/site-packages/sklearn/model_selection/_validation.py", line 687, in _score
    scores = scorer(estimator, X_test, y_test)
  File "/home/pbc/anaconda3/envs/cuda9/lib/python3.6/site-packages/sklearn/metrics/_scorer.py", line 88, in __call__
    *args, **kwargs)
  File "/home/pbc/anaconda3/envs/cuda9/lib/python3.6/site-packages/sklearn/metrics/_scorer.py", line 353, in _score
    y_pred = self._select_proba_binary(y_pred, clf.classes_)
AttributeError: 'CascadeForestClassifier' object has no attribute 'classes_'
  UserWarning,

from deep-forest.

xuyxu avatar xuyxu commented on May 28, 2024

好的,我周末研究一下。

from deep-forest.

BinchaoPeng avatar BinchaoPeng commented on May 28, 2024

class_
decision_funtion
这两个链接或许有用

from deep-forest.

BinchaoPeng avatar BinchaoPeng commented on May 28, 2024

好的,我周末研究一下。

请问你搞定了吗?发现不结合网格搜索和交叉验证这两个功能,不好实用,建议还是接入sklearn比较好

from deep-forest.

py666888 avatar py666888 commented on May 28, 2024

请问不自定义分类器,现在支持网格搜索调参吗?

from deep-forest.

BinchaoPeng avatar BinchaoPeng commented on May 28, 2024

请问不自定义分类器,现在支持网格搜索调参吗?

需要自己实现,不支持sklearn,按照sklearn的方式实现就可以了

from deep-forest.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.