예제 #1
0
    def test_eval_partial_cv_on_subset_no_timeout(self):
        results = [0.071428571428571508,
                   0.071428571428571508,
                   0.08333333333333337,
                   0.16666666666666674,
                   0.0]
        for fold in range(5):
            eval_partial_cv(self.queue, self.configuration,
                                      self.data, self.tmp_dir, 1, 1,
                                      fold, 5, 80, True, False, True)

            info = self.queue.get()
            self.assertAlmostEqual(info[1], results[fold])
            self.assertEqual(info[2], 1)

        results = [0.071428571428571508,
                   0.15476190476190488,
                   0.16666666666666674,
                   0.0,
                   0.0]
        for fold in range(5):
            eval_partial_cv(self.queue, self.configuration,
                                      self.data, self.tmp_dir, 1, 1,
                                      fold, 5, 43, True, False, True)

            info = self.queue.get()
            self.assertAlmostEqual(info[1], results[fold])
            self.assertEqual(info[2], 1)
예제 #2
0
 def test_eval_partial_cv(self):
     results = [0.071428571428571508,
                0.071428571428571508,
                0.08333333333333337,
                0.16666666666666674,
                0.0]
     for fold in range(5):
         eval_partial_cv(self.queue, self.configuration, self.data,
                         self.tmp_dir, 1, 1, fold, 5, None, True, False, True)
         info = self.queue.get()
         results.append(info[1])
         self.assertAlmostEqual(info[1], results[fold])
         self.assertEqual(info[2], 1)
예제 #3
0
 def test_eval_partial_cv(self):
     results = [
         0.071428571428571508, 0.071428571428571508, 0.08333333333333337,
         0.16666666666666674, 0.0
     ]
     for fold in range(5):
         eval_partial_cv(self.queue, self.configuration, self.data,
                         self.tmp_dir, 1, 1, fold, 5, None, True, False,
                         True)
         info = self.queue.get()
         results.append(info[1])
         self.assertAlmostEqual(info[1], results[fold])
         self.assertEqual(info[2], 1)
예제 #4
0
    def test_eval_partial_cv_on_subset_no_timeout(self):
        results = [
            0.071428571428571508, 0.071428571428571508, 0.08333333333333337,
            0.16666666666666674, 0.0
        ]
        for fold in range(5):
            eval_partial_cv(self.queue, self.configuration, self.data,
                            self.tmp_dir, 1, 1, fold, 5, 80, True, False, True)

            info = self.queue.get()
            self.assertAlmostEqual(info[1], results[fold])
            self.assertEqual(info[2], 1)

        results = [
            0.071428571428571508, 0.15476190476190488, 0.16666666666666674,
            0.0, 0.0
        ]
        for fold in range(5):
            eval_partial_cv(self.queue, self.configuration, self.data,
                            self.tmp_dir, 1, 1, fold, 5, 43, True, False, True)

            info = self.queue.get()
            self.assertAlmostEqual(info[1], results[fold])
            self.assertEqual(info[2], 1)