… load a convention from a local YAML file?

… load a convention from a local YAML file?#

Yes you can. To demonstrate this, let’s take a convention file, which comes with the h5RDMtoolbox

import h5rdmtoolbox as h5tbx
from h5rdmtoolbox import tutorial
yaml_filename = tutorial.get_convention_yaml_filename()

cv = h5tbx.convention.Convention.from_yaml(yaml_filename)
h5tbx.use(cv)
using("h5rdmtoolbox-tutorial-convention")
with h5tbx.File(data_type='experimental', contact=h5tbx.__author_orcid__) as h5:
    h5.dump()