nabu.pipeline.utils module

nabu.pipeline.utils.use_options(step_name, step_attr)[source]
nabu.pipeline.utils.pipeline_step(step_attr, step_desc)[source]
nabu.pipeline.utils.get_subregion(sub_region, ndim=3)[source]

Return a “normalized” sub-region in the form ((start_z, end_z), (start_y, end_y), (start_x, end_x)).

Parameters:

sub_region (tuple) – A tuple of tuples or tuple of integers.

Notes

The parameter “sub_region” is normally a tuple of tuples of integers. However it can be more convenient to use tuple of integers. This function will attempt at catching the different cases, but will fail if ‘sub_region’ contains heterogeneous types (ex. tuples along with int)

class nabu.pipeline.utils.EnvSettings(skip_tomoscan_checks: bool = False)[source]

Bases: object

This class centralises the definitions, possibly documentation, and access to environnt variable driven settings. It is meant to be used in the following way:

from nabu.utils import nabu_env_settings if not nabu_env_settings.skip_tomoscan_checks:

do something

skip_tomoscan_checks: bool = False