Skip to content

Constants of type string do not work (sample_configutation returns the first letter of the string) #379

@mdorier

Description

@mdorier

Example:

>>> from ConfigSpace import ConfigurationSpace, Constant
>>> const = Constant("const", "something")
>>> const
Constant(name='const', default_value='something', meta=None, size=1, value='something')
>>> cs = ConfigurationSpace()
>>> cs.add(const)
>>> cs
Configuration space object:
  Hyperparameters:
    const, Type: Constant, Value: something

>>> cs.sample_configuration()
Configuration(values={
  'const': 's',
})

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions