File tree Expand file tree Collapse file tree 1 file changed +2
-9
lines changed Expand file tree Collapse file tree 1 file changed +2
-9
lines changed Original file line number Diff line number Diff line change 2121from  ..under_sampling  import  RandomUnderSampler 
2222
2323
24- class  _EasyEnsembleGeneralization (ClassifierMixin , BaseEnsemble ):
24+ class  EasyEnsembleGeneralization (ClassifierMixin , BaseEnsemble ):
2525
2626    """This classifier generalize the Easy Ensemble algorithm for imbalanced  
2727       datasets. 
@@ -95,7 +95,7 @@ def __init__(self,
9595
9696    def  _validate_estimator (self ):
9797        """Check the estimator and set the base_estimator_ attribute.""" 
98-         super (_EasyEnsembleGeneralization , self )._validate_estimator (
98+         super (EasyEnsembleGeneralization , self )._validate_estimator (
9999            default = DecisionTreeClassifier ())
100100
101101    def  _validate_sampler (self ):
@@ -199,10 +199,3 @@ def predict_proba(self, X):
199199        """ 
200200        check_is_fitted (self , "_voting" )
201201        return  self ._voting .predict_proba (X )
202- 
203- 
204- # XXX  make EasyEnsembleGeneralization to pass sklearn compatibility test 
205- bases  =  _EasyEnsembleGeneralization .__mro__ 
206- bases  =  tuple (x  for  x  in  bases  if  x  !=  MetaEstimatorMixin )
207- EasyEnsembleGeneralization  =  type (
208-     'EasyEnsembleGeneralization' , bases , dict (_EasyEnsembleGeneralization .__dict__ ))
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments