Changelog:
- Add dataset visualization support for trained engines.
python
from pyshac.utils.vis_utils import plot_dataset
shac = pyshac.SHAC(...)
shac.fit(...) or shac.fit_dataset(...)
plot_dataset(shac.dataset, to_file='dataset.png', title='Dataset history', eval_label='Loss')
- Add **fit_dataset**, which supports engine fitting on external datasets
Uses the provided dataset file to train the engine, instead of using the sequentual halving and classification algorithm directly. The data provided in the path must strictly follow the format of the dataset maintained by the engine.
**Standard format of datasets:**
Each dataset csv file must contain an integer id column named "id"
as its 1st column, followed by several columns describing the values
taken by the hyper parameters, and the final column must be for
the the objective criterion, and *must* be named "scores".
The csv file *must* contain a header, following the above format.
Example
python
params corresponds to params in the external dataset
total_budget is <= the size of the external dataset
num batches is set such that total budget is divisible by num batches
shac = pyshac.SHAC(params, total_budget, num_batches)
shac.fit_dataset('path/to/external/dataset.csv', presort=True)
Bugfixes:
- Properly add the readme to Pypi
- Use codecs for writing compatibility
- Use io for reading compatibility