Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(3)  |  Call(3)  |  Derive(0)  |  Import(0)

src/m/o/mozsci-HEAD/test/test_evaluation.py   mozsci(Download)
        calculated = np.array([0, 1, 1, 0, 0, 0, 1])
 
        measure = evaluation.classification_model_performance(observed, calculated)
 
        self.assertEqual(measure, 0)
        calculated = np.array([0, 1, 1, 0, 0, 0, 1])
 
        measure = evaluation.classification_model_performance(observed, calculated)
 
        self.assertAlmostEqual(measure, 0.2857142857140)
        calculated = np.array([0, 1, 1, 0, 0, 0, 1])
 
        measure = evaluation.classification_model_performance(observed, calculated, [1.0, 3.0])
 
    def test_matrix_measure_1(self):