Пример #1
0
 def __init__(self):
     super(LocalBaseline, self).__init__()
     self.model_param = LocalBaselineParam()
     self.model_name = "LocalBaseline"
     self.metric_type = ""
     self.model_param_name = "LocalBaselineParam"
     self.model_meta_name = "LocalBaselineMeta"
Пример #2
0
    def __init__(self):
        super(LocalBaseline, self).__init__()
        self.model_param = LocalBaselineParam()
        self.model_name = "LocalBaseline"
        self.metric_type = ""
        self.model_param_name = "LocalBaselineParam"
        self.model_meta_name = "LocalBaselineMeta"

        # one_ve_rest parameter
        self.need_one_vs_rest = None
        self.one_vs_rest_classes = []
        self.one_vs_rest_obj = None
Пример #3
0
 def setUp(self):
     self.job_id = str(uuid.uuid1())
     session.init("test_random_sampler_" + self.job_id)
     data_num = 100
     feature_num = 8
     self.prepare_data(data_num, feature_num)
     params = LocalBaselineParam()
     local_baseline_obj = LocalBaseline()
     local_baseline_obj._init_model(params)
     local_baseline_obj.need_run = True
     local_baseline_obj.header = ["x1", "x2", "x3", "x4", "x5", "x6", "x7", "x8"]
     local_baseline_obj.model_name = "LogisticRegression"
     local_baseline_obj.model_opts = {}
     self.local_baseline_obj = local_baseline_obj
Пример #4
0
 def setUp(self):
     self.job_id = str(uuid.uuid1())
     self.session = Session.create(0,
                                   0).init_computing(self.job_id).computing
     data_num = 100
     feature_num = 8
     self.prepare_data(data_num, feature_num)
     params = LocalBaselineParam()
     local_baseline_obj = LocalBaseline()
     local_baseline_obj._init_model(params)
     local_baseline_obj.need_run = True
     local_baseline_obj.header = [
         "x1", "x2", "x3", "x4", "x5", "x6", "x7", "x8"
     ]
     local_baseline_obj.model_name = "LogisticRegression"
     local_baseline_obj.model_opts = {}
     self.local_baseline_obj = local_baseline_obj