0

I am using skmultilearn library to solve a multi-label machine learning problem. There are 5 labels with binary data (0 or 1). Sklearn logistic regression is being used as base classifier. But I need to set label specific features for each classifier. The label data of one classifier to be used as feature of another classifier. I am not able to figure out on how to do that.

Any help appreciated.

Andreas Rossberg
  • 34,518
  • 3
  • 61
  • 72
Deb Paswan
  • 11
  • 2

1 Answers1

0

One-vs-Rest is the method of solving the multi-label problem you are trying to address, it is the transformation type. You just need to generate a different training set for each simple classifier so that you have all the combinations between the original attributes and each of the labels. Pandas can be useful for the manipulation of the data and the generation of the different datasets for each simple classifier. Note that using this strategy in its original form ignores the relationships between the tags.

Ricardo Sanchez
  • 704
  • 6
  • 21
  • Thanks Ricardo. Yes, I am looking for the same One-vs-Rest method and have implemented also by manipulating the data through Pandas. But I am looking for any package which operates like this taking all the data and label list at once. – Deb Paswan Sep 04 '20 at 09:30
  • in which way pandas is not enough to meet your needs? – Ricardo Sanchez Sep 04 '20 at 20:21
  • What I did is manipulated data through pandas and created n no of models for n labels. My current requirement is to create a single model which can handle my one-vs-rest multi-label scenario. – Deb Paswan Sep 06 '20 at 04:09