Skip to content

Types

neps.types #

Primitive types to be used in NePS or consumers of NePS.

AttrDict #

AttrDict(*args: Any, **kwargs: Any)

Bases: dict

Dictionary that allows access to keys as attributes.

Source code in neps/types.py
def __init__(self, *args: Any, **kwargs: Any):
    """Initialize like a dict."""
    super().__init__(*args, **kwargs)
    self.__dict__ = self

ConfigResult dataclass #

ConfigResult(
    id: str,
    config: ConfigLike,
    result: dict,
    metadata: dict,
)

Primary class through which optimizers recieve results.

config instance-attribute #

config: ConfigLike

Configuration that was evaluated.

id instance-attribute #

id: str

Unique identifier for the configuration.

metadata instance-attribute #

metadata: dict

Any additional data to store with this config and result.

result instance-attribute #

result: dict

Some dictionary of results.