hydra_zen.save_as_yaml#
- hydra_zen.save_as_yaml(config, f, resolve=False)[source]#
Save a config to a yaml-format file
This is an alias of
omegaconf.Omegaconf.save
[1].- Parameters:
See also
to_yaml
Serialize a config as a yaml-formatted string.
load_from_yaml
Load a config from a yaml-format file.
References
Examples
>>> from hydra_zen import make_config, save_as_yaml, load_from_yaml
Basic usage
>>> Conf = make_config(a=1, b="foo") >>> save_as_yaml(Conf, "test.yaml") # file written to: test.yaml >>> load_from_yaml("test.yaml") {'a': 1, 'b': 'foo'}