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

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

src/m/o/mozsci-HEAD/test/test_variables.py   mozsci(Download)
        y = data.view(dtype=np.int).reshape(-1, 3)[:, 2].reshape(-1, 1)
        model.fit(X, y)
        ypred = model.predict(X)
        self.assertTrue(classification_error(y, ypred) < 0.002)
 
        # now try using __getitem__
        model.fit(data, data)
        ypred = model.predict(data)