Spaces:
Sleeping
Sleeping
MilesCranmer
commited on
Commit
•
29edd56
1
Parent(s):
48b723d
Change assert to allow no binary/unary operators
Browse files- pysr/sr.py +1 -1
pysr/sr.py
CHANGED
@@ -101,7 +101,7 @@ def pysr(X=None, y=None, weights=None,
|
|
101 |
raise ValueError("The threads kwarg is deprecated. Use procs.")
|
102 |
|
103 |
# Check for potential errors before they happen
|
104 |
-
assert len(binary_operators) > 0
|
105 |
assert len(X.shape) == 2
|
106 |
assert len(y.shape) == 1
|
107 |
assert X.shape[0] == y.shape[0]
|
|
|
101 |
raise ValueError("The threads kwarg is deprecated. Use procs.")
|
102 |
|
103 |
# Check for potential errors before they happen
|
104 |
+
assert len(unary_operators) + len(binary_operators) > 0
|
105 |
assert len(X.shape) == 2
|
106 |
assert len(y.shape) == 1
|
107 |
assert X.shape[0] == y.shape[0]
|