import os from solnml.components.models.base_nn import BaseImgClassificationNeuralNetwork from solnml.components.utils.class_loader import find_components, ThirdPartyComponents """ Load the buildin classifiers. """ classifiers_directory = os.path.split(__file__)[0] _classifiers = find_components(__package__, classifiers_directory, BaseImgClassificationNeuralNetwork) """ Load third-party classifiers. """ _addons = ThirdPartyComponents(BaseImgClassificationNeuralNetwork) def add_classifier(classifier): _addons.add_component(classifier)
import os from solnml.components.feature_engineering.transformations.base_transformer import Transformer from solnml.components.utils.class_loader import find_components """ Load the buildin classifiers. """ selector_directory = os.path.split(__file__)[0] _selector = find_components(__package__, selector_directory, Transformer)
import os from solnml.components.feature_engineering.transformations.base_transformer import Transformer from solnml.components.utils.class_loader import find_components """ Load the buildin classifiers. """ preprocessor_directory = os.path.split(__file__)[0] _preprocessor = find_components(__package__, preprocessor_directory, Transformer) _balancer = {} # for key in ['weight_balancer','smote_balancer']: for key in ['weight_balancer']: if key in _preprocessor.keys(): _balancer[key] = _preprocessor[key]
import os from solnml.components.models.base_model import BaseClassificationModel from solnml.components.utils.class_loader import find_components, ThirdPartyComponents """ Load the buildin classifiers. """ imbalanced_classifiers_directory = os.path.split(__file__)[0] _imb_classifiers = find_components(__package__, imbalanced_classifiers_directory, BaseClassificationModel)
import os from solnml.components.models.base_model import BaseRegressionModel from solnml.components.utils.class_loader import find_components, ThirdPartyComponents """ Load the buildin regressors. """ regressors_directory = os.path.split(__file__)[0] _regressors = find_components(__package__, regressors_directory, BaseRegressionModel) """ Load third-party classifiers. """ _addons = ThirdPartyComponents(BaseRegressionModel) def add_regressor(regressor): _addons.add_component(regressor)
import os from collections import OrderedDict from solnml.components.feature_engineering.transformations.base_transformer import Transformer from solnml.components.utils.class_loader import find_components, ThirdPartyComponents """ Load the buildin classifiers. """ balancer_directory = os.path.split(__file__)[0] _balancer = find_components(__package__, balancer_directory, Transformer) _imb_balancer = OrderedDict() # TODO:Verify the effect of smote_balancer # for key in ['weight_balancer', 'smote_balancer']: for key in ['weight_balancer']: if key in _balancer.keys(): _imb_balancer[key] = _balancer[key] _bal_balancer = OrderedDict() for key in ['weight_balancer']: if key in _balancer.keys(): _bal_balancer[key] = _balancer[key] """ Load third-party classifiers. """ _addons = ThirdPartyComponents(Transformer) def add_balancer(balancer): _addons.add_component(balancer)
import os from solnml.components.feature_engineering.transformations.base_transformer import Transformer from solnml.components.utils.class_loader import find_components """ Load the buildin classifiers. """ rescaler_directory = os.path.split(__file__)[0] _rescaler = find_components(__package__, rescaler_directory, Transformer)
import os from solnml.components.feature_engineering.transformations.base_transformer import Transformer from solnml.components.utils.class_loader import find_components """ Load the buildin classifiers. """ generator_directory = os.path.split(__file__)[0] _generator = find_components(__package__, generator_directory, Transformer)