Open oleg-kachan opened 1 year ago
Thank you for raising, I look into it.
I have a version 0.7.1 installed via pip and I don't see several lines which are present in the main branch of the github repo. So, maybe you need to update pypi by the latest version of the code?
The lines are in the following file https://github.com/analyticalmindsltd/smote_variants/blob/master/smote_variants/classifiers/_oversamplingclassifier.py
line 30, OversamplingClassifier._init_():
self.classes_ = None
line 47, OversamplingClassifier.fit():
self.classes_ = self.classifier_obj.classes_
Yes, this is the issue. I have prepared the release of 0.7.2, but one of the dependencies (metric-learn) struggles with the latest version of numpy. As soon as they fix it (already done, but not released yet), I will release 0.7.2 to PyPI, until that, you should be able to use it from the repo here.
I use custom scorer from sklearn, via
make_scorer
function. It does not work ifneeds_proba=True
, so metrics like ROC AUC, PR AUC are unfeasible to be used withsmote_variants
.The error says OversamplingClassifier does not have
_classes
field, had been the latest version pushed to pip?