vak.config.parse.from_toml_path#
- vak.config.parse.from_toml_path(toml_path, sections=None)[source]#
parse a TOML configuration file
- Parameters:
toml_path (str, Path) – path to a configuration file in TOML format. Parsed by
toml
library, then converted to an instance ofvak.config.parse.Config
by callingvak.parse.from_toml
sections (str, list) – name of section or sections from configuration file that should be parsed. Can be a string (single section) or list of strings (multiple sections). Default is None, in which case all are validated and parsed.
- Returns:
config – instance of Config class, whose attributes correspond to sections in a config.toml file.
- Return type:
vak.config.parse.Config