alogos._utilities.argument_processing

Functions

check_arg(arg_name, arg_val, types=None, vals=None, conv=None)

Check an argument by inspecting its type and value.

str_arg(arg_name, arg_val, default=None, vals=None, to_lower=False)

Check a string argument.

int_arg(arg_name, arg_val, default=None, vals=None, min_incl=None, max_incl=None, allow_none=False)

Check an integer argument.

num_arg(arg_name, arg_val, default=None, vals=None, min_incl=None, max_incl=None)

Check a numerical argument.

bool_arg(arg_name, arg_val, default=None, vals=None)

Check a boolean argument.

callable_arg(arg_name, arg_val, default=None, vals=None)

Check a callable argument.

logical_xor(var1, var2)

Compute logical XOR between two inputs.

ensure_file_extension(filepath, ending)

Ensure a filepath ends with a certain extension.

ensure_no_file_extension(filepath, ending)

Ensure a filepath ends without a certain extension.


Detailed object descriptions

alogos._utilities.argument_processing.check_arg(arg_name, arg_val, types=None, vals=None, conv=None)[source]

Check an argument by inspecting its type and value.

alogos._utilities.argument_processing.str_arg(arg_name, arg_val, default=None, vals=None, to_lower=False)[source]

Check a string argument.

alogos._utilities.argument_processing.int_arg(arg_name, arg_val, default=None, vals=None, min_incl=None, max_incl=None, allow_none=False)[source]

Check an integer argument.

alogos._utilities.argument_processing.num_arg(arg_name, arg_val, default=None, vals=None, min_incl=None, max_incl=None)[source]

Check a numerical argument.

alogos._utilities.argument_processing.bool_arg(arg_name, arg_val, default=None, vals=None)[source]

Check a boolean argument.

alogos._utilities.argument_processing.callable_arg(arg_name, arg_val, default=None, vals=None)[source]

Check a callable argument.

alogos._utilities.argument_processing.logical_xor(var1, var2)[source]

Compute logical XOR between two inputs.

alogos._utilities.argument_processing.ensure_file_extension(filepath, ending)[source]

Ensure a filepath ends with a certain extension.

alogos._utilities.argument_processing.ensure_no_file_extension(filepath, ending)[source]

Ensure a filepath ends without a certain extension.