aiaccel.config.pathlib2str_config#

aiaccel.config.pathlib2str_config(config: ListConfig | DictConfig) ListConfig | DictConfig[source]#

Convert pathlib.Path objects in the configuration to strings.

This function recursively traverses the configuration and replaces all pathlib.Path objects with their string representations. This is useful for saving the configuration in a YAML file, as YAML does not support Path objects.

Parameters:

config (ListConfig | DictConfig) – The configuration to convert.

Returns:

The modified configuration with Path objects replaced by strings.

Return type:

ListConfig | DictConfig