MilesCranmer commited on
Commit
f266b70
1 Parent(s): 83d8e67

Add another selection test, but with numpy arrays

Browse files
Files changed (1) hide show
  1. test/test.py +4 -2
test/test.py CHANGED
@@ -219,10 +219,12 @@ class TestPipeline(unittest.TestCase):
219
  maxsize=12,
220
  **self.default_test_kwargs,
221
  )
222
- model.fit(X, y, Xresampled=Xresampled)
223
  model.set_params(model_selection="accuracy")
224
- model.predict(X)
225
  self.assertLess(np.average((model.predict(X) - y) ** 2), 1e-4)
 
 
 
226
 
227
 
228
  class TestBest(unittest.TestCase):
 
219
  maxsize=12,
220
  **self.default_test_kwargs,
221
  )
 
222
  model.set_params(model_selection="accuracy")
223
+ model.fit(X, y, Xresampled=Xresampled)
224
  self.assertLess(np.average((model.predict(X) - y) ** 2), 1e-4)
225
+ # Again, but with numpy arrays:
226
+ model.fit(X.values, y.values, Xresampled=Xresampled.values)
227
+ self.assertLess(np.average((model.predict(X.values) - y.values) ** 2), 1e-4)
228
 
229
 
230
  class TestBest(unittest.TestCase):