|
PineForge HPO 1.11.0
Native hyperparameter optimization for PineForge strategies
|
Public Member Functions | |
| None | __init__ (self, list sources, Any passed_space=None) |
| str | key_of (self, dict values) |
| dict | row_values (self, Row row) |
| None | bind (self, dict band, float|None fraction, float|None ratio) |
| float | gap (self, float objective) |
| bool | better (self, float objective, float other) |
| Any | rank (self, str name, Any value) |
| list | sort_values (self, str name, Any values) |
| dict | cell (self, dict values) |
Public Attributes | |
| space | |
| direction | |
| dimensions | |
| names | |
| varying | |
| constants | |
| rows | |
| row_count | |
| by_id | |
| summaries | |
| input_sha256 | |
| duplicate_rows | |
| reference | |
| reference_id | |
| band | |
| delta | |
| fraction | |
| ratio | |
The rows of the supplied sources indexed by parameter vector. Built by ``prepare``. It holds the common recorded space, one ``Dimension`` per parameter in byte-wise name order, the groups of rows that share a vector, the reference value and the input digest. ``bind`` adds the band so that ``cell`` can classify a vector. Treat every attribute as read-only.
Definition at line 493 of file neighbourhood.py.
| None pineforge_hpo.neighbourhood.Study.__init__ | ( | self, | |
| list | sources, | ||
| Any | passed_space = None |
||
| ) |
Definition at line 502 of file neighbourhood.py.
| bool pineforge_hpo.neighbourhood.Study.better | ( | self, | |
| float | objective, | ||
| float | other | ||
| ) |
Whether ``objective`` is strictly better than ``other``.
Definition at line 620 of file neighbourhood.py.
References pineforge::hpo::TpeSampler.direction(), pineforge::hpo::DlibGlobalSampler.direction(), pineforge_hpo._rows.Source.direction, pineforge_hpo.neighbourhood.Study.direction, and pineforge_hpo.study_spec.ObjectiveSpec.direction.
| None pineforge_hpo.neighbourhood.Study.bind | ( | self, | |
| dict | band, | ||
| float | None | fraction, | ||
| float | None | ratio | ||
| ) |
Set the band and the move rules; computes the near-best distance.
Definition at line 599 of file neighbourhood.py.
References pineforge_hpo.neighbourhood.Study.reference.
| dict pineforge_hpo.neighbourhood.Study.cell | ( | self, | |
| dict | values | ||
| ) |
Class, objective, gap, near flag and row ids of one full vector. Classes: ``scored_ok`` (status ok), ``scored_infeasible`` (constraint violation), ``unscorable`` (any other status; the recorded objective of the first row is shown, a pruned row's is a prefix value) and ``never_evaluated``. Scored rows of one vector agree exactly, so the first scored row speaks for the vector; otherwise the first row does.
Definition at line 632 of file neighbourhood.py.
References pineforge_hpo.neighbourhood.Study.delta, pineforge_hpo.neighbourhood.Study.gap(), and pineforge_hpo.neighbourhood.Study.key_of().
| float pineforge_hpo.neighbourhood.Study.gap | ( | self, | |
| float | objective | ||
| ) |
Distance from the reference value; one subtraction, never negative.
Definition at line 614 of file neighbourhood.py.
References pineforge::hpo::TpeSampler.direction(), pineforge::hpo::DlibGlobalSampler.direction(), pineforge_hpo._rows.Source.direction, pineforge_hpo.neighbourhood.Study.direction, pineforge_hpo.study_spec.ObjectiveSpec.direction, and pineforge_hpo.neighbourhood.Study.reference.
Referenced by pineforge_hpo.neighbourhood.Study.cell().
| str pineforge_hpo.neighbourhood.Study.key_of | ( | self, | |
| dict | values | ||
| ) |
Canonical key of a normalised parameter vector.
Definition at line 548 of file neighbourhood.py.
References pineforge_hpo._rows.Row.space, pineforge_hpo._rows.Source.space, and pineforge_hpo.neighbourhood.Study.space.
Referenced by pineforge_hpo.neighbourhood.Study.cell().
| Any pineforge_hpo.neighbourhood.Study.rank | ( | self, | |
| str | name, | ||
| Any | value | ||
| ) |
Definition at line 626 of file neighbourhood.py.
References pineforge::hpo::SearchSpace.dimensions(), pineforge_hpo.neighbourhood.Study.dimensions, and pineforge_hpo.neighbourhood.Study.rank().
Referenced by pineforge_hpo.neighbourhood.Study.rank(), and pineforge_hpo.neighbourhood.Dimension.sort_values().
| dict pineforge_hpo.neighbourhood.Study.row_values | ( | self, | |
| Row | row | ||
| ) |
The normalised parameter vector of a row, or an input_invalid refusal.
Definition at line 555 of file neighbourhood.py.
References pineforge::hpo::SearchSpace.dimensions(), and pineforge_hpo.neighbourhood.Study.dimensions.
| list pineforge_hpo.neighbourhood.Study.sort_values | ( | self, | |
| str | name, | ||
| Any | values | ||
| ) |
Definition at line 629 of file neighbourhood.py.
References pineforge::hpo::SearchSpace.dimensions(), pineforge_hpo.neighbourhood.Study.dimensions, and pineforge_hpo.neighbourhood.Study.sort_values().
Referenced by pineforge_hpo.neighbourhood.Study.sort_values().
| pineforge_hpo.neighbourhood.Study.band |
Definition at line 609 of file neighbourhood.py.
| pineforge_hpo.neighbourhood.Study.by_id |
Definition at line 521 of file neighbourhood.py.
| pineforge_hpo.neighbourhood.Study.constants |
Definition at line 518 of file neighbourhood.py.
| pineforge_hpo.neighbourhood.Study.delta |
Definition at line 610 of file neighbourhood.py.
Referenced by pineforge_hpo.neighbourhood.Study.cell().
| pineforge_hpo.neighbourhood.Study.dimensions |
Definition at line 515 of file neighbourhood.py.
Referenced by pineforge_hpo.neighbourhood.Study.rank(), pineforge_hpo.neighbourhood.Study.row_values(), and pineforge_hpo.neighbourhood.Study.sort_values().
| pineforge_hpo.neighbourhood.Study.direction |
Definition at line 508 of file neighbourhood.py.
Referenced by pineforge_hpo.neighbourhood.Study.better(), and pineforge_hpo.neighbourhood.Study.gap().
| pineforge_hpo.neighbourhood.Study.duplicate_rows |
Definition at line 530 of file neighbourhood.py.
| pineforge_hpo.neighbourhood.Study.fraction |
Definition at line 611 of file neighbourhood.py.
| pineforge_hpo.neighbourhood.Study.input_sha256 |
Definition at line 529 of file neighbourhood.py.
| pineforge_hpo.neighbourhood.Study.names |
Definition at line 516 of file neighbourhood.py.
Referenced by pineforge_hpo._rows.RowsError.__reduce__(), pineforge_hpo.dsr.DsrError.__reduce__(), pineforge_hpo.holdout.HoldoutError.__reduce__(), pineforge_hpo.neighbourhood.NeighbourhoodError.__reduce__(), pineforge_hpo.pareto.ParetoError.__reduce__(), pineforge_hpo.walkforward.WalkforwardError.__reduce__(), pineforge_hpo.dsr.DsrError.document(), pineforge_hpo.holdout.HoldoutError.document(), pineforge_hpo.neighbourhood.NeighbourhoodError.document(), pineforge_hpo.pareto.ParetoError.document(), pineforge_hpo.pbo.PboError.document(), and pineforge_hpo.walkforward.WalkforwardError.document().
| pineforge_hpo.neighbourhood.Study.ratio |
Definition at line 612 of file neighbourhood.py.
| pineforge_hpo.neighbourhood.Study.reference |
Definition at line 539 of file neighbourhood.py.
Referenced by pineforge_hpo.neighbourhood.Study.bind(), and pineforge_hpo.neighbourhood.Study.gap().
| pineforge_hpo.neighbourhood.Study.reference_id |
Definition at line 540 of file neighbourhood.py.
| pineforge_hpo.neighbourhood.Study.row_count |
Definition at line 520 of file neighbourhood.py.
| pineforge_hpo.neighbourhood.Study.rows |
Definition at line 519 of file neighbourhood.py.
| pineforge_hpo.neighbourhood.Study.space |
Definition at line 505 of file neighbourhood.py.
Referenced by pineforge_hpo.neighbourhood.Study.key_of().
| pineforge_hpo.neighbourhood.Study.summaries |
Definition at line 522 of file neighbourhood.py.
| pineforge_hpo.neighbourhood.Study.varying |
Definition at line 517 of file neighbourhood.py.