MilesCranmer commited on
Commit
43b3838
1 Parent(s): ebab977

Check shape length after validation

Browse files
Files changed (1) hide show
  1. pysr/sr.py +5 -5
pysr/sr.py CHANGED
@@ -1392,6 +1392,11 @@ class PySRRegressor(BaseEstimator, RegressorMixin, MultiOutputMixin):
1392
 
1393
  self._setup_equation_file()
1394
 
 
 
 
 
 
1395
  if X.shape[0] > 10000 and not self.batching:
1396
  warnings.warn(
1397
  "Note: you are running with more than 10,000 datapoints. "
@@ -1403,11 +1408,6 @@ class PySRRegressor(BaseEstimator, RegressorMixin, MultiOutputMixin):
1403
  "More datapoints will lower the search speed."
1404
  )
1405
 
1406
- # Parameter input validation (for parameters defined in __init__)
1407
- X, y, Xresampled, variable_names = self._validate_fit_params(
1408
- X, y, Xresampled, variable_names
1409
- )
1410
-
1411
  # Pre transformations (feature selection and denoising)
1412
  X, y, variable_names = self._pre_transform_training_data(
1413
  X, y, Xresampled, variable_names
 
1392
 
1393
  self._setup_equation_file()
1394
 
1395
+ # Parameter input validation (for parameters defined in __init__)
1396
+ X, y, Xresampled, variable_names = self._validate_fit_params(
1397
+ X, y, Xresampled, variable_names
1398
+ )
1399
+
1400
  if X.shape[0] > 10000 and not self.batching:
1401
  warnings.warn(
1402
  "Note: you are running with more than 10,000 datapoints. "
 
1408
  "More datapoints will lower the search speed."
1409
  )
1410
 
 
 
 
 
 
1411
  # Pre transformations (feature selection and denoising)
1412
  X, y, variable_names = self._pre_transform_training_data(
1413
  X, y, Xresampled, variable_names