Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues about Multi label Hoeffding Tree #235

Open
cici-xihui opened this issue Jul 28, 2021 · 0 comments
Open

Issues about Multi label Hoeffding Tree #235

cici-xihui opened this issue Jul 28, 2021 · 0 comments

Comments

@cici-xihui
Copy link

cici-xihui commented Jul 28, 2021

Hello,

I tried to use multi-label Hoeffding Tree to build my baseline, however I gots some problems.

At first

        import moa.classifiers.multilabel.MultilabelHoeffdingTree;

        MultiTargetArffFileStream stream = new MultiTargetArffFileStream("mediamill.arff", "-101");

        MultilabelHoeffdingTree learner = new MultilabelHoeffdingTree();

I got a warning :
[WARNING] Only 1 labels found! (Expecting 101)
(Ignoring this prediction)

It means that the defaults classifier is not a multi-label classifier ?

So I use PSUpdate classifier as the base classifier in the leaf of hoeffding tree (as in mentioned in the article) :

        _import moa.classifiers.multilabel.MultilabelHoeffdingTree;
        import meka.classifiers.multilabel.incremental.PSUpdateable;

        MultilabelHoeffdingTree learner = new MultilabelHoeffdingTree();
        MEKAClassifier PS = new MEKAClassifier();
        PSUpdateable base = new PSUpdateable();
        PS.baseLearnerOption.setCurrentObject(base);
        PS.setModelContext(header);
        PS.prepareForUse();
        PS.resetLearningImpl();
        learner.learnerOption.setCurrentObject(PS);

Then I got [ERROR] Failed to update classifier
weka.core.UnsupportedAttributeTypeException: weka.classifiers.bayes.NaiveBayesUpdateable: Cannot handle unary class!

The dataset "mediamill.arff" I used has the numeric attributes, and the labelset is at the end of each example.
When I load data, I add a minus sign, so there should be a problem with the connection between moa and weka when loading data?

Thank you for your help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant