Spaces:
Sleeping
Sleeping
MilesCranmer
commited on
Commit
•
5abd46e
1
Parent(s):
f422d37
Bump backend version with `should_simplify` param
Browse files- docs/param_groupings.yml +1 -0
- pysr/sr.py +6 -0
- pysr/version.py +2 -2
docs/param_groupings.yml
CHANGED
@@ -23,6 +23,7 @@
|
|
23 |
- use_frequency
|
24 |
- use_frequency_in_tournament
|
25 |
- adaptive_parsimony_scaling
|
|
|
26 |
- Mutations:
|
27 |
- weight_add_node
|
28 |
- weight_insert_node
|
|
|
23 |
- use_frequency
|
24 |
- use_frequency_in_tournament
|
25 |
- adaptive_parsimony_scaling
|
26 |
+
- should_simplify
|
27 |
- Mutations:
|
28 |
- weight_add_node
|
29 |
- weight_insert_node
|
pysr/sr.py
CHANGED
@@ -436,6 +436,9 @@ class PySRRegressor(MultiOutputMixin, RegressorMixin, BaseEstimator):
|
|
436 |
topn : int
|
437 |
How many top individuals migrate from each population.
|
438 |
Default is `12`.
|
|
|
|
|
|
|
439 |
should_optimize_constants : bool
|
440 |
Whether to numerically optimize constants (Nelder-Mead/Newton)
|
441 |
at the end of each iteration. Default is `True`.
|
@@ -706,6 +709,7 @@ class PySRRegressor(MultiOutputMixin, RegressorMixin, BaseEstimator):
|
|
706 |
migration=True,
|
707 |
hof_migration=True,
|
708 |
topn=12,
|
|
|
709 |
should_optimize_constants=True,
|
710 |
optimizer_algorithm="BFGS",
|
711 |
optimizer_nrestarts=2,
|
@@ -759,6 +763,7 @@ class PySRRegressor(MultiOutputMixin, RegressorMixin, BaseEstimator):
|
|
759 |
self.constraints = constraints
|
760 |
self.nested_constraints = nested_constraints
|
761 |
self.warmup_maxsize_by = warmup_maxsize_by
|
|
|
762 |
# - Early exit conditions:
|
763 |
self.max_evals = max_evals
|
764 |
self.timeout_in_seconds = timeout_in_seconds
|
@@ -1593,6 +1598,7 @@ class PySRRegressor(MultiOutputMixin, RegressorMixin, BaseEstimator):
|
|
1593 |
migration=self.migration,
|
1594 |
hof_migration=self.hof_migration,
|
1595 |
fraction_replaced_hof=self.fraction_replaced_hof,
|
|
|
1596 |
should_optimize_constants=self.should_optimize_constants,
|
1597 |
warmup_maxsize_by=self.warmup_maxsize_by,
|
1598 |
use_frequency=self.use_frequency,
|
|
|
436 |
topn : int
|
437 |
How many top individuals migrate from each population.
|
438 |
Default is `12`.
|
439 |
+
should_simplify : bool
|
440 |
+
Whether to use algebraic simplification in the search. Note that only
|
441 |
+
a few simple rules are implemented. Default is `True`.
|
442 |
should_optimize_constants : bool
|
443 |
Whether to numerically optimize constants (Nelder-Mead/Newton)
|
444 |
at the end of each iteration. Default is `True`.
|
|
|
709 |
migration=True,
|
710 |
hof_migration=True,
|
711 |
topn=12,
|
712 |
+
should_simplify=None,
|
713 |
should_optimize_constants=True,
|
714 |
optimizer_algorithm="BFGS",
|
715 |
optimizer_nrestarts=2,
|
|
|
763 |
self.constraints = constraints
|
764 |
self.nested_constraints = nested_constraints
|
765 |
self.warmup_maxsize_by = warmup_maxsize_by
|
766 |
+
self.should_simplify = should_simplify
|
767 |
# - Early exit conditions:
|
768 |
self.max_evals = max_evals
|
769 |
self.timeout_in_seconds = timeout_in_seconds
|
|
|
1598 |
migration=self.migration,
|
1599 |
hof_migration=self.hof_migration,
|
1600 |
fraction_replaced_hof=self.fraction_replaced_hof,
|
1601 |
+
should_simplify=self.should_simplify,
|
1602 |
should_optimize_constants=self.should_optimize_constants,
|
1603 |
warmup_maxsize_by=self.warmup_maxsize_by,
|
1604 |
use_frequency=self.use_frequency,
|
pysr/version.py
CHANGED
@@ -1,2 +1,2 @@
|
|
1 |
-
__version__ = "0.12.
|
2 |
-
__symbolic_regression_jl_version__ = "0.16.
|
|
|
1 |
+
__version__ = "0.12.1"
|
2 |
+
__symbolic_regression_jl_version__ = "0.16.2"
|