ertk.sklearn.models.SkModelConfig

class ertk.sklearn.models.SkModelConfig(kwargs: ~typing.Dict[str, ~typing.Any] = <factory>, transform: str | None = 'std', transform_kwargs: ~typing.Dict[str, ~typing.Any] = <factory>, param_grid: ~typing.Dict[str, ~typing.Any] = <factory>, param_grid_path: str | None = None)

Bases: ERTKConfig

Configuration for a scikit-learn model.

__init__(kwargs: ~typing.Dict[str, ~typing.Any] = <factory>, transform: str | None = 'std', transform_kwargs: ~typing.Dict[str, ~typing.Any] = <factory>, param_grid: ~typing.Dict[str, ~typing.Any] = <factory>, param_grid_path: str | None = None) None

Methods

__init__([kwargs, transform, ...])

Inherited Methods

from_config(config)

Create config object from any compatible config.

from_file(path[, override])

Create config from YAML file and optionlly override some values.

merge_with_args([args])

Merge config with command-line arguments.

to_dictconfig()

Convert config to DictConfig.

to_file(path)

Write config to YAML file.

to_string()

Generate YAML string representation of config.

Attributes

param_grid_path

The path to a YAML file containing the parameter grid to use for grid search.

transform

The name of the transform to use.

kwargs

Keyword arguments to pass to the model constructor.

transform_kwargs

Keyword arguments to pass to the transform constructor.

param_grid

The parameter grid to use for grid search.

kwargs: Dict[str, Any]

Keyword arguments to pass to the model constructor.

param_grid: Dict[str, Any]

The parameter grid to use for grid search.

param_grid_path: str | None = None

The path to a YAML file containing the parameter grid to use for grid search.

transform: str | None = 'std'

The name of the transform to use.

transform_kwargs: Dict[str, Any]

Keyword arguments to pass to the transform constructor.