Note

You are not reading the stable version of Gammapy documentation.
Access the latest stable version v1.3 or the list of Gammapy releases.

write_yaml

gammapy.utils.scripts.write_yaml(dictionary, filename, logger=None, sort_keys=True)[source]

Write YAML file.

Parameters
dictionarydict

Python dictionary

filenamePath

Filename

loggerLogger

Logger

sort_keysbool

Whether to sort keys.