def __init__(self, config): self.config = self._Parameters(config) if self.config.oversample_method == 'SMOTE_imlearn': self.sampler = Sampler.SMOTEImlearn(config) elif self.config.oversample_method == 'naive': self.sampler = Sampler.Naive(config) elif self.config.oversample_method == 'ADASYN': self.sampler = Sampler.ADASYNImlearn(config) elif self.config.oversample_method == 'pySMOTE': self.sampler = Sampler.PySmote(config) elif self.config.oversample_method == 'RUS': self.sampler = Sampler.RUSImlearn(config)