Parameter#

class obsidian.parameters.base.Parameter(name: str)[source]#

Bases: ABC

Base class for obsidian parameters.

__init__(name: str)[source]#

Methods

__init__(name)

decode()

Decode parameter from transformed space

encode()

Encode parameter to a format that can be used for training

load_state(obj_dict)

Load the state of the Parameter object from a dictionary.

save_state()

Save the state of the Parameter object.

set_search()

Set the search space for the parameter

abstract decode()[source]#

Decode parameter from transformed space

abstract encode()[source]#

Encode parameter to a format that can be used for training

classmethod load_state(obj_dict: dict)[source]#

Load the state of the Parameter object from a dictionary.

Parameters:

obj_dict (dict) – A dictionary containing the state of the object.

Returns:

A new instance of the Parameter class with the loaded state.

Return type:

Parameter

save_state() dict[source]#

Save the state of the Parameter object.

Returns:

A dictionary containing the state of the object.

Return type:

dict

Set the search space for the parameter