type

language.Choices

class Choices:

Validator: value must be one of the given options.

Pass to :func:`param`'s ``validator=`` kwarg. Prefer the ``choices=`` kwarg on :func:`param` for a single source of truth.

Examples

::

    opt = L.param("adam", validator=L.Choices("adam", "sgd", "adamw"))

Members

property

Source: laco/language.py:1489