mvpa2.base.constraintsΒΆ

Helper for parameter validation, documentation and conversion

Inheritance diagram of mvpa2.base.constraints

Functions

expand_contraint_spec(spec) Helper to translate literal contraint specs into functional ones

Classes

AltConstraints(\*constraints) Logical OR for constraints.
Constraint Base class for input value conversion/validation.
Constraints(\*constraints) Logical AND for constraints.
EnsureBool Ensure that an input is a bool.
EnsureChoice(\*values) Ensure an input is element of a set of possible values
EnsureDType(dtype) Ensure that an input (or several inputs) are of a particular data type.
EnsureFloat() Ensure that an input (or several inputs) are of a data type ‘float’.
EnsureInt() Ensure that an input (or several inputs) are of a data type ‘int’.
EnsureListOf(dtype) Ensure that an input is a list of a particular data type
EnsureNone Ensure an input is of value None
EnsureRange([min, max]) Ensure an input is within a particular range
EnsureStr Ensure an input is a string.
EnsureTupleOf(dtype) Ensure that an input is a tuple of a particular data type