httomo.yaml_checker

httomo.yaml_checker#

Classes

Colour()

Class for storing the ANSI escape codes for different colours.

UniqueKeyLoader(stream)

Check for duplicate keys in yaml

Functions

check_first_method_is_loader(conf)

Check that the first method in pipeline is a loader.

check_hdf5_paths_against_loader(conf, ...)

Check that the hdf5 paths given as parameters to the loader indeed exist in the given data file.

check_id_has_side_out(conf)

Check method with an id has side outputs

check_keys(conf)

There should be three main keys in each method

check_methods_exist_in_templates(conf)

Check if the methods in the pipeline YAML file are valid methods, by checking if they exist in the template YAML files.

check_no_duplicated_keys(f)

there should be no duplicate keys in yaml file :param f: yaml file to check

check_no_imagesaver_after_sweep_method(f)

check that there shouldn't be image saver present after the sweep method

check_no_required_parameter_values(conf)

there should be no REQUIRED parameters in the config pipeline

check_parameter_names_are_known(conf)

Check if the parameter name of config methods exists in yaml template method parameters

check_parameter_names_are_str(conf)

Parameter names should be type string

check_ref_id_valid(conf)

Check reference str is matching a valid method id

check_side_out_matches_ref_arg(conf)

Check reference name exists

sanity_check(conf_generator)

Check if the yaml file is properly indented, has valid mapping and tags.

validate_yaml_config(yaml_file[, in_file])

Check that the modules, methods, and parameters in the YAML_CONFIG file are valid, and adhere to the same structure as in each corresponding module in httomo.yaml_templates.

Module for checking the validity of yaml files.