pymovements.utils.checks#

Provides basic checks to be reused in other modules.

Functions

check_is_greater_than_zero

Check if all passed values are greater than zero.

check_is_int

Check if all passed values are of type int.

check_is_length_matching

Check if two sequences are of equal length.

check_is_mutual_exclusive

Check if at most one of two values is not None.

check_is_none_is_mutual

Check if two values are either both None or both have a value.

check_is_not_none

Check if all passed values are None.

check_is_positive_value

Check if all passed values are have a value greater or equal to zero.

check_is_scalar

Check if all passed values are of type int or float.

check_nan_both_channels

Check if all nans occur at the same time steps for both channels.

check_no_zeros

Check if variable, or if it is iterable, any of its components are zero.

check_shapes

Check if all provided arrays are of shape (N, 2) and shape is equal for all arrays.

check_two_kwargs

Check if exactly two keyword arguments are given.